add krb5_use_cstype macro
authorJohn Kohl <jtkohl@mit.edu>
Tue, 20 Nov 1990 14:41:07 +0000 (14:41 +0000)
committerJohn Kohl <jtkohl@mit.edu>
Tue, 20 Nov 1990 14:41:07 +0000 (14:41 +0000)
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@1481 dc483132-0cff-0310-8789-dd5450dbe970

src/include/krb5/encryption.h

index dd86b7589a4d9bf2d638337c88377aac06b3e636..8e4f1355c4450e643993f6e0c6a772ff863b97be 100644 (file)
@@ -141,6 +141,8 @@ extern int krb5_max_cksum;          /* max entry in array */
 
 #define valid_cksumtype(cktype)     ((cktype <= krb5_max_cksum) && (cktype > 0) && krb5_cksumarray[cktype])
 
+/* set up *eblockp to use etype */
+#define krb5_use_cstype(eblockp, etype) (eblockp)->crypto_entry = krb5_csarray[(etype)]->system
 
 #define krb5_encrypt(inptr, outptr, size, eblock, ivec) (*(eblock)->crypto_entry->encrypt_func)(inptr, outptr, size, eblock, ivec)
 #define krb5_decrypt(inptr, outptr, size, eblock, ivec) (*(eblock)->crypto_entry->decrypt_func)(inptr, outptr, size, eblock, ivec)