Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/lib/libskey de-__P, slightly KNF, and make a bit of the form...



details:   https://anonhg.NetBSD.org/src/rev/5eb814065de3
branches:  trunk
changeset: 573666:5eb814065de3
user:      perry <perry%NetBSD.org@localhost>
date:      Fri Feb 04 16:12:13 2005 +0000

description:
de-__P, slightly KNF, and make a bit of the formatting more consistent.

diffstat:

 lib/libskey/skey.h |  76 ++++++++++++++++++++++++++---------------------------
 1 files changed, 37 insertions(+), 39 deletions(-)

diffs (126 lines):

diff -r 5f678f8560f4 -r 5eb814065de3 lib/libskey/skey.h
--- a/lib/libskey/skey.h        Fri Feb 04 15:52:08 2005 +0000
+++ b/lib/libskey/skey.h        Fri Feb 04 16:12:13 2005 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: skey.h,v 1.8 2000/07/28 16:35:11 thorpej Exp $ */
+/*     $NetBSD: skey.h,v 1.9 2005/02/04 16:12:13 perry Exp $   */
 
 /*
  * S/KEY v1.1b (skey.h)
@@ -16,8 +16,7 @@
  */
 
 /* Server-side data structure for reading keys file during login */
-struct skey
-{
+struct skey {
   FILE *keyfile;
   char buf[256];
   char *logname;
@@ -28,8 +27,7 @@
 };
 
 /* Client-side structure for scanning data stream for challenge */
-struct mc
-{
+struct mc {
   char buf[256];
   int skip;
   int cnt;
@@ -37,62 +35,62 @@
 
 /* Maximum sequence number we allow */
 #ifndef SKEY_MAX_SEQ
-#define SKEY_MAX_SEQ           10000
+#define SKEY_MAX_SEQ           10000
 #endif
 
 /* Minimum secret password length (rfc2289) */
 #ifndef SKEY_MIN_PW_LEN
-#define SKEY_MIN_PW_LEN                10
+#define SKEY_MIN_PW_LEN                10
 #endif
 
 /* Max secret password length (rfc2289 says 63 but allows more) */
 #ifndef SKEY_MAX_PW_LEN
-#define SKEY_MAX_PW_LEN                255
+#define SKEY_MAX_PW_LEN                255
 #endif
 
 /* Max length of an S/Key seed (rfc2289) */
 #ifndef SKEY_MAX_SEED_LEN
-#define SKEY_MAX_SEED_LEN       16
+#define SKEY_MAX_SEED_LEN      16
 #endif
 
 /* Max length of S/Key challenge (otp-???? 9999 seed) */
 #ifndef SKEY_MAX_CHALLENGE
-#define SKEY_MAX_CHALLENGE      (11 + SKEY_MAX_HASHNAME_LEN + SKEY_MAX_SEED_LEN)
+#define SKEY_MAX_CHALLENGE     (11 + SKEY_MAX_HASHNAME_LEN + SKEY_MAX_SEED_LEN)
 #endif
 
 /* Max length of hash algorithm name (md4/md5/sha1/rmd160) */
-#define SKEY_MAX_HASHNAME_LEN  6
+#define SKEY_MAX_HASHNAME_LEN  6
 
 /* Size of a binary key (not NULL-terminated) */
-#define SKEY_BINKEY_SIZE                8
+#define SKEY_BINKEY_SIZE       8
 
 /* Location of random file for bogus challenges */
-#define _SKEY_RAND_FILE_PATH_  "/var/db/host.random"
+#define _SKEY_RAND_FILE_PATH_  "/var/db/host.random"
 
 /* Prototypes */
-void f __P ((char *));
-int keycrunch __P ((char *, const char *, const char *));
-char *btoe __P ((char *, const char *));
-char *put8 __P ((char *, const char *));
-int etob __P ((char *, const char *));
-void rip __P ((char *));
-int skeychallenge __P ((struct skey *, const char *, char *, size_t));
-int skeylookup __P ((struct skey *, const char *));
-int skeyverify __P ((struct skey *, char *));
-void sevenbit __P ((char *));
-void backspace __P ((char *));
-const char *skipspace __P ((const char *));
-char *readpass __P ((char *, int));
-char *readskey __P ((char *, int));
-int skey_authenticate __P ((const char *));
-int skey_passcheck __P ((const char *, char *));
-const char *skey_keyinfo __P ((const char *));
-int skey_haskey __P ((const char *));
-int getskeyprompt __P ((struct skey *, char *, char *));
-int atob8 __P((char *, const char *));
-int btoa8 __P((char *, const char *));
-int htoi __P((int));
-const char *skey_get_algorithm __P((void));
-const char *skey_set_algorithm __P((const char *));
-int skeygetnext __P((struct skey *));
-int skeyzero __P((struct skey *, char *));
+void f(char *);
+int keycrunch(char *, const char *, const char *);
+char *btoe(char *, const char *);
+char *put8(char *, const char *);
+int etob(char *, const char *);
+void rip(char *);
+int skeychallenge(struct skey *, const char *, char *, size_t);
+int skeylookup(struct skey *, const char *);
+int skeyverify(struct skey *, char *);
+void sevenbit(char *);
+void backspace(char *);
+const char *skipspace(const char *);
+char *readpass(char *, int);
+char *readskey(char *, int);
+int skey_authenticate(const char *);
+int skey_passcheck(const char *, char *);
+const char *skey_keyinfo(const char *);
+int skey_haskey(const char *);
+int getskeyprompt(struct skey *, char *, char *);
+int atob8(char *, const char *);
+int btoa8(char *, const char *);
+int htoi(int);
+const char *skey_get_algorithm(void);
+const char *skey_set_algorithm(const char *);
+int skeygetnext(struct skey *);
+int skeyzero(struct skey *, char *);



Home | Main Index | Thread Index | Old Index