1 #ifndef _HEADER_smb_krb5_h
2 #define _HEADER_smb_krb5_h
4 #define KRB5_PRIVATE 1 /* this file uses PRIVATE interfaces! */
5 /* this file uses DEPRECATED interfaces! */
7 #define ADS_IGNORE_PRINCIPAL "not_defined_in_RFC4178@please_ignore"
9 #if defined(HAVE_KRB5_DEPRECATED_WITH_IDENTIFIER)
10 #define KRB5_DEPRECATED 1
12 #define KRB5_DEPRECATED
19 #ifndef KRB5_ADDR_NETBIOS
20 #define KRB5_ADDR_NETBIOS 0x14
23 #ifndef KRB5KRB_ERR_RESPONSE_TOO_BIG
24 #define KRB5KRB_ERR_RESPONSE_TOO_BIG (-1765328332L)
27 /* Heimdal uses a slightly different name */
28 #if defined(HAVE_ENCTYPE_ARCFOUR_HMAC_MD5) && !defined(HAVE_ENCTYPE_ARCFOUR_HMAC)
29 #define ENCTYPE_ARCFOUR_HMAC ENCTYPE_ARCFOUR_HMAC_MD5
32 /* The older versions of heimdal that don't have this
33 define don't seem to use it anyway. I'm told they
34 always use a subkey */
35 #ifndef HAVE_AP_OPTS_USE_SUBKEY
36 #define AP_OPTS_USE_SUBKEY 0
41 #if defined(HAVE_MAGIC_IN_KRB5_ADDRESS) && defined(HAVE_ADDRTYPE_IN_KRB5_ADDRESS) /* MIT */
43 #elif defined(HAVE_KRB5_ADDRESSES) /* Heimdal */
44 krb5_addresses
*addrs
;
46 #error UNKNOWN_KRB5_ADDRESS_TYPE
47 #endif /* defined(HAVE_MAGIC_IN_KRB5_ADDRESS) && defined(HAVE_ADDRTYPE_IN_KRB5_ADDRESS) */
50 #ifdef HAVE_KRB5_KEYBLOCK_KEYVALUE /* Heimdal */
51 #define KRB5_KEY_TYPE(k) ((k)->keytype)
52 #define KRB5_KEY_LENGTH(k) ((k)->keyvalue.length)
53 #define KRB5_KEY_DATA(k) ((k)->keyvalue.data)
54 #define KRB5_KEY_DATA_CAST void
56 #define KRB5_KEY_TYPE(k) ((k)->enctype)
57 #define KRB5_KEY_LENGTH(k) ((k)->length)
58 #define KRB5_KEY_DATA(k) ((k)->contents)
59 #define KRB5_KEY_DATA_CAST krb5_octet
60 #endif /* HAVE_KRB5_KEYBLOCK_KEYVALUE */
62 #ifdef HAVE_KRB5_KEYTAB_ENTRY_KEY /* MIT */
63 #define KRB5_KT_KEY(k) (&(k)->key)
64 #elif HAVE_KRB5_KEYTAB_ENTRY_KEYBLOCK /* Heimdal */
65 #define KRB5_KT_KEY(k) (&(k)->keyblock)
67 #error krb5_keytab_entry has no key or keyblock member
68 #endif /* HAVE_KRB5_KEYTAB_ENTRY_KEY */
70 #endif /* HAVE_KRB5 */
72 #include "krb5_protos.h"
74 #endif /* _HEADER_smb_krb5_h */