diff options
author | Jeremy Allison <jra@samba.org> | 2004-10-28 23:50:14 +0000 |
---|---|---|
committer | Gerald (Jerry) Carter <jerry@samba.org> | 2007-10-10 10:53:05 -0500 |
commit | 13542c7b5058d1fa0817ae9f371e013157b471d0 (patch) | |
tree | b32d24d434aaf48de5665136da02f9f6522a201c /source3/libsmb | |
parent | c5621fe5a673a270d633bb890c3d42c1d8d4d50b (diff) | |
download | samba-13542c7b5058d1fa0817ae9f371e013157b471d0.tar.gz samba-13542c7b5058d1fa0817ae9f371e013157b471d0.tar.xz samba-13542c7b5058d1fa0817ae9f371e013157b471d0.zip |
r3342: More MIT/Heimdal fixes to allow an enctype to be explicitly set in a krb5_creds
struct.
Jeremy.
(This used to be commit c9b80490128e09442a01dd8ec6f4b453769e82c1)
Diffstat (limited to 'source3/libsmb')
-rw-r--r-- | source3/libsmb/clikrb5.c | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/source3/libsmb/clikrb5.c b/source3/libsmb/clikrb5.c index f7f84f1e297..291aa13de01 100644 --- a/source3/libsmb/clikrb5.c +++ b/source3/libsmb/clikrb5.c @@ -251,6 +251,17 @@ } #endif +void kerberos_set_creds_enctype(krb5_creds *pcreds, int enctype) +{ +#if defined(HAVE_KRB5_KEYBLOCK_IN_CREDS) + KRB5_KEY_TYPE((&pcreds->keyblock)) = enctype; +#elif defined(HAVE_KRB5_SESSION_IN_CREDS) + KRB5_KEY_TYPE((&pcreds->session)) = enctype; +#else +#error UNKNOWN_KEYBLOCK_MEMBER_IN_KRB5_CREDS_STRUCT +#endif +} + static BOOL ads_cleanup_expired_creds(krb5_context context, krb5_ccache ccache, krb5_creds *credsp) |