summaryrefslogtreecommitdiffstats
path: root/src/lib/crypto/krb/state.c
diff options
context:
space:
mode:
authorGreg Hudson <ghudson@mit.edu>2011-03-05 13:51:00 +0000
committerGreg Hudson <ghudson@mit.edu>2011-03-05 13:51:00 +0000
commit46408af6a4436e57747c89deb364415c51a5c5c5 (patch)
tree610f8fd57633380ee2aabc352d8be6c10ee58b09 /src/lib/crypto/krb/state.c
parentb2ae990817b9ccfcaabf550fc0a6c200342e42d1 (diff)
downloadkrb5-46408af6a4436e57747c89deb364415c51a5c5c5.tar.gz
krb5-46408af6a4436e57747c89deb364415c51a5c5c5.tar.xz
krb5-46408af6a4436e57747c89deb364415c51a5c5c5.zip
Remove the init_state and free_state enctype functions and go back to
always delegating state to the enc provider. (We needed enctype- specific state initialization for CCM enctypes when we had them.) git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@24681 dc483132-0cff-0310-8789-dd5450dbe970
Diffstat (limited to 'src/lib/crypto/krb/state.c')
-rw-r--r--src/lib/crypto/krb/state.c20
1 files changed, 2 insertions, 18 deletions
diff --git a/src/lib/crypto/krb/state.c b/src/lib/crypto/krb/state.c
index 2c3371c3a..85327de03 100644
--- a/src/lib/crypto/krb/state.c
+++ b/src/lib/crypto/krb/state.c
@@ -35,22 +35,6 @@
*/
#include "crypto_int.h"
-/* Most enctypes delegate cipher state handling to the enc provider by using
- * this function as their init_state methods. */
-krb5_error_code
-krb5int_init_state_enc(const struct krb5_keytypes *ktp,
- const krb5_keyblock *key, krb5_keyusage keyusage,
- krb5_data *out_state)
-{
- return ktp->enc->init_state(key, keyusage, out_state);
-}
-
-void
-krb5int_free_state_enc(const struct krb5_keytypes *ktp, krb5_data *state)
-{
- (void)ktp->enc->free_state(state);
-}
-
krb5_error_code KRB5_CALLCONV
krb5_c_init_state (krb5_context context, const krb5_keyblock *key,
krb5_keyusage keyusage, krb5_data *new_state)
@@ -60,7 +44,7 @@ krb5_c_init_state (krb5_context context, const krb5_keyblock *key,
ktp = find_enctype(key->enctype);
if (ktp == NULL)
return KRB5_BAD_ENCTYPE;
- return ktp->init_state(ktp, key, keyusage, new_state);
+ return ktp->enc->init_state(key, keyusage, new_state);
}
krb5_error_code KRB5_CALLCONV
@@ -72,6 +56,6 @@ krb5_c_free_state(krb5_context context, const krb5_keyblock *key,
ktp = find_enctype(key->enctype);
if (ktp == NULL)
return KRB5_BAD_ENCTYPE;
- ktp->free_state(ktp, state);
+ ktp->enc->free_state(state);
return 0;
}