From 7fc21c4a4a6ef8a88567f166eda1fe73784686c7 Mon Sep 17 00:00:00 2001 From: Greg Hudson Date: Mon, 24 Oct 2011 15:09:32 +0000 Subject: Refactor salt computation into libkdb5 Add a new API krb5_dbe_compute_salt() to determine the salt for a key data entry, and use it in the three places we currently compute salts. git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@25410 dc483132-0cff-0310-8789-dd5450dbe970 --- src/include/kdb.h | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'src/include') diff --git a/src/include/kdb.h b/src/include/kdb.h index 78f786f3b..0f50a83c1 100644 --- a/src/include/kdb.h +++ b/src/include/kdb.h @@ -576,6 +576,12 @@ krb5_dbe_update_tl_data( krb5_context context, krb5_db_entry * entry, krb5_tl_data * new_tl_data); +/* Compute the salt for a key data entry given the corresponding principal. */ +krb5_error_code +krb5_dbe_compute_salt(krb5_context context, const krb5_key_data *key, + krb5_const_principal princ, krb5_int16 *salttype_out, + krb5_data **salt_out); + krb5_error_code krb5_dbe_cpw( krb5_context kcontext, krb5_keyblock * master_key, -- cgit