diff options
author | Jeremy Allison <jra@samba.org> | 2003-01-19 22:27:32 +0000 |
---|---|---|
committer | Jeremy Allison <jra@samba.org> | 2003-01-19 22:27:32 +0000 |
commit | 812e093f026a3575f00633c8d4d63b8bdb8a1bcb (patch) | |
tree | 9dfb2220e6f57759da6a66340e25e772274cf0d9 /source3/libsmb | |
parent | dd99a6a81619c46ea512076f0ca860748d2fae4a (diff) | |
download | samba-812e093f026a3575f00633c8d4d63b8bdb8a1bcb.tar.gz samba-812e093f026a3575f00633c8d4d63b8bdb8a1bcb.tar.bz2 samba-812e093f026a3575f00633c8d4d63b8bdb8a1bcb.zip |
Merge in more of the SuSE patches for Heimdal. These changes show how
to add a function without an explicit #ifdef HEIMDAL which I'm trying
to avoid.
Jeremy.
(This used to be commit 92ecd0bf0fe2cc4f6c86ca48e6e458e726470a50)
Diffstat (limited to 'source3/libsmb')
-rw-r--r-- | source3/libsmb/clikrb5.c | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/source3/libsmb/clikrb5.c b/source3/libsmb/clikrb5.c index cca2a9cd3a..20d0906e71 100644 --- a/source3/libsmb/clikrb5.c +++ b/source3/libsmb/clikrb5.c @@ -2,6 +2,7 @@ Unix SMB/CIFS implementation. simple kerberos5 routines for active directory Copyright (C) Andrew Tridgell 2001 + Copyright (C) Luke Howard 2002 This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -21,6 +22,34 @@ #include "includes.h" #ifdef HAVE_KRB5 + +#ifndef KRB5_SET_REAL_TIME +/* + * This function is not in the Heimdal mainline. + */ +krb5_error_code krb5_set_real_time(krb5_context context, int32_t seconds, int32_t microseconds) +{ + krb5_error_code ret; + int32_t sec, usec; + + ret = krb5_us_timeofday(context, &sec, &usec); + if (ret) + return ret; + + context->kdc_sec_offset = seconds - sec; + context->kdc_usec_offset = microseconds - usec; + + return 0; +} +#endif + +#if defined(HAVE_KRB5_SET_DEFAULT_IN_TKT_ETYPES) && !defined(HAVE_KRB5_SET_DEFAULT_TGS_KTYPES) +krb5_error_code krb5_set_default_tgs_ktypes(krb5_context ctx, const krb5_enctype *enc) +{ + return krb5_set_default_in_tkt_etypes(ctx, enc); +} +#endif + /* we can't use krb5_mk_req because w2k wants the service to be in a particular format */ |