diff options
Diffstat (limited to 'src/lib/krb5/krb')
66 files changed, 217 insertions, 203 deletions
diff --git a/src/lib/krb5/krb/ChangeLog b/src/lib/krb5/krb/ChangeLog index 8223b84..a6c9e65 100644 --- a/src/lib/krb5/krb/ChangeLog +++ b/src/lib/krb5/krb/ChangeLog @@ -1,45 +1,18 @@ +Wed Feb 22 17:14:31 1995 Keith Vetter (keithv@fusion.com) + + * walk_rtr.c (krb5_walk_realm_tree): formal parameter wasn't declared. + * send_tgs.c: const in wrong place in the prototype. + * get_in_tkt.c, preauth.c, rd_cred.c, rd_priv.c, rd_req_dec.c, + rd_safe.c: needed a 32 bit abs() function. + * parse.c: removed call to fprintf on error the windows version + * send_auth.c: defined for windows the ECONNABORTED errno (will + be removed when the socket layer is fully implemented). + Tue Feb 21 23:38:34 1995 Theodore Y. Ts'o (tytso@dcl) * mk_cred.c (krb5_mk_cred): Fix argument type to krb5_free_cred_enc_part(). -Thu Feb 16 00:22:03 1995 Chris Provenzano (proven@mit.edu) - - * send_tgs.c (krb5_send_tgs()) Added check for a valid krb5_creds * arg. - - * mk_req_ext.c (krb5_mk_req_extended()) Require caller to pass in a - valid krb5_creds * arg, and removed kdc_options krb5_flags - and krb5_ccache from arg list. - * send_tgs.c (krb5_send_tgs()) - * sendauth.c (krb5_sendauth()) - Fix calls to krb5_mk_req_extended() - - * gc_frm_kdc.c (krb5_get_cred_from_kdc()) Changed krb5_creds * in/out - arg to be an in only arg and added krb5_creds ** out arg. - - * gc_via_tgt.c (krb5_get_cred_via_tgt()) Changed krb5_creds * in/out - arg to be an in only arg and added krb5_creds ** out arg. - - * gc_2tgt.c (krb5_get_cred_via_2tgt()) Changed krb5_creds * in/out - arg to be an in only arg and added krb5_creds ** out arg. - - * int-proto.h Updated prototypes for krb5_get_cred_via_tgt() and - krb5_get_cred_via_2tgt(). - - * get_creds.c (krb5_get_credentials()) Changed krb5_creds * in/out - arg to be an in only arg and added krb5_creds ** out arg. - * sendauth.c (krb5_sendauth()) - Routines that also require krb5_creds * in/out arg to be - appropriately changed because krb5_get_credentials() changed. - * gc_frm_kdc.c (krb5_get_cred_from_kdc()) - * get_fcreds.c (krb5_get_for_creds()) - * mk_req.c (krb5_mk_req()) - Other routines that needed adjusting because - krb5_get_credentials() changed but didn't need an API change. - - * int-proto.h Don't prototype krb5_get_cred_via_tgt() twice. Use the - second to prototype krb5_get_cred_via_2tgt(). - Mon Feb 13 20:25:20 1995 Theodore Y. Ts'o (tytso@dcl) * get_in_tkt.c (krb5_get_in_tkt): Fix memory leak --- the default diff --git a/src/lib/krb5/krb/Makefile.in b/src/lib/krb5/krb/Makefile.in index 64aab2a..7ac5d07 100644 --- a/src/lib/krb5/krb/Makefile.in +++ b/src/lib/krb5/krb/Makefile.in @@ -1,74 +1,74 @@ CFLAGS = $(CCOPTS) $(DEFS) LDFLAGS = -g -all:: $(OBJS) - +##DOSBUILDTOP = ..\..\.. +##DOSLIBNAME=..\libkrb5.lib +##DOS!include $(BUILDTOP)\config\windows.in - -OBJS= addr_comp.o \ - addr_order.o \ - addr_srch.o \ - bld_pr_ext.o \ - bld_princ.o \ - chk_trans.o \ - compat_recv.o \ - conv_princ.o \ - copy_addrs.o \ - copy_auth.o \ - copy_athctr.o \ - copy_cksum.o \ - copy_creds.o \ - copy_data.o \ - copy_key.o \ - copy_princ.o \ - copy_tick.o \ - cp_key_cnt.o \ - decode_kdc.o \ - decrypt_tk.o \ - encode_kdc.o \ - encrypt_tk.o \ - free_rtree.o \ - faddr_ordr.o \ - gc_frm_kdc.o \ - gc_via_tgt.o \ - gc_2tgt.o \ - gen_seqnum.o \ - gen_subkey.o \ - get_creds.o \ - get_fcreds.o \ - get_in_tkt.o \ - in_tkt_ktb.o \ - in_tkt_pwd.o \ - in_tkt_sky.o \ - init_ctx.o \ - kdc_rep_dc.o \ - krbconfig.o \ - mk_cred.o \ - mk_error.o \ - mk_priv.o \ - mk_rep.o \ - mk_req.o \ - mk_req_ext.o \ - mk_safe.o \ - parse.o \ - pr_to_salt.o \ - preauth.o \ - princ_comp.o \ - rd_cred.o \ - rd_error.o \ - rd_priv.o \ - rd_rep.o \ - rd_req.o \ - rd_req_sim.o \ - rd_req_dec.o \ - rd_safe.o \ - recvauth.o \ - sendauth.o \ - send_tgs.o \ - srv_rcache.o \ - tgtname.o \ - unparse.o \ - walk_rtree.o +OBJS= addr_comp.$(OBJEXT) \ + addr_order.$(OBJEXT) \ + addr_srch.$(OBJEXT) \ + bld_pr_ext.$(OBJEXT) \ + bld_princ.$(OBJEXT) \ + chk_trans.$(OBJEXT) \ + compat_recv.$(OBJEXT) \ + conv_princ.$(OBJEXT) \ + copy_addrs.$(OBJEXT) \ + copy_auth.$(OBJEXT) \ + copy_athctr.$(OBJEXT) \ + copy_cksum.$(OBJEXT) \ + copy_creds.$(OBJEXT) \ + copy_data.$(OBJEXT) \ + copy_key.$(OBJEXT) \ + copy_princ.$(OBJEXT) \ + copy_tick.$(OBJEXT) \ + cp_key_cnt.$(OBJEXT) \ + decode_kdc.$(OBJEXT) \ + decrypt_tk.$(OBJEXT) \ + encode_kdc.$(OBJEXT) \ + encrypt_tk.$(OBJEXT) \ + free_rtree.$(OBJEXT) \ + faddr_ordr.$(OBJEXT) \ + gc_frm_kdc.$(OBJEXT) \ + gc_via_tgt.$(OBJEXT) \ + gc_2tgt.$(OBJEXT) \ + gen_seqnum.$(OBJEXT) \ + gen_subkey.$(OBJEXT) \ + get_creds.$(OBJEXT) \ + get_fcreds.$(OBJEXT) \ + get_in_tkt.$(OBJEXT) \ + in_tkt_ktb.$(OBJEXT) \ + in_tkt_pwd.$(OBJEXT) \ + in_tkt_sky.$(OBJEXT) \ + init_ctx.$(OBJEXT) \ + kdc_rep_dc.$(OBJEXT) \ + krbconfig.$(OBJEXT) \ + mk_cred.$(OBJEXT) \ + mk_error.$(OBJEXT) \ + mk_priv.$(OBJEXT) \ + mk_rep.$(OBJEXT) \ + mk_req.$(OBJEXT) \ + mk_req_ext.$(OBJEXT) \ + mk_safe.$(OBJEXT) \ + parse.$(OBJEXT) \ + pr_to_salt.$(OBJEXT) \ + preauth.$(OBJEXT) \ + princ_comp.$(OBJEXT) \ + rd_cred.$(OBJEXT) \ + rd_error.$(OBJEXT) \ + rd_priv.$(OBJEXT) \ + rd_rep.$(OBJEXT) \ + rd_req.$(OBJEXT) \ + rd_req_sim.$(OBJEXT) \ + rd_req_dec.$(OBJEXT) \ + rd_safe.$(OBJEXT) \ + recvauth.$(OBJEXT) \ + sendauth.$(OBJEXT) \ + send_tgs.$(OBJEXT) \ + srv_rcache.$(OBJEXT) \ + tgtname.$(OBJEXT) \ + unparse.$(OBJEXT) \ + walk_rtree.$(OBJEXT) SRCS= $(srcdir)/addr_comp.c \ $(srcdir)/addr_order.c \ @@ -135,6 +135,8 @@ SRCS= $(srcdir)/addr_comp.c \ $(srcdir)/unparse.c \ $(srcdir)/walk_rtree.c +all:: $(OBJS) + COMERRLIB=$(BUILDTOP)/util/et/libcom_err.a T_WALK_RTREE_OBJS= t_walk_rtree.o walk_rtree.o tgtname.o unparse.o \ @@ -145,7 +147,11 @@ t_walk_rtree: $(T_WALK_RTREE_OBJS) TEST_PROGS= t_walk_rtree -check:: $(TEST_PROGS) +check:: check-$(WHAT) + +check-unix:: $(TEST_PROGS) + +check-windows:: clean:: - $(RM) t_walk_rtree t_walk_rtree.o + $(RM) t_walk_rtree$(EXEEXT) t_walk_rtree.$(OBJEXT) diff --git a/src/lib/krb5/krb/addr_comp.c b/src/lib/krb5/krb/addr_comp.c index 211648f..76d8e91 100644 --- a/src/lib/krb5/krb/addr_comp.c +++ b/src/lib/krb5/krb/addr_comp.c @@ -31,7 +31,7 @@ /* * If the two addresses are the same, return TRUE, else return FALSE */ -krb5_boolean +krb5_boolean INTERFACE krb5_address_compare(context, addr1, addr2) krb5_context context; const krb5_address *addr1; diff --git a/src/lib/krb5/krb/addr_order.c b/src/lib/krb5/krb/addr_order.c index 6d9f346..185f73f 100644 --- a/src/lib/krb5/krb/addr_order.c +++ b/src/lib/krb5/krb/addr_order.c @@ -36,7 +36,7 @@ * Return an ordering on two addresses: 0 if the same, * < 0 if first is less than 2nd, > 0 if first is greater than 2nd. */ -int +int INTERFACE krb5_address_order(context, addr1, addr2) krb5_context context; register const krb5_address *addr1; diff --git a/src/lib/krb5/krb/addr_srch.c b/src/lib/krb5/krb/addr_srch.c index cc9189f..1988d08 100644 --- a/src/lib/krb5/krb/addr_srch.c +++ b/src/lib/krb5/krb/addr_srch.c @@ -31,7 +31,7 @@ * if addr is listed in addrlist, or addrlist is null, return TRUE. * if not listed, return FALSE */ -krb5_boolean +krb5_boolean INTERFACE krb5_address_search(context, addr, addrlist) krb5_context context; const krb5_address *addr; diff --git a/src/lib/krb5/krb/bld_pr_ext.c b/src/lib/krb5/krb/bld_pr_ext.c index 5d11e2b..753bbb7 100644 --- a/src/lib/krb5/krb/bld_pr_ext.c +++ b/src/lib/krb5/krb/bld_pr_ext.c @@ -34,7 +34,7 @@ #include <varargs.h> #endif -krb5_error_code +krb5_error_code INTERFACE_C #if __STDC__ || defined(STDARG_PROTOTYPES) krb5_build_principal_ext(krb5_context context, krb5_principal * princ, int rlen, const char * realm, ...) #else diff --git a/src/lib/krb5/krb/bld_princ.c b/src/lib/krb5/krb/bld_princ.c index 94dbb72..b82c43a 100644 --- a/src/lib/krb5/krb/bld_princ.c +++ b/src/lib/krb5/krb/bld_princ.c @@ -36,7 +36,7 @@ #include <krb5/ext-proto.h> -krb5_error_code +krb5_error_code INTERFACE_C krb5_build_principal_va(context, princ, rlen, realm, ap) krb5_context context; krb5_principal princ; @@ -99,7 +99,7 @@ krb5_build_principal_va(context, princ, rlen, realm, ap) return 0; } -krb5_error_code +krb5_error_code INTERFACE_C #if __STDC__ || defined(STDARG_PROTOTYPES) krb5_build_principal(krb5_context context, krb5_principal * princ, int rlen, const char * realm, ...) diff --git a/src/lib/krb5/krb/chk_trans.c b/src/lib/krb5/krb/chk_trans.c index 9b2d5b9..b326431 100644 --- a/src/lib/krb5/krb/chk_trans.c +++ b/src/lib/krb5/krb/chk_trans.c @@ -25,7 +25,8 @@ #define MAX_REALM_LN 500 -krb5_error_code krb5_check_transited_list(context, trans, realm1, realm2) +krb5_error_code INTERFACE +krb5_check_transited_list(context, trans, realm1, realm2) krb5_context context; krb5_data *trans; krb5_data *realm1; diff --git a/src/lib/krb5/krb/compat_recv.c b/src/lib/krb5/krb/compat_recv.c index e0276b3..9e986c0 100644 --- a/src/lib/krb5/krb/compat_recv.c +++ b/src/lib/krb5/krb/compat_recv.c @@ -35,6 +35,7 @@ #include <krb5/krb5.h> +#ifndef _MSDOS #include <krb5/osconf.h> #include <krb5/kdb.h> #include <krb5/kdb_dbm.h> @@ -314,3 +315,4 @@ mutual_fail: return(rem); } #endif +#endif diff --git a/src/lib/krb5/krb/conv_princ.c b/src/lib/krb5/krb/conv_princ.c index 2ed3ccf..0013080 100644 --- a/src/lib/krb5/krb/conv_princ.c +++ b/src/lib/krb5/krb/conv_princ.c @@ -99,7 +99,8 @@ static char *strnchr(s, c, n) /* XXX This calls for a new error code */ #define KRB5_INVALID_PRINCIPAL KRB5_LNAME_BADFORMAT -krb5_error_code krb5_524_conv_principal(context, princ, name, inst, realm) +krb5_error_code INTERFACE +krb5_524_conv_principal(context, princ, name, inst, realm) krb5_context context; const krb5_principal princ; char *name; @@ -166,7 +167,8 @@ krb5_error_code krb5_524_conv_principal(context, princ, name, inst, realm) return 0; } -krb5_error_code krb5_425_conv_principal(context, name, instance, realm, princ) +krb5_error_code INTERFACE +krb5_425_conv_principal(context, name, instance, realm, princ) krb5_context context; const char *name; const char *instance; diff --git a/src/lib/krb5/krb/copy_addrs.c b/src/lib/krb5/krb/copy_addrs.c index 1bb0ba6..ad21082 100644 --- a/src/lib/krb5/krb/copy_addrs.c +++ b/src/lib/krb5/krb/copy_addrs.c @@ -52,7 +52,7 @@ krb5_address **outad; /* * Copy an address array, with fresh allocation. */ -krb5_error_code +krb5_error_code INTERFACE krb5_copy_addresses(context, inaddr, outaddr) krb5_context context; krb5_address * const * inaddr; @@ -90,7 +90,7 @@ krb5_copy_addresses(context, inaddr, outaddr) * Note that this function may change the value of *outaddr even if it * returns failure, but it will not change the contents of the list. */ -krb5_error_code +krb5_error_code INTERFACE krb5_append_addresses(context, inaddr, outaddr) krb5_context context; krb5_address * const * inaddr; diff --git a/src/lib/krb5/krb/copy_athctr.c b/src/lib/krb5/krb/copy_athctr.c index 82bb8d7..c303af5 100644 --- a/src/lib/krb5/krb/copy_athctr.c +++ b/src/lib/krb5/krb/copy_athctr.c @@ -29,7 +29,7 @@ #include <krb5/ext-proto.h> -krb5_error_code +krb5_error_code INTERFACE krb5_copy_authenticator(context, authfrom, authto) krb5_context context; const krb5_authenticator *authfrom; diff --git a/src/lib/krb5/krb/copy_auth.c b/src/lib/krb5/krb/copy_auth.c index 830af3a..62b0b61 100644 --- a/src/lib/krb5/krb/copy_auth.c +++ b/src/lib/krb5/krb/copy_auth.c @@ -52,7 +52,7 @@ krb5_authdata **outad; /* * Copy an authdata array, with fresh allocation. */ -krb5_error_code +krb5_error_code INTERFACE krb5_copy_authdata(context, inauthdat, outauthdat) krb5_context context; krb5_authdata * const * inauthdat; diff --git a/src/lib/krb5/krb/copy_cksum.c b/src/lib/krb5/krb/copy_cksum.c index cf04f48..0e1a250 100644 --- a/src/lib/krb5/krb/copy_cksum.c +++ b/src/lib/krb5/krb/copy_cksum.c @@ -29,7 +29,7 @@ #include <krb5/ext-proto.h> -krb5_error_code +krb5_error_code INTERFACE krb5_copy_checksum(context, ckfrom, ckto) krb5_context context; const krb5_checksum *ckfrom; diff --git a/src/lib/krb5/krb/copy_creds.c b/src/lib/krb5/krb/copy_creds.c index 5c14be0..7ac47cc 100644 --- a/src/lib/krb5/krb/copy_creds.c +++ b/src/lib/krb5/krb/copy_creds.c @@ -33,7 +33,7 @@ * Copy credentials, allocating fresh storage where needed. */ -krb5_error_code +krb5_error_code INTERFACE krb5_copy_creds(context, incred, outcred) krb5_context context; const krb5_creds *incred; diff --git a/src/lib/krb5/krb/copy_data.c b/src/lib/krb5/krb/copy_data.c index 669ed3e..9701067 100644 --- a/src/lib/krb5/krb/copy_data.c +++ b/src/lib/krb5/krb/copy_data.c @@ -31,7 +31,7 @@ /* * Copy a data structure, with fresh allocation. */ -krb5_error_code +krb5_error_code INTERFACE krb5_copy_data(context, indata, outdata) krb5_context context; const krb5_data *indata; diff --git a/src/lib/krb5/krb/copy_key.c b/src/lib/krb5/krb/copy_key.c index 305d80d..f714d86 100644 --- a/src/lib/krb5/krb/copy_key.c +++ b/src/lib/krb5/krb/copy_key.c @@ -31,7 +31,7 @@ /* * Copy a keyblock, including alloc'ed storage. */ -krb5_error_code +krb5_error_code INTERFACE krb5_copy_keyblock(context, from, to) krb5_context context; const krb5_keyblock *from; diff --git a/src/lib/krb5/krb/copy_princ.c b/src/lib/krb5/krb/copy_princ.c index 4ccfa25..11dee84 100644 --- a/src/lib/krb5/krb/copy_princ.c +++ b/src/lib/krb5/krb/copy_princ.c @@ -32,7 +32,7 @@ /* * Copy a principal structure, with fresh allocation. */ -krb5_error_code +krb5_error_code INTERFACE krb5_copy_principal(context, inprinc, outprinc) krb5_context context; krb5_const_principal inprinc; diff --git a/src/lib/krb5/krb/copy_tick.c b/src/lib/krb5/krb/copy_tick.c index c4d512b..7ee83f0 100644 --- a/src/lib/krb5/krb/copy_tick.c +++ b/src/lib/krb5/krb/copy_tick.c @@ -94,7 +94,7 @@ krb5_copy_enc_tkt_part(context, partfrom, partto) return 0; } -krb5_error_code +krb5_error_code INTERFACE krb5_copy_ticket(context, from, pto) krb5_context context; const krb5_ticket *from; diff --git a/src/lib/krb5/krb/cp_key_cnt.c b/src/lib/krb5/krb/cp_key_cnt.c index 6b4db98..541562b 100644 --- a/src/lib/krb5/krb/cp_key_cnt.c +++ b/src/lib/krb5/krb/cp_key_cnt.c @@ -31,7 +31,7 @@ /* * Copy a keyblock, including alloc'ed storage. */ -krb5_error_code +krb5_error_code INTERFACE krb5_copy_keyblock_contents(context, from, to) krb5_context context; const krb5_keyblock *from; diff --git a/src/lib/krb5/krb/decode_kdc.c b/src/lib/krb5/krb/decode_kdc.c index dc24be9..a611ea3 100644 --- a/src/lib/krb5/krb/decode_kdc.c +++ b/src/lib/krb5/krb/decode_kdc.c @@ -44,7 +44,7 @@ returns errors from encryption routines, system errors */ -krb5_error_code +krb5_error_code INTERFACE krb5_decode_kdc_rep(context, enc_rep, key, etype, dec_rep) krb5_context context; krb5_data * enc_rep; diff --git a/src/lib/krb5/krb/decrypt_tk.c b/src/lib/krb5/krb/decrypt_tk.c index cd93328..9a31a0b 100644 --- a/src/lib/krb5/krb/decrypt_tk.c +++ b/src/lib/krb5/krb/decrypt_tk.c @@ -40,7 +40,7 @@ */ -krb5_error_code +krb5_error_code INTERFACE krb5_decrypt_tkt_part(context, srv_key, ticket) krb5_context context; const krb5_keyblock *srv_key; diff --git a/src/lib/krb5/krb/encode_kdc.c b/src/lib/krb5/krb/encode_kdc.c index 0918c2c..6550cb4 100644 --- a/src/lib/krb5/krb/encode_kdc.c +++ b/src/lib/krb5/krb/encode_kdc.c @@ -43,7 +43,7 @@ */ /* due to argument promotion rules, we need to use the DECLARG/OLDDECLARG stuff... */ -krb5_error_code +krb5_error_code INTERFACE krb5_encode_kdc_rep(context, type, encpart, eblock, client_key, dec_rep, enc_rep) krb5_context context; const krb5_msgtype type; diff --git a/src/lib/krb5/krb/encrypt_tk.c b/src/lib/krb5/krb/encrypt_tk.c index 80095b4..a363cac 100644 --- a/src/lib/krb5/krb/encrypt_tk.c +++ b/src/lib/krb5/krb/encrypt_tk.c @@ -43,7 +43,7 @@ enc_part->ciphertext.data allocated & filled in with encrypted stuff */ -krb5_error_code +krb5_error_code INTERFACE krb5_encrypt_tkt_part(context, eblock, srv_key, dec_ticket) krb5_context context; krb5_encrypt_block *eblock; diff --git a/src/lib/krb5/krb/faddr_ordr.c b/src/lib/krb5/krb/faddr_ordr.c index e6870d9..f0f1093 100644 --- a/src/lib/krb5/krb/faddr_ordr.c +++ b/src/lib/krb5/krb/faddr_ordr.c @@ -36,7 +36,7 @@ * Return an ordering on the two full addresses: 0 if the same, * < 0 if first is less than 2nd, > 0 if first is greater than 2nd. */ -int +int INTERFACE krb5_fulladdr_order(context, addr1, addr2) krb5_context context; register const krb5_fulladdr *addr1; diff --git a/src/lib/krb5/krb/free_rtree.c b/src/lib/krb5/krb/free_rtree.c index fca10b0..7206bc3 100644 --- a/src/lib/krb5/krb/free_rtree.c +++ b/src/lib/krb5/krb/free_rtree.c @@ -28,7 +28,7 @@ #include <krb5/krb5.h> #include <krb5/ext-proto.h> -void +void INTERFACE krb5_free_realm_tree(context, realms) krb5_context context; krb5_principal *realms; diff --git a/src/lib/krb5/krb/gc_2tgt.c b/src/lib/krb5/krb/gc_2tgt.c index 7503ee7..88f493a 100644 --- a/src/lib/krb5/krb/gc_2tgt.c +++ b/src/lib/krb5/krb/gc_2tgt.c @@ -31,7 +31,7 @@ #include <krb5/ext-proto.h> #include "int-proto.h" -krb5_error_code +krb5_error_code INTERFACE krb5_get_cred_via_2tgt (context, tgt, kdcoptions, sumtype, in_cred, out_cred) krb5_context context; krb5_creds *tgt; diff --git a/src/lib/krb5/krb/gc_frm_kdc.c b/src/lib/krb5/krb/gc_frm_kdc.c index 865d073..72a4578 100644 --- a/src/lib/krb5/krb/gc_frm_kdc.c +++ b/src/lib/krb5/krb/gc_frm_kdc.c @@ -65,7 +65,8 @@ extern krb5_cksumtype krb5_kdc_req_sumtype; #define TGT_ETYPE \ krb5_keytype_array[tgt.keyblock.keytype]->system->proto_enctype; -krb5_error_code krb5_get_cred_from_kdc(context, ccache, in_cred, out_cred, tgts) +krb5_error_code INTERFACE +krb5_get_cred_from_kdc(context, ccache, in_cred, out_cred, tgts) krb5_context context; krb5_ccache ccache; krb5_creds *in_cred; diff --git a/src/lib/krb5/krb/gc_via_tgt.c b/src/lib/krb5/krb/gc_via_tgt.c index 620a50d..11d4dfa 100644 --- a/src/lib/krb5/krb/gc_via_tgt.c +++ b/src/lib/krb5/krb/gc_via_tgt.c @@ -33,7 +33,7 @@ #include <krb5/ext-proto.h> #include "int-proto.h" -krb5_error_code +krb5_error_code INTERFACE krb5_get_cred_via_tgt (context, tgt, kdcoptions, sumtype, in_cred, out_cred) krb5_context context; krb5_creds * tgt; diff --git a/src/lib/krb5/krb/gen_seqnum.c b/src/lib/krb5/krb/gen_seqnum.c index f5ead42..c8d702b 100644 --- a/src/lib/krb5/krb/gen_seqnum.c +++ b/src/lib/krb5/krb/gen_seqnum.c @@ -35,7 +35,7 @@ #define MIN(a,b) ((a) < (b) ? (a) : (b)) #endif -krb5_error_code +krb5_error_code INTERFACE krb5_generate_seq_number(context, key, seqno) krb5_context context; const krb5_keyblock *key; diff --git a/src/lib/krb5/krb/gen_subkey.c b/src/lib/krb5/krb/gen_subkey.c index 68425b2..763c909 100644 --- a/src/lib/krb5/krb/gen_subkey.c +++ b/src/lib/krb5/krb/gen_subkey.c @@ -28,7 +28,7 @@ #include <krb5/krb5.h> #include <krb5/ext-proto.h> -krb5_error_code +krb5_error_code INTERFACE krb5_generate_subkey(context, key, subkey) krb5_context context; const krb5_keyblock *key; diff --git a/src/lib/krb5/krb/get_creds.c b/src/lib/krb5/krb/get_creds.c index 14f44b2..a6c08fe 100644 --- a/src/lib/krb5/krb/get_creds.c +++ b/src/lib/krb5/krb/get_creds.c @@ -43,7 +43,7 @@ #include <krb5/krb5.h> #include <krb5/ext-proto.h> -krb5_error_code +krb5_error_code INTERFACE krb5_get_credentials(context, options, ccache, in_creds, out_creds) krb5_context context; const krb5_flags options; diff --git a/src/lib/krb5/krb/get_fcreds.c b/src/lib/krb5/krb/get_fcreds.c index b5fea08..3a88e77 100644 --- a/src/lib/krb5/krb/get_fcreds.c +++ b/src/lib/krb5/krb/get_fcreds.c @@ -31,6 +31,7 @@ /* libkrb5.a to allow widespread use */ #include <stdio.h> +#ifndef _MSDOS #include <pwd.h> #include <netdb.h> @@ -44,7 +45,7 @@ #define flags2options(flags) (flags & KDC_TKT_COMMON_MASK) /* Get a TGT for use at the remote host */ -krb5_error_code +krb5_error_code INTERFACE krb5_get_for_creds(context, sumtype, rhost, client, enc_key, forwardable, outbuf) krb5_context context; @@ -226,4 +227,4 @@ errout: krb5_free_kdc_rep(context, dec_rep); return retval; } - +#endif diff --git a/src/lib/krb5/krb/get_in_tkt.c b/src/lib/krb5/krb/get_in_tkt.c index 0e72579..6b47622 100644 --- a/src/lib/krb5/krb/get_in_tkt.c +++ b/src/lib/krb5/krb/get_in_tkt.c @@ -60,21 +60,21 @@ extern krb5_deltat krb5_clockskew; -#define in_clock_skew(date) (abs((date)-request.nonce) < krb5_clockskew) +#define in_clock_skew(date) (labs((date)-request.nonce) < krb5_clockskew) /* some typedef's for the function args to make things look a bit cleaner */ -typedef krb5_error_code (*git_key_proc) PROTOTYPE((krb5_context, +typedef krb5_error_code (INTERFACE *git_key_proc) PROTOTYPE((krb5_context, const krb5_keytype, krb5_data *, krb5_const_pointer, krb5_keyblock **)); -typedef krb5_error_code (*git_decrypt_proc) PROTOTYPE((krb5_context, +typedef krb5_error_code (INTERFACE *git_decrypt_proc) PROTOTYPE((krb5_context, const krb5_keyblock *, krb5_const_pointer, krb5_kdc_rep * )); -krb5_error_code +krb5_error_code INTERFACE krb5_get_in_tkt(context, options, addrs, etypes, ptypes, key_proc, keyseed, decrypt_proc, decryptarg, creds, ccache, ret_as_reply) krb5_context context; diff --git a/src/lib/krb5/krb/in_tkt_ktb.c b/src/lib/krb5/krb/in_tkt_ktb.c index 47fd8a9..20df47c 100644 --- a/src/lib/krb5/krb/in_tkt_ktb.c +++ b/src/lib/krb5/krb/in_tkt_ktb.c @@ -38,7 +38,15 @@ struct keytab_keyproc_arg { * "keyseed" is actually a krb5_keytab, or NULL if we should fetch * from system area. */ -static keytab_keyproc(context, type, salt, keyseed, key) +krb5_error_code INTERFACE keytab_keyproc + PROTOTYPE((krb5_context, + const krb5_keytype, + krb5_data *, + krb5_const_pointer, + krb5_keyblock **)); + +krb5_error_code INTERFACE +keytab_keyproc(context, type, salt, keyseed, key) krb5_context context; const krb5_keytype type; krb5_data * salt; @@ -100,7 +108,7 @@ static keytab_keyproc(context, type, salt, keyseed, key) returns system errors, encryption errors */ -krb5_error_code +krb5_error_code INTERFACE krb5_get_in_tkt_with_keytab(context, options, addrs, etypes, pre_auth_types, keytab, ccache, creds, ret_as_reply) krb5_context context; diff --git a/src/lib/krb5/krb/in_tkt_pwd.c b/src/lib/krb5/krb/in_tkt_pwd.c index 1fb3b41..02ea384 100644 --- a/src/lib/krb5/krb/in_tkt_pwd.c +++ b/src/lib/krb5/krb/in_tkt_pwd.c @@ -34,8 +34,14 @@ extern char *krb5_default_pwd_prompt1; /* * key-producing procedure for use by krb5_get_in_tkt_with_password. */ - -static krb5_error_code +krb5_error_code INTERFACE pwd_keyproc + PROTOTYPE((krb5_context, + const krb5_keytype, + krb5_data *, + krb5_const_pointer, + krb5_keyblock **)); + +krb5_error_code INTERFACE pwd_keyproc(context, type, salt, keyseed, key) krb5_context context; const krb5_keytype type; @@ -93,7 +99,7 @@ pwd_keyproc(context, type, salt, keyseed, key) returns system errors, encryption errors */ -krb5_error_code +krb5_error_code INTERFACE krb5_get_in_tkt_with_password(context, options, addrs, etypes, pre_auth_types, password, ccache, creds, ret_as_reply) krb5_context context; diff --git a/src/lib/krb5/krb/in_tkt_sky.c b/src/lib/krb5/krb/in_tkt_sky.c index a0ccb15..54c4a2b 100644 --- a/src/lib/krb5/krb/in_tkt_sky.c +++ b/src/lib/krb5/krb/in_tkt_sky.c @@ -40,6 +40,14 @@ struct skey_keyproc_arg { * "keyseed" is actually a krb5_keyblock *, or NULL if we should fetch * from system area. */ +krb5_error_code INTERFACE skey_keyproc + PROTOTYPE((krb5_context, + const krb5_keytype, + krb5_data *, + krb5_const_pointer, + krb5_keyblock **)); + +krb5_error_code INTERFACE skey_keyproc(context, type, salt, keyseed, key) krb5_context context; const krb5_keytype type; @@ -92,7 +100,7 @@ skey_keyproc(context, type, salt, keyseed, key) returns system errors, encryption errors */ -krb5_error_code +krb5_error_code INTERFACE krb5_get_in_tkt_with_skey(context, options, addrs, etypes, pre_auth_types, key, ccache, creds, ret_as_reply) krb5_context context; diff --git a/src/lib/krb5/krb/init_ctx.c b/src/lib/krb5/krb/init_ctx.c index e3debf0..50c6dac 100644 --- a/src/lib/krb5/krb/init_ctx.c +++ b/src/lib/krb5/krb/init_ctx.c @@ -27,7 +27,7 @@ #include <krb5/los-proto.h> #include <krb5/ext-proto.h> -krb5_error_code +krb5_error_code INTERFACE krb5_init_context(context) krb5_context *context; { @@ -57,7 +57,7 @@ cleanup: return retval; } -void +void INTERFACE krb5_free_context(ctx) krb5_context ctx; { @@ -73,7 +73,7 @@ krb5_free_context(ctx) /* * Set the desired default etypes, making sure they are valid. */ -krb5_error_code +krb5_error_code INTERFACE krb5_set_default_in_tkt_etypes(context, etypes) krb5_context context; const krb5_enctype *etypes; @@ -112,7 +112,7 @@ krb5_set_default_in_tkt_etypes(context, etypes) return 0; } -krb5_error_code +krb5_error_code INTERFACE krb5_get_default_in_tkt_etypes(context, etypes) krb5_context context; krb5_enctype **etypes; @@ -124,7 +124,7 @@ krb5_get_default_in_tkt_etypes(context, etypes) (context->etype_count + 1))) { memcpy(old_etypes, context->etypes, sizeof(krb5_enctype) * context->etype_count); - old_etypes[context->etype_count] = NULL; + old_etypes[context->etype_count] = 0; } else { return ENOMEM; } diff --git a/src/lib/krb5/krb/int-proto.h b/src/lib/krb5/krb/int-proto.h index 0a08e39..e8dafaf 100644 --- a/src/lib/krb5/krb/int-proto.h +++ b/src/lib/krb5/krb/int-proto.h @@ -28,19 +28,19 @@ #ifndef KRB5_INT_FUNC_PROTO__ #define KRB5_INT_FUNC_PROTO__ -krb5_error_code krb5_tgtname +krb5_error_code INTERFACE krb5_tgtname PROTOTYPE((krb5_context context, const krb5_data *, const krb5_data *, krb5_principal *)); -krb5_error_code krb5_get_cred_via_tgt +krb5_error_code INTERFACE krb5_get_cred_via_tgt PROTOTYPE((krb5_context context, krb5_creds *, const krb5_flags, const krb5_cksumtype, krb5_creds *, krb5_creds **)); -krb5_error_code krb5_get_cred_via_2tgt +krb5_error_code INTERFACE krb5_get_cred_via_2tgt PROTOTYPE((krb5_context context, krb5_creds *, const krb5_flags, diff --git a/src/lib/krb5/krb/kdc_rep_dc.c b/src/lib/krb5/krb/kdc_rep_dc.c index 569e088..f8cdc68 100644 --- a/src/lib/krb5/krb/kdc_rep_dc.c +++ b/src/lib/krb5/krb/kdc_rep_dc.c @@ -36,7 +36,7 @@ */ /*ARGSUSED*/ -krb5_error_code +krb5_error_code INTERFACE krb5_kdc_rep_decrypt_proc(context, key, decryptarg, dec_rep) krb5_context context; const krb5_keyblock * key; diff --git a/src/lib/krb5/krb/mk_cred.c b/src/lib/krb5/krb/mk_cred.c index 211437f..668c91f 100644 --- a/src/lib/krb5/krb/mk_cred.c +++ b/src/lib/krb5/krb/mk_cred.c @@ -34,7 +34,7 @@ #include <krb5/asn1.h> /* Create asn.1 encoded KRB-CRED message from the kdc reply. */ -krb5_error_code +krb5_error_code INTERFACE krb5_mk_cred(context, dec_rep, etype, key, sender_addr, recv_addr, outbuf) krb5_context context; krb5_kdc_rep *dec_rep; diff --git a/src/lib/krb5/krb/mk_error.c b/src/lib/krb5/krb/mk_error.c index 5a92a16..0d924aa 100644 --- a/src/lib/krb5/krb/mk_error.c +++ b/src/lib/krb5/krb/mk_error.c @@ -38,7 +38,7 @@ returns system errors */ -krb5_error_code +krb5_error_code INTERFACE krb5_mk_error(context, dec_err, enc_err) krb5_context context; const krb5_error *dec_err; diff --git a/src/lib/krb5/krb/mk_priv.c b/src/lib/krb5/krb/mk_priv.c index df762b2..39832bb 100644 --- a/src/lib/krb5/krb/mk_priv.c +++ b/src/lib/krb5/krb/mk_priv.c @@ -47,7 +47,7 @@ returns system errors */ -krb5_error_code +krb5_error_code INTERFACE krb5_mk_priv(context, userdata, etype, key, sender_addr, recv_addr, seq_number, priv_flags, rcache, i_vector, outbuf) krb5_context context; diff --git a/src/lib/krb5/krb/mk_rep.c b/src/lib/krb5/krb/mk_rep.c index 504d9ca..d76e042 100644 --- a/src/lib/krb5/krb/mk_rep.c +++ b/src/lib/krb5/krb/mk_rep.c @@ -45,7 +45,7 @@ returns system errors */ -krb5_error_code +krb5_error_code INTERFACE krb5_mk_rep(context, repl, kblock, outbuf) krb5_context context; const krb5_ap_rep_enc_part *repl; diff --git a/src/lib/krb5/krb/mk_req.c b/src/lib/krb5/krb/mk_req.c index 178b2dd..2bb89bc 100644 --- a/src/lib/krb5/krb/mk_req.c +++ b/src/lib/krb5/krb/mk_req.c @@ -50,7 +50,7 @@ extern krb5_flags krb5_kdc_default_options; -krb5_error_code +krb5_error_code INTERFACE krb5_mk_req(context, server, ap_req_options, checksum, ccache, outbuf) krb5_context context; krb5_const_principal server; diff --git a/src/lib/krb5/krb/mk_req_ext.c b/src/lib/krb5/krb/mk_req_ext.c index 9b5c060..1f8c98e 100644 --- a/src/lib/krb5/krb/mk_req_ext.c +++ b/src/lib/krb5/krb/mk_req_ext.c @@ -72,7 +72,7 @@ krb5_generate_authenticator PROTOTYPE((krb5_context, const krb5_checksum *, krb5_keyblock *, krb5_int32, krb5_authdata ** )); -krb5_error_code +krb5_error_code INTERFACE krb5_mk_req_extended(context, ap_req_options, checksum, sequence, newkey, in_creds, authentp, outbuf) krb5_context context; diff --git a/src/lib/krb5/krb/mk_safe.c b/src/lib/krb5/krb/mk_safe.c index e50d924..b5b691b 100644 --- a/src/lib/krb5/krb/mk_safe.c +++ b/src/lib/krb5/krb/mk_safe.c @@ -45,7 +45,7 @@ returns system errors */ -krb5_error_code +krb5_error_code INTERFACE krb5_mk_safe(context, userdata, sumtype, key, sender_addr, recv_addr, seq_number, safe_flags, rcache, outbuf) krb5_context context; diff --git a/src/lib/krb5/krb/parse.c b/src/lib/krb5/krb/parse.c index fe051ae..60aea42 100644 --- a/src/lib/krb5/krb/parse.c +++ b/src/lib/krb5/krb/parse.c @@ -64,7 +64,7 @@ * May the fleas of a thousand camels infest the ISO, they who think * that arbitrarily large multi-component names are a Good Thing..... */ -krb5_error_code +krb5_error_code INTERFACE krb5_parse_name(context, name, nprincipal) krb5_context context; const char *name; @@ -190,8 +190,10 @@ krb5_parse_name(context, name, nprincipal) else krb5_princ_component(context, principal, i)->length = size; if (i + 1 != components) { + #ifndef _WINDOWS fprintf(stderr, "Programming error in krb5_parse_name!"); + #endif exit(1); } } else { diff --git a/src/lib/krb5/krb/pr_to_salt.c b/src/lib/krb5/krb/pr_to_salt.c index f920621..2f7beb8 100644 --- a/src/lib/krb5/krb/pr_to_salt.c +++ b/src/lib/krb5/krb/pr_to_salt.c @@ -32,7 +32,7 @@ /* * Convert a krb5_principal into the default salt for that principal. */ -krb5_error_code +krb5_error_code INTERFACE krb5_principal2salt_internal(context, pr, ret, use_realm) krb5_context context; register krb5_const_principal pr; @@ -74,7 +74,7 @@ krb5_principal2salt_internal(context, pr, ret, use_realm) return 0; } -krb5_error_code +krb5_error_code INTERFACE krb5_principal2salt(context, pr, ret) krb5_context context; register krb5_const_principal pr; @@ -83,7 +83,7 @@ krb5_principal2salt(context, pr, ret) return krb5_principal2salt_internal(context, pr, ret, 1); } -krb5_error_code +krb5_error_code INTERFACE krb5_principal2salt_norealm(context, pr, ret) krb5_context context; register krb5_const_principal pr; diff --git a/src/lib/krb5/krb/preauth.c b/src/lib/krb5/krb/preauth.c index e03d24c..e4992a4 100644 --- a/src/lib/krb5/krb/preauth.c +++ b/src/lib/krb5/krb/preauth.c @@ -76,7 +76,7 @@ static krb5_error_code find_preauthenticator * * Note: This is a first crack at what any preauthentication will need... */ -krb5_error_code +krb5_error_code INTERFACE krb5_obtain_padata(context, type, client, src_addr, encrypt_key, ret_data) krb5_context context; int type; /*IN: Preauth type */ @@ -182,7 +182,7 @@ error_out: * Note: This is a first crack at what any preauthentication will need... */ -krb5_error_code +krb5_error_code INTERFACE krb5_verify_padata(context, data,client,src_addr, decrypt_key, req_id, flags) krb5_context context; krb5_pa_data *data; /*IN: padata */ @@ -307,7 +307,7 @@ find_preauthenticator(type, preauth) */ int seeded = 0 ; /* Used by srand below */ -krb5_error_code +krb5_error_code INTERFACE get_unixtime_padata(context, client, src_addr, pa_data) krb5_context context; krb5_principal client; @@ -344,7 +344,7 @@ get_unixtime_padata(context, client, src_addr, pa_data) return(0); } -krb5_error_code +krb5_error_code INTERFACE verify_unixtime_padata(context, client, src_addr, data) krb5_context context; krb5_principal client; @@ -355,7 +355,7 @@ verify_unixtime_padata(context, client, src_addr, data) krb5_error_code retval; krb5_timestamp currenttime, patime; extern krb5_deltat krb5_clockskew; -#define in_clock_skew(date) (abs((date)-currenttime) < krb5_clockskew) +#define in_clock_skew(date) (labs((date)-currenttime) < krb5_clockskew) tmp = (unsigned char *) data->data; if (tmp[8] != 0) @@ -379,7 +379,7 @@ verify_unixtime_padata(context, client, src_addr, data) #include "sdcli.h" #include "sdconf.c" -krb5_error_code +krb5_error_code INTERFACE verify_securid_padata(client, src_addr, data) krb5_principal client; krb5_address **src_addr; @@ -427,7 +427,7 @@ verify_securid_padata(client, src_addr, data) } } #else -krb5_error_code +krb5_error_code INTERFACE verify_securid_padata(context, client, src_addr, data) krb5_context context; krb5_principal client; @@ -451,7 +451,7 @@ static char *krb5_SecureId_prompt = "\nEnter Your SecurId Access Code Prepended */ static char *krb5_SecureId_prompt = "\nEnter Your SecurId Access Code Prepended with Your PIN\n (or a \'#\'if Your PIN is entered on the card keypad): "; -krb5_error_code +krb5_error_code INTERFACE get_securid_padata(context, client,src_addr,pa_data) krb5_context context; krb5_principal client; diff --git a/src/lib/krb5/krb/princ_comp.c b/src/lib/krb5/krb/princ_comp.c index 7697707..7000ed8 100644 --- a/src/lib/krb5/krb/princ_comp.c +++ b/src/lib/krb5/krb/princ_comp.c @@ -29,7 +29,7 @@ #include <krb5/krb5.h> #include <krb5/ext-proto.h> -krb5_boolean +krb5_boolean INTERFACE krb5_realm_compare(context, princ1, princ2) krb5_context context; krb5_const_principal princ1; @@ -45,7 +45,7 @@ krb5_realm_compare(context, princ1, princ2) return TRUE; } -krb5_boolean +krb5_boolean INTERFACE krb5_principal_compare(context, princ1, princ2) krb5_context context; krb5_const_principal princ1; diff --git a/src/lib/krb5/krb/rd_cred.c b/src/lib/krb5/krb/rd_cred.c index dd7b3a6..1316be8 100644 --- a/src/lib/krb5/krb/rd_cred.c +++ b/src/lib/krb5/krb/rd_cred.c @@ -33,10 +33,10 @@ #include <krb5/asn1.h> extern krb5_deltat krb5_clockskew; -#define in_clock_skew(date) (abs((date)-currenttime) < krb5_clockskew) +#define in_clock_skew(date) (labs((date)-currenttime) < krb5_clockskew) /* Decode the KRB-CRED message, and return creds */ -krb5_error_code +krb5_error_code INTERFACE krb5_rd_cred(context, inbuf, key, creds, sender_addr, recv_addr) krb5_context context; const krb5_data *inbuf; diff --git a/src/lib/krb5/krb/rd_error.c b/src/lib/krb5/krb/rd_error.c index c30310d..29a3723 100644 --- a/src/lib/krb5/krb/rd_error.c +++ b/src/lib/krb5/krb/rd_error.c @@ -41,7 +41,7 @@ * returns system errors */ -krb5_error_code +krb5_error_code INTERFACE krb5_rd_error(context, enc_errbuf, dec_error) krb5_context context; const krb5_data *enc_errbuf; diff --git a/src/lib/krb5/krb/rd_priv.c b/src/lib/krb5/krb/rd_priv.c index 08cda45..199d46d 100644 --- a/src/lib/krb5/krb/rd_priv.c +++ b/src/lib/krb5/krb/rd_priv.c @@ -32,7 +32,7 @@ #include <krb5/ext-proto.h> extern krb5_deltat krb5_clockskew; -#define in_clock_skew(date) (abs((date)-currenttime) < krb5_clockskew) +#define in_clock_skew(date) (labs((date)-currenttime) < krb5_clockskew) /* @@ -55,7 +55,7 @@ Returns system errors, integrity errors. */ -krb5_error_code +krb5_error_code INTERFACE krb5_rd_priv(context, inbuf, key, sender_addr, recv_addr, seq_number, priv_flags, i_vector, rcache, outbuf) krb5_context context; diff --git a/src/lib/krb5/krb/rd_rep.c b/src/lib/krb5/krb/rd_rep.c index 13a49c7..779fbad 100644 --- a/src/lib/krb5/krb/rd_rep.c +++ b/src/lib/krb5/krb/rd_rep.c @@ -41,7 +41,7 @@ * returns system errors, encryption errors, replay errors */ -krb5_error_code +krb5_error_code INTERFACE krb5_rd_rep(context, inbuf, kblock, repl) krb5_context context; const krb5_data *inbuf; diff --git a/src/lib/krb5/krb/rd_req.c b/src/lib/krb5/krb/rd_req.c index 467f0e0..97e5a38 100644 --- a/src/lib/krb5/krb/rd_req.c +++ b/src/lib/krb5/krb/rd_req.c @@ -54,7 +54,7 @@ * returns system errors, encryption errors, replay errors */ -krb5_error_code +krb5_error_code INTERFACE krb5_rd_req(context, inbuf, server, sender_addr, fetchfrom, keyproc, keyprocarg, rcache, authdat) krb5_context context; diff --git a/src/lib/krb5/krb/rd_req_dec.c b/src/lib/krb5/krb/rd_req_dec.c index 21aee09..1963126 100644 --- a/src/lib/krb5/krb/rd_req_dec.c +++ b/src/lib/krb5/krb/rd_req_dec.c @@ -66,9 +66,9 @@ static krb5_error_code decrypt_authenticator PROTOTYPE((krb5_context, const krb5_ap_req *, krb5_authenticator **)); extern krb5_deltat krb5_clockskew; -#define in_clock_skew(date) (abs((date)-currenttime) < krb5_clockskew) +#define in_clock_skew(date) (labs((date)-currenttime) < krb5_clockskew) -krb5_error_code +krb5_error_code INTERFACE krb5_rd_req_decoded(context, req, server, sender_addr, fetchfrom, keyproc, keyprocarg, rcache, authdat) krb5_context context; diff --git a/src/lib/krb5/krb/rd_req_sim.c b/src/lib/krb5/krb/rd_req_sim.c index 24a2515..f2db248 100644 --- a/src/lib/krb5/krb/rd_req_sim.c +++ b/src/lib/krb5/krb/rd_req_sim.c @@ -48,7 +48,7 @@ * returns system errors, encryption errors, replay errors */ -krb5_error_code +krb5_error_code INTERFACE krb5_rd_req_simple(context, inbuf, server, sender_addr, authdat) krb5_context context; const krb5_data *inbuf; diff --git a/src/lib/krb5/krb/rd_safe.c b/src/lib/krb5/krb/rd_safe.c index 1844a67..2bdcdf4 100644 --- a/src/lib/krb5/krb/rd_safe.c +++ b/src/lib/krb5/krb/rd_safe.c @@ -31,7 +31,7 @@ #include <krb5/ext-proto.h> extern krb5_deltat krb5_clockskew; -#define in_clock_skew(date) (abs((date)-currenttime) < krb5_clockskew) +#define in_clock_skew(date) (labs((date)-currenttime) < krb5_clockskew) /* parses a KRB_SAFE message from inbuf, placing the integrity-protected user @@ -46,7 +46,7 @@ extern krb5_deltat krb5_clockskew; returns system errors, integrity errors */ -krb5_error_code +krb5_error_code INTERFACE krb5_rd_safe(context, inbuf, key, sender_addr, recv_addr, seq_number, safe_flags, rcache, outbuf) krb5_context context; diff --git a/src/lib/krb5/krb/recvauth.c b/src/lib/krb5/krb/recvauth.c index 3f682d3..2cd87c9 100644 --- a/src/lib/krb5/krb/recvauth.c +++ b/src/lib/krb5/krb/recvauth.c @@ -26,6 +26,7 @@ #include <krb5/krb5.h> +#ifndef _MSDOS #include <krb5/osconf.h> #include <krb5/kdb.h> #include <krb5/kdb_dbm.h> @@ -42,7 +43,7 @@ extern krb5_flags krb5_kdc_default_options; static char *sendauth_version = "KRB5_SENDAUTH_V1.0"; -krb5_error_code +krb5_error_code INTERFACE krb5_recvauth(context, /* IN */ fd, appl_version, server, sender_addr, fetch_from, @@ -322,4 +323,4 @@ krb5_recvauth(context, return 0; } - +#endif diff --git a/src/lib/krb5/krb/send_tgs.c b/src/lib/krb5/krb/send_tgs.c index a5e118d..8b2d8d4 100644 --- a/src/lib/krb5/krb/send_tgs.c +++ b/src/lib/krb5/krb/send_tgs.c @@ -48,7 +48,7 @@ returns system errors */ -krb5_error_code +krb5_error_code INTERFACE krb5_send_tgs(context, kdcoptions, timestruct, etypes, sumtype, sname, addrs, authorization_data, padata, second_ticket, in_cred, rep) krb5_context context; @@ -58,7 +58,7 @@ krb5_send_tgs(context, kdcoptions, timestruct, etypes, sumtype, sname, addrs, const krb5_cksumtype sumtype; krb5_const_principal sname; krb5_address * const * addrs; - krb5_authdata * const * authorization_data; + const krb5_authdata ** authorization_data; krb5_pa_data * const * padata; const krb5_data * second_ticket; krb5_creds * in_cred; diff --git a/src/lib/krb5/krb/sendauth.c b/src/lib/krb5/krb/sendauth.c index f5a1394..2f67f30 100644 --- a/src/lib/krb5/krb/sendauth.c +++ b/src/lib/krb5/krb/sendauth.c @@ -36,7 +36,9 @@ #include <stdio.h> #include <string.h> -#include <netinet/in.h> +#ifdef _MSDOS +#define ECONNABORTED 53 +#endif #define WORKING_RCACHE @@ -44,7 +46,7 @@ extern krb5_flags krb5_kdc_default_options; static char *sendauth_version = "KRB5_SENDAUTH_V1.0"; -krb5_error_code +krb5_error_code INTERFACE krb5_sendauth(context, /* IN */ fd, appl_version, client, server, ap_req_options, checksump, diff --git a/src/lib/krb5/krb/srv_rcache.c b/src/lib/krb5/krb/srv_rcache.c index 63f5478..39bb229 100644 --- a/src/lib/krb5/krb/srv_rcache.c +++ b/src/lib/krb5/krb/srv_rcache.c @@ -30,7 +30,7 @@ #include <ctype.h> #include <stdio.h> -krb5_error_code +krb5_error_code INTERFACE krb5_get_server_rcache(context, piece, rcptr) krb5_context context; const krb5_data *piece; diff --git a/src/lib/krb5/krb/tgtname.c b/src/lib/krb5/krb/tgtname.c index 7b342a1..e6cf43c 100644 --- a/src/lib/krb5/krb/tgtname.c +++ b/src/lib/krb5/krb/tgtname.c @@ -30,7 +30,7 @@ /* This is an internal-only function, used by krb5_get_cred_from_kdc() */ -krb5_error_code +krb5_error_code INTERFACE krb5_tgtname(context, server, client, tgtprinc) krb5_context context; const krb5_data *server, *client; diff --git a/src/lib/krb5/krb/unparse.c b/src/lib/krb5/krb/unparse.c index 7c29f84..f817450 100644 --- a/src/lib/krb5/krb/unparse.c +++ b/src/lib/krb5/krb/unparse.c @@ -55,7 +55,7 @@ #define REALM_SEP '@' #define COMPONENT_SEP '/' -krb5_error_code +krb5_error_code INTERFACE krb5_unparse_name_ext(context, principal, name, size) krb5_context context; krb5_const_principal principal; @@ -174,7 +174,7 @@ krb5_unparse_name_ext(context, principal, name, size) return 0; } -krb5_error_code +krb5_error_code INTERFACE krb5_unparse_name(context, principal, name) krb5_context context; krb5_const_principal principal; diff --git a/src/lib/krb5/krb/walk_rtree.c b/src/lib/krb5/krb/walk_rtree.c index c3170d2..38fa355 100644 --- a/src/lib/krb5/krb/walk_rtree.c +++ b/src/lib/krb5/krb/walk_rtree.c @@ -36,11 +36,12 @@ #define max(x,y) ((x) > (y) ? (x) : (y)) #endif -krb5_error_code +krb5_error_code INTERFACE krb5_walk_realm_tree(context, client, server, tree, realm_branch_char) krb5_context context; const krb5_data *client, *server; krb5_principal **tree; + int realm_branch_char; { krb5_error_code retval; krb5_principal *rettree; |