diff options
author | Chris Provenzano <proven@mit.edu> | 1995-09-06 19:07:04 +0000 |
---|---|---|
committer | Chris Provenzano <proven@mit.edu> | 1995-09-06 19:07:04 +0000 |
commit | e2881a98c8944e1a70b584d94187f6468eb23a6d (patch) | |
tree | af22582f75ca3a5d05961a0e2645d9536776fd2a /src/lib | |
parent | 29e13c7b49e47ef64805e7f864c64d6105293607 (diff) | |
download | krb5-e2881a98c8944e1a70b584d94187f6468eb23a6d.tar.gz krb5-e2881a98c8944e1a70b584d94187f6468eb23a6d.tar.xz krb5-e2881a98c8944e1a70b584d94187f6468eb23a6d.zip |
* des_int.h, destest.c, init_rkey.c, random_key.c, string2key.c
* verify.c : s/keytype/enctype/g, s/KEYTYPE/ENCTYPE/g
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@6712 dc483132-0cff-0310-8789-dd5450dbe970
Diffstat (limited to 'src/lib')
-rw-r--r-- | src/lib/crypto/des/ChangeLog | 4 | ||||
-rw-r--r-- | src/lib/crypto/des/des_int.h | 2 | ||||
-rw-r--r-- | src/lib/crypto/des/destest.c | 4 | ||||
-rw-r--r-- | src/lib/crypto/des/init_rkey.c | 10 | ||||
-rw-r--r-- | src/lib/crypto/des/random_key.c | 2 | ||||
-rw-r--r-- | src/lib/crypto/des/string2key.c | 16 | ||||
-rw-r--r-- | src/lib/crypto/des/verify.c | 4 |
7 files changed, 23 insertions, 19 deletions
diff --git a/src/lib/crypto/des/ChangeLog b/src/lib/crypto/des/ChangeLog index b36a526eb..ba2beec6a 100644 --- a/src/lib/crypto/des/ChangeLog +++ b/src/lib/crypto/des/ChangeLog @@ -1,3 +1,7 @@ +Wed Sep 06 14:20:57 1995 Chris Provenzano (proven@mit.edu) + + * des_int.h, destest.c, init_rkey.c, random_key.c, string2key.c + * verify.c : s/keytype/enctype/g, s/KEYTYPE/ENCTYPE/g Tue Sep 05 22:10:34 1995 Chris Provenzano (proven@mit.edu) diff --git a/src/lib/crypto/des/des_int.h b/src/lib/crypto/des/des_int.h index cd242a361..97ca9883e 100644 --- a/src/lib/crypto/des/des_int.h +++ b/src/lib/crypto/des/des_int.h @@ -145,7 +145,7 @@ extern krb5_error_code mit_des_random_key /* string2key.c */ extern krb5_error_code mit_des_string_to_key - PROTOTYPE(( const krb5_encrypt_block FAR *, const krb5_keytype, + PROTOTYPE(( const krb5_encrypt_block FAR *, const krb5_enctype, krb5_keyblock FAR *, const krb5_data FAR *, const krb5_data FAR *)); /* weak_key.c */ diff --git a/src/lib/crypto/des/destest.c b/src/lib/crypto/des/destest.c index c4b320e49..a1f9daf09 100644 --- a/src/lib/crypto/des/destest.c +++ b/src/lib/crypto/des/destest.c @@ -58,9 +58,9 @@ char *argv[]; /* do some initialisation */ initialize_krb5_error_table(); - krb5_use_keytype(context, &eblock, KEYTYPE_DES_CBC_CRC); + krb5_use_enctype(context, &eblock, ENCTYPE_DES_CBC_CRC); keyblock.magic = KV5M_KEYBLOCK; - keyblock.keytype = KEYTYPE_DES_CBC_CRC; + keyblock.enctype = ENCTYPE_DES_CBC_CRC; keyblock.length = sizeof (mit_des_cblock); keyblock.contents = (krb5_octet *)key; diff --git a/src/lib/crypto/des/init_rkey.c b/src/lib/crypto/des/init_rkey.c index 441de6418..ca9483a5c 100644 --- a/src/lib/crypto/des/init_rkey.c +++ b/src/lib/crypto/des/init_rkey.c @@ -38,11 +38,11 @@ mit_des_init_random_key (seedblock, seed) krb5_pointer * seed; { mit_des_random_key_seed * p_seed; - if ((seedblock->keytype != KEYTYPE_DES_CBC_CRC) && - (seedblock->keytype != KEYTYPE_DES_CBC_MD4) && - (seedblock->keytype != KEYTYPE_DES_CBC_MD5) && - (seedblock->keytype != KEYTYPE_DES_CBC_RAW)) - return KRB5_BAD_KEYTYPE; + if ((seedblock->enctype != ENCTYPE_DES_CBC_CRC) && + (seedblock->enctype != ENCTYPE_DES_CBC_MD4) && + (seedblock->enctype != ENCTYPE_DES_CBC_MD5) && + (seedblock->enctype != ENCTYPE_DES_CBC_RAW)) + return KRB5_BAD_ENCTYPE; if ( !(p_seed = (mit_des_random_key_seed *) malloc(sizeof(mit_des_random_key_seed))) ) return ENOMEM; diff --git a/src/lib/crypto/des/random_key.c b/src/lib/crypto/des/random_key.c index 563751769..3a8758f2b 100644 --- a/src/lib/crypto/des/random_key.c +++ b/src/lib/crypto/des/random_key.c @@ -45,7 +45,7 @@ mit_des_random_key (eblock, seed, keyblock) } randkey->magic = KV5M_KEYBLOCK; randkey->length = sizeof(mit_des_cblock); - randkey->keytype = eblock->crypto_entry->proto_keytype; + randkey->enctype = eblock->crypto_entry->proto_enctype; mit_des_new_random_key(randkey->contents, (mit_des_random_key_seed *) seed); *keyblock = randkey; return 0; diff --git a/src/lib/crypto/des/string2key.c b/src/lib/crypto/des/string2key.c index c20f2be9d..e5cddf02f 100644 --- a/src/lib/crypto/des/string2key.c +++ b/src/lib/crypto/des/string2key.c @@ -26,7 +26,7 @@ /* converts the string pointed to by "data" into an encryption key - of type "keytype". *keyblock is filled in with the key info; + of type "enctype". *keyblock is filled in with the key info; in particular, keyblock->contents is to be set to allocated storage. It is the responsibility of the caller to release this storage when the generated key no longer needed. @@ -35,15 +35,15 @@ algorithm. If the particular function called does not know how to make a - key of type "keytype", an error may be returned. + key of type "enctype", an error may be returned. returns: errors */ krb5_error_code -mit_des_string_to_key (eblock, keytype, keyblock, data, salt) +mit_des_string_to_key (eblock, enctype, keyblock, data, salt) const krb5_encrypt_block FAR * eblock; -const krb5_keytype keytype; +const krb5_enctype enctype; krb5_keyblock FAR * keyblock; const krb5_data FAR * data; const krb5_data FAR * salt; @@ -65,16 +65,16 @@ const krb5_data FAR * salt; #define min(A, B) ((A) < (B) ? (A): (B)) #endif - if ((keytype != KEYTYPE_DES_CBC_CRC) && (keytype != KEYTYPE_DES_CBC_MD4) && - (keytype != KEYTYPE_DES_CBC_MD5) && (keytype != KEYTYPE_DES_CBC_RAW)) - return (KRB5_PROG_KEYTYPE_NOSUPP); + if ((enctype != ENCTYPE_DES_CBC_CRC) && (enctype != ENCTYPE_DES_CBC_MD4) && + (enctype != ENCTYPE_DES_CBC_MD5) && (enctype != ENCTYPE_DES_CBC_RAW)) + return (KRB5_PROG_ETYPE_NOSUPP); if ( !(keyblock->contents = (krb5_octet *)malloc(sizeof(mit_des_cblock))) ) return(ENOMEM); keyblock->magic = KV5M_KEYBLOCK; keyblock->length = sizeof(mit_des_cblock); - keyblock->keytype = eblock->crypto_entry->proto_keytype; + keyblock->enctype = eblock->crypto_entry->proto_enctype; key = keyblock->contents; if (salt) diff --git a/src/lib/crypto/des/verify.c b/src/lib/crypto/des/verify.c index 1953ac57f..7ae08c763 100644 --- a/src/lib/crypto/des/verify.c +++ b/src/lib/crypto/des/verify.c @@ -148,8 +148,8 @@ main(argc,argv) /* do some initialisation */ initialize_krb5_error_table(); - krb5_use_keytype(context, &eblock, KEYTYPE_DES_CBC_CRC); - keyblock.keytype = KEYTYPE_DES_CBC_CRC; + krb5_use_enctype(context, &eblock, ENCTYPE_DES_CBC_CRC); + keyblock.enctype = ENCTYPE_DES_CBC_CRC; keyblock.length = sizeof(mit_des_cblock); /* use known input and key */ |