From: Theodore Tso Date: Sat, 18 Nov 1995 03:11:26 +0000 (+0000) Subject: Renamed filenames so they would be unique in an 8.3 filesystem. Added X-Git-Tag: krb5-1.0-beta6~792 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=b0ee9d6d0167c55479bdb55bfbe1c22ab9355d6c;p=krb5.git Renamed filenames so they would be unique in an 8.3 filesystem. Added GSSAPI V2 functions to mechglueP.h (now mglueP.h) git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@7114 dc483132-0cff-0310-8789-dd5450dbe970 --- diff --git a/src/lib/gssapi/mechglue/Makefile.in b/src/lib/gssapi/mechglue/Makefile.in index b32292f94..90cbd7b58 100644 --- a/src/lib/gssapi/mechglue/Makefile.in +++ b/src/lib/gssapi/mechglue/Makefile.in @@ -8,72 +8,80 @@ CFLAGS = $(CCOPTS) $(DEFS) -I. -I$(srcdir) LIBDONE=DONE LIB_SUBDIRSS=. -SRCS = gss_acquire_cred.c \ - gss_release_cred.c \ - gss_init_sec_context.c \ - gss_accept_sec_context.c \ - gss_process_context.c \ - gss_delete_sec_context.c \ - gss_context_time.c \ - gss_sign.c \ - gss_verify.c \ - gss_seal.c \ - gss_unseal.c \ - gss_display_status.c \ - gss_indicate_mechs.c \ - gss_compare_name.c \ - gss_display_name.c \ - gss_import_name.c \ - gss_release_name.c \ - gss_release_buffer.c \ - gss_release_oid_set.c \ - gss_inquire_cred.c \ - gss_initialize.c \ - get_mech_type.c \ +SRCS = g_acquire_cred.c \ + g_rel_cred.c \ + g_init_sec_context.c \ + g_accept_sec_context.c \ + g_process_context.c \ + g_delete_sec_context.c \ + g_context_time.c \ + g_sign.c \ + g_verify.c \ + g_seal.c \ + g_unseal.c \ + g_dsp_status.c \ + g_indicate_mechs.c \ + g_compare_name.c \ + g_dsp_name.c \ + g_imp_name.c \ + g_rel_name.c \ + g_rel_buffer.c \ + g_rel_oid_set.c \ + g_inquire_cred.c \ + g_initialize.c \ + get_mtype.c \ get_mechanism.c \ internal_name.c \ gssd_pname_to_uid.c \ add_mechanism.c -OBJS = gss_acquire_cred.$(OBJEXT) \ - gss_release_cred.$(OBJEXT) \ - gss_init_sec_context.$(OBJEXT) \ - gss_accept_sec_context.$(OBJEXT) \ - gss_process_context.$(OBJEXT) \ - gss_delete_sec_context.$(OBJEXT) \ - gss_context_time.$(OBJEXT) \ - gss_sign.$(OBJEXT) \ - gss_verify.$(OBJEXT) \ - gss_seal.$(OBJEXT) \ - gss_unseal.$(OBJEXT) \ - gss_display_status.$(OBJEXT) \ - gss_indicate_mechs.$(OBJEXT) \ - gss_compare_name.$(OBJEXT) \ - gss_display_name.$(OBJEXT) \ - gss_import_name.$(OBJEXT) \ - gss_release_name.$(OBJEXT) \ - gss_release_buffer.$(OBJEXT) \ - gss_release_oid_set.$(OBJEXT) \ - gss_inquire_cred.$(OBJEXT) \ - gss_initialize.$(OBJEXT) \ - get_mech_type.$(OBJEXT) \ +OBJS = g_acquire_cred.$(OBJEXT) \ + g_rel_cred.$(OBJEXT) \ + g_init_sec_context.$(OBJEXT) \ + g_accept_sec_context.$(OBJEXT) \ + g_process_context.$(OBJEXT) \ + g_delete_sec_context.$(OBJEXT) \ + g_context_time.$(OBJEXT) \ + g_sign.$(OBJEXT) \ + g_verify.$(OBJEXT) \ + g_seal.$(OBJEXT) \ + g_unseal.$(OBJEXT) \ + g_dsp_status.$(OBJEXT) \ + g_indicate_mechs.$(OBJEXT) \ + g_compare_name.$(OBJEXT) \ + g_dsp_name.$(OBJEXT) \ + g_imp_name.$(OBJEXT) \ + g_rel_name.$(OBJEXT) \ + g_rel_buffer.$(OBJEXT) \ + g_rel_oid_set.$(OBJEXT) \ + g_inquire_cred.$(OBJEXT) \ + g_initialize.$(OBJEXT) \ + get_mtype.$(OBJEXT) \ get_mechanism.$(OBJEXT) \ internal_name.$(OBJEXT) \ gssd_pname_to_uid.$(OBJEXT) \ add_mechanism.$(OBJEXT) +EHDRDIR= $(BUILDTOP)$(S)include$(S)gssapi EXPORTED_HEADERS = mechglue.h -all:: all-$(WHAT) $(OBJS) +.c.o: + $(CC) $(CFLAGS) -c $(srcdir)/$*.c +@SHARED_RULE@ -all-unix:: +all:: all-$(WHAT) -all-mac:: +all-unix:: shared includes $(OBJS) -all-windows:: +all-mac:: shared includes $(OBJS) + +all-windows:: includes $(OBJS) if not exist $(EHDRDIR)\nul mkdir $(EHDRDIR) copy mechglue.h $(EHDRDIR) +shared: + mkdir shared + unixmac: libgssapi.$(LIBEXT): $(OBJS) @@ -83,8 +91,10 @@ libgssapi.$(LIBEXT): $(OBJS) clean:: clean-$(WHAT) clean-unix:: + $(RM) shared/* clean-mac:: + $(RM) shared/* clean-windows:: $(RM) $(EHDRDIR)\gssapi.h $(EHDRDIR)\gssapi_generic.h @@ -96,3 +106,5 @@ install:: do $(INSTALL_DATA) $(srcdir)$(S)$$f \ $(DESTDIR)$(KRB5_INCDIR)$(S)gssapi$(S)$$f ; \ done + +includes:: diff --git a/src/lib/gssapi/mechglue/add_mechanism.c b/src/lib/gssapi/mechglue/add_mechanism.c index fa5ea5322..398f0503f 100644 --- a/src/lib/gssapi/mechglue/add_mechanism.c +++ b/src/lib/gssapi/mechglue/add_mechanism.c @@ -6,7 +6,7 @@ * All rights reserved. */ -#include "mechglueP.h" +#include "mglueP.h" #include static struct gss_config null_mech = { diff --git a/src/lib/gssapi/mechglue/configure.in b/src/lib/gssapi/mechglue/configure.in index 3cd9048db..755d6e2a5 100644 --- a/src/lib/gssapi/mechglue/configure.in +++ b/src/lib/gssapi/mechglue/configure.in @@ -3,9 +3,11 @@ CONFIG_RULES AC_PROG_ARCHIVE AC_PROG_RANLIB AC_PROG_INSTALL +V5_SHARED_LIB_OBJS +SubdirLibraryRule([${OBJS}]) CopySrcHeader(mechglue.h,[$(EHDRDIR)]) -AppendRule([install:: libgssapi.[$](LIBEXT) - [$](INSTALL_DATA) libgssapi.[$](LIBEXT) [$](DESTDIR)[$](KRB5_LIBDIR)[$](S)libgssapi.[$](LIBEXT)]) -LinkFileDir([$](TOPLIBD)/libgssapi.[$](LIBEXT),libgssapi.[$](LIBEXT),./gssapi/mechglue) -AppendRule([all:: [$](TOPLIBD)/libgssapi.[$](LIBEXT)]) +dnl AppendRule([install:: libgssapi.[$](LIBEXT) +dnl [$](INSTALL_DATA) libgssapi.[$](LIBEXT) [$](DESTDIR)[$](KRB5_LIBDIR)[$](S)libgssapi.[$](LIBEXT)]) +dnl LinkFileDir([$](TOPLIBD)/libgssapi.[$](LIBEXT),libgssapi.[$](LIBEXT),./gssapi/mechglue) +dnl AppendRule([all:: [$](TOPLIBD)/libgssapi.[$](LIBEXT)]) V5_AC_OUTPUT_MAKEFILE diff --git a/src/lib/gssapi/mechglue/gss_accept_sec_context.c b/src/lib/gssapi/mechglue/g_accept_sec_context.c similarity index 99% rename from src/lib/gssapi/mechglue/gss_accept_sec_context.c rename to src/lib/gssapi/mechglue/g_accept_sec_context.c index e9fd1193c..31162d842 100644 --- a/src/lib/gssapi/mechglue/gss_accept_sec_context.c +++ b/src/lib/gssapi/mechglue/g_accept_sec_context.c @@ -6,7 +6,7 @@ * All rights reserved. */ -#include "mechglueP.h" +#include "mglueP.h" OM_uint32 gss_accept_sec_context (minor_status, @@ -29,7 +29,7 @@ gss_channel_bindings_t input_chan_bindings; gss_name_t * src_name; gss_OID * mech_type; gss_buffer_t output_token; -int * ret_flags; +OM_uint32 * ret_flags; OM_uint32 * time_rec; gss_cred_id_t * delegated_cred_handle; diff --git a/src/lib/gssapi/mechglue/gss_acquire_cred.c b/src/lib/gssapi/mechglue/g_acquire_cred.c similarity index 99% rename from src/lib/gssapi/mechglue/gss_acquire_cred.c rename to src/lib/gssapi/mechglue/g_acquire_cred.c index 3b1c5680b..111819be6 100644 --- a/src/lib/gssapi/mechglue/gss_acquire_cred.c +++ b/src/lib/gssapi/mechglue/g_acquire_cred.c @@ -6,7 +6,7 @@ * All rights reserved. */ -#include "mechglueP.h" +#include "mglueP.h" OM_uint32 gss_acquire_cred(minor_status, @@ -62,7 +62,7 @@ OM_uint32 * time_rec; if (minor_status) *minor_status = 0; - if (desired_name == GSS_C_NO_NAME) + if (desired_name == 0) return GSS_S_BAD_NAME; /* No need to continue if we don't have a place to store the creds */ diff --git a/src/lib/gssapi/mechglue/gss_compare_name.c b/src/lib/gssapi/mechglue/g_compare_name.c similarity index 95% rename from src/lib/gssapi/mechglue/gss_compare_name.c rename to src/lib/gssapi/mechglue/g_compare_name.c index b07ace599..e521004ab 100644 --- a/src/lib/gssapi/mechglue/gss_compare_name.c +++ b/src/lib/gssapi/mechglue/g_compare_name.c @@ -6,7 +6,7 @@ * All rights reserved. */ -#include "mechglueP.h" +#include "mglueP.h" OM_uint32 gss_compare_name (minor_status, @@ -25,7 +25,7 @@ int * name_equal; gss_initialize(); - if (name1 == GSS_C_NO_NAME || name2 == GSS_C_NO_NAME) { + if (name1 == 0 || name2 == 0) { if (name_equal) *name_equal = 0; return GSS_S_BAD_NAME; diff --git a/src/lib/gssapi/mechglue/gss_context_time.c b/src/lib/gssapi/mechglue/g_context_time.c similarity index 97% rename from src/lib/gssapi/mechglue/gss_context_time.c rename to src/lib/gssapi/mechglue/g_context_time.c index efcd5d607..775fd04b2 100644 --- a/src/lib/gssapi/mechglue/gss_context_time.c +++ b/src/lib/gssapi/mechglue/g_context_time.c @@ -6,7 +6,7 @@ * All rights reserved. */ -#include "mechglueP.h" +#include "mglueP.h" OM_uint32 gss_context_time (minor_status, diff --git a/src/lib/gssapi/mechglue/gss_delete_sec_context.c b/src/lib/gssapi/mechglue/g_delete_sec_context.c similarity index 98% rename from src/lib/gssapi/mechglue/gss_delete_sec_context.c rename to src/lib/gssapi/mechglue/g_delete_sec_context.c index 69866bd04..6bc3c2be6 100644 --- a/src/lib/gssapi/mechglue/gss_delete_sec_context.c +++ b/src/lib/gssapi/mechglue/g_delete_sec_context.c @@ -6,7 +6,7 @@ * All rights reserved. */ -#include "mechglueP.h" +#include "mglueP.h" OM_uint32 gss_delete_sec_context (minor_status, diff --git a/src/lib/gssapi/mechglue/gss_display_name.c b/src/lib/gssapi/mechglue/g_dsp_name.c similarity index 95% rename from src/lib/gssapi/mechglue/gss_display_name.c rename to src/lib/gssapi/mechglue/g_dsp_name.c index 4f1a27861..0009efdce 100644 --- a/src/lib/gssapi/mechglue/gss_display_name.c +++ b/src/lib/gssapi/mechglue/g_dsp_name.c @@ -6,7 +6,7 @@ * All rights reserved. */ -#include "mechglueP.h" +#include "mglueP.h" OM_uint32 gss_display_name (minor_status, @@ -28,7 +28,7 @@ gss_OID * output_name_type; * to the name_type component of union_name */ - if (input_name == GSS_C_NO_NAME) + if (input_name == 0) return GSS_S_BAD_NAME; union_name = (gss_union_name_t) input_name; diff --git a/src/lib/gssapi/mechglue/gss_display_status.c b/src/lib/gssapi/mechglue/g_dsp_status.c similarity index 91% rename from src/lib/gssapi/mechglue/gss_display_status.c rename to src/lib/gssapi/mechglue/g_dsp_status.c index 43decb6ba..29542df2c 100644 --- a/src/lib/gssapi/mechglue/gss_display_status.c +++ b/src/lib/gssapi/mechglue/g_dsp_status.c @@ -6,7 +6,7 @@ * All rights reserved. */ -#include "mechglueP.h" +#include "mglueP.h" OM_uint32 gss_display_status (minor_status, @@ -17,10 +17,10 @@ gss_display_status (minor_status, status_string) OM_uint32 * minor_status; -int status_value; +OM_uint32 status_value; int status_type; -const_gss_OID req_mech_type; -int * message_context; +gss_OID req_mech_type; +OM_uint32 * message_context; gss_buffer_t status_string; { diff --git a/src/lib/gssapi/mechglue/gss_import_name.c b/src/lib/gssapi/mechglue/g_imp_name.c similarity index 96% rename from src/lib/gssapi/mechglue/gss_import_name.c rename to src/lib/gssapi/mechglue/g_imp_name.c index 6ec428df2..4f22fe0e5 100644 --- a/src/lib/gssapi/mechglue/gss_import_name.c +++ b/src/lib/gssapi/mechglue/g_imp_name.c @@ -6,7 +6,7 @@ * All rights reserved. */ -#include "mechglueP.h" +#include "mglueP.h" OM_uint32 gss_import_name(minor_status, @@ -16,7 +16,7 @@ gss_import_name(minor_status, OM_uint32 * minor_status; gss_buffer_t input_name_buffer; -const_gss_OID input_name_type; +gss_OID input_name_type; gss_name_t * output_name; { diff --git a/src/lib/gssapi/mechglue/gss_indicate_mechs.c b/src/lib/gssapi/mechglue/g_indicate_mechs.c similarity index 98% rename from src/lib/gssapi/mechglue/gss_indicate_mechs.c rename to src/lib/gssapi/mechglue/g_indicate_mechs.c index 3b8183e10..3071f569a 100644 --- a/src/lib/gssapi/mechglue/gss_indicate_mechs.c +++ b/src/lib/gssapi/mechglue/g_indicate_mechs.c @@ -6,7 +6,7 @@ * All rights reserved. */ -#include "mechglueP.h" +#include "mglueP.h" extern gss_mechanism *mechs_array; diff --git a/src/lib/gssapi/mechglue/gss_init_sec_context.c b/src/lib/gssapi/mechglue/g_init_sec_context.c similarity index 94% rename from src/lib/gssapi/mechglue/gss_init_sec_context.c rename to src/lib/gssapi/mechglue/g_init_sec_context.c index ed6f81fbb..8899386c7 100644 --- a/src/lib/gssapi/mechglue/gss_init_sec_context.c +++ b/src/lib/gssapi/mechglue/g_init_sec_context.c @@ -6,7 +6,7 @@ * All rights reserved. */ -#include "mechglueP.h" +#include "mglueP.h" OM_uint32 gss_init_sec_context (minor_status, @@ -23,19 +23,19 @@ gss_init_sec_context (minor_status, ret_flags, time_rec) -OM_uint32 * minor_status; +OM_uint32 FAR * minor_status; gss_cred_id_t claimant_cred_handle; gss_ctx_id_t * context_handle; gss_name_t target_name; -const_gss_OID req_mech_type; -int req_flags; -int time_req; +gss_OID req_mech_type; +OM_uint32 req_flags; +OM_uint32 time_req; gss_channel_bindings_t input_chan_bindings; gss_buffer_t input_token; -gss_OID * actual_mech_type; +gss_OID FAR * actual_mech_type; gss_buffer_t output_token; -int * ret_flags; -OM_uint32 * time_rec; +OM_uint32 FAR * ret_flags; +OM_uint32 FAR * time_rec; { OM_uint32 status, temp_status, temp_minor_status; diff --git a/src/lib/gssapi/mechglue/gss_initialize.c b/src/lib/gssapi/mechglue/g_initialize.c similarity index 97% rename from src/lib/gssapi/mechglue/gss_initialize.c rename to src/lib/gssapi/mechglue/g_initialize.c index a6e7ed101..5081b1a28 100644 --- a/src/lib/gssapi/mechglue/gss_initialize.c +++ b/src/lib/gssapi/mechglue/g_initialize.c @@ -6,7 +6,7 @@ * All rights reserved. */ -#include "mechglueP.h" +#include "mglueP.h" static int _gss_initialized = 0; diff --git a/src/lib/gssapi/mechglue/gss_inquire_cred.c b/src/lib/gssapi/mechglue/g_inquire_cred.c similarity index 99% rename from src/lib/gssapi/mechglue/gss_inquire_cred.c rename to src/lib/gssapi/mechglue/g_inquire_cred.c index 460e8c3ae..9d1697aa0 100644 --- a/src/lib/gssapi/mechglue/gss_inquire_cred.c +++ b/src/lib/gssapi/mechglue/g_inquire_cred.c @@ -6,7 +6,7 @@ * All rights reserved. */ -#include "mechglueP.h" +#include "mglueP.h" OM_uint32 gss_inquire_cred(minor_status, diff --git a/src/lib/gssapi/mechglue/gss_process_context.c b/src/lib/gssapi/mechglue/g_process_context.c similarity index 97% rename from src/lib/gssapi/mechglue/gss_process_context.c rename to src/lib/gssapi/mechglue/g_process_context.c index e44e41649..75ecb32c3 100644 --- a/src/lib/gssapi/mechglue/gss_process_context.c +++ b/src/lib/gssapi/mechglue/g_process_context.c @@ -6,7 +6,7 @@ * All rights reserved. */ -#include "mechglueP.h" +#include "mglueP.h" OM_uint32 gss_process_context_token (minor_status, diff --git a/src/lib/gssapi/mechglue/gss_release_buffer.c b/src/lib/gssapi/mechglue/g_rel_buffer.c similarity index 96% rename from src/lib/gssapi/mechglue/gss_release_buffer.c rename to src/lib/gssapi/mechglue/g_rel_buffer.c index 99ed4d5a8..86a13d506 100644 --- a/src/lib/gssapi/mechglue/gss_release_buffer.c +++ b/src/lib/gssapi/mechglue/g_rel_buffer.c @@ -6,7 +6,7 @@ * All rights reserved. */ -#include "mechglueP.h" +#include "mglueP.h" OM_uint32 gss_release_buffer (minor_status, diff --git a/src/lib/gssapi/mechglue/gss_release_cred.c b/src/lib/gssapi/mechglue/g_rel_cred.c similarity index 98% rename from src/lib/gssapi/mechglue/gss_release_cred.c rename to src/lib/gssapi/mechglue/g_rel_cred.c index 2ef94276c..f5df0dffa 100644 --- a/src/lib/gssapi/mechglue/gss_release_cred.c +++ b/src/lib/gssapi/mechglue/g_rel_cred.c @@ -6,7 +6,7 @@ * All rights reserved. */ -#include "mechglueP.h" +#include "mglueP.h" OM_uint32 gss_release_cred(minor_status, diff --git a/src/lib/gssapi/mechglue/gss_release_name.c b/src/lib/gssapi/mechglue/g_rel_name.c similarity index 89% rename from src/lib/gssapi/mechglue/gss_release_name.c rename to src/lib/gssapi/mechglue/g_rel_name.c index 87b7d3126..9e288112a 100644 --- a/src/lib/gssapi/mechglue/gss_release_name.c +++ b/src/lib/gssapi/mechglue/g_rel_name.c @@ -6,7 +6,7 @@ * All rights reserved. */ -#include "mechglueP.h" +#include "mglueP.h" OM_uint32 gss_release_name (minor_status, @@ -20,7 +20,7 @@ gss_name_t * input_name; /* if input_name is NULL, return error */ - if(input_name == GSS_C_NO_NAME) + if (input_name == 0) return(GSS_S_BAD_NAME); /* @@ -29,7 +29,7 @@ gss_name_t * input_name; */ union_name = (gss_union_name_t) *input_name; - *input_name = GSS_C_NO_NAME; + *input_name = 0; *minor_status = 0; if (union_name == NULL) diff --git a/src/lib/gssapi/mechglue/gss_release_oid_set.c b/src/lib/gssapi/mechglue/g_rel_oid_set.c similarity index 96% rename from src/lib/gssapi/mechglue/gss_release_oid_set.c rename to src/lib/gssapi/mechglue/g_rel_oid_set.c index 3a98df27d..da1d0ed6d 100644 --- a/src/lib/gssapi/mechglue/gss_release_oid_set.c +++ b/src/lib/gssapi/mechglue/g_rel_oid_set.c @@ -6,7 +6,7 @@ * All rights reserved. */ -#include "mechglueP.h" +#include "mglueP.h" OM_uint32 gss_release_oid_set (minor_status, diff --git a/src/lib/gssapi/mechglue/gss_seal.c b/src/lib/gssapi/mechglue/g_seal.c similarity index 69% rename from src/lib/gssapi/mechglue/gss_seal.c rename to src/lib/gssapi/mechglue/g_seal.c index 47cb5c5c5..0981b73ed 100644 --- a/src/lib/gssapi/mechglue/gss_seal.c +++ b/src/lib/gssapi/mechglue/g_seal.c @@ -6,7 +6,7 @@ * All rights reserved. */ -#include "mechglueP.h" +#include "mglueP.h" OM_uint32 gss_seal (minor_status, @@ -62,3 +62,26 @@ gss_buffer_t output_message_buffer; return(GSS_S_NO_CONTEXT); } + +OM_uint32 +gss_wrap (minor_status, + context_handle, + conf_req_flag, + qop_req, + input_message_buffer, + conf_state, + output_message_buffer) + +OM_uint32 * minor_status; +gss_ctx_id_t context_handle; +int conf_req_flag; +gss_qop_t qop_req; +gss_buffer_t input_message_buffer; +int * conf_state; +gss_buffer_t output_message_buffer; + +{ + return gss_seal(minor_status, context_handle, conf_req_flag, + (int) qop_req, input_message_buffer, conf_state, + output_message_buffer); +} diff --git a/src/lib/gssapi/mechglue/gss_sign.c b/src/lib/gssapi/mechglue/g_sign.c similarity index 73% rename from src/lib/gssapi/mechglue/gss_sign.c rename to src/lib/gssapi/mechglue/g_sign.c index ba00f28a7..98092337d 100644 --- a/src/lib/gssapi/mechglue/gss_sign.c +++ b/src/lib/gssapi/mechglue/g_sign.c @@ -6,7 +6,7 @@ * All rights reserved. */ -#include "mechglueP.h" +#include "mglueP.h" OM_uint32 gss_sign (minor_status, @@ -56,3 +56,22 @@ gss_buffer_t msg_token; return(GSS_S_NO_CONTEXT); } + +OM_uint32 +gss_get_mic (minor_status, + context_handle, + qop_req, + message_buffer, + msg_token) + +OM_uint32 * minor_status; +gss_ctx_id_t context_handle; +gss_qop_t qop_req; +gss_buffer_t message_buffer; +gss_buffer_t msg_token; + +{ + return (gss_sign(minor_status, context_handle, (int) qop_req, + message_buffer, msg_token)); +} + diff --git a/src/lib/gssapi/mechglue/gss_unseal.c b/src/lib/gssapi/mechglue/g_unseal.c similarity index 69% rename from src/lib/gssapi/mechglue/gss_unseal.c rename to src/lib/gssapi/mechglue/g_unseal.c index 97d19a59e..0a1bd846b 100644 --- a/src/lib/gssapi/mechglue/gss_unseal.c +++ b/src/lib/gssapi/mechglue/g_unseal.c @@ -6,7 +6,7 @@ * All rights reserved. */ -#include "mechglueP.h" +#include "mglueP.h" OM_uint32 gss_unseal (minor_status, @@ -59,3 +59,25 @@ int * qop_state; return(GSS_S_NO_CONTEXT); } + +OM_uint32 +gss_unwrap (minor_status, + context_handle, + input_message_buffer, + output_message_buffer, + conf_state, + qop_state) + +OM_uint32 * minor_status; +gss_ctx_id_t context_handle; +gss_buffer_t input_message_buffer; +gss_buffer_t output_message_buffer; +int * conf_state; +gss_qop_t * qop_state; + +{ + return (gss_unseal(minor_status, context_handle, + input_message_buffer, + output_message_buffer, + conf_state, (int *) qop_state)); +} diff --git a/src/lib/gssapi/mechglue/gss_verify.c b/src/lib/gssapi/mechglue/g_verify.c similarity index 72% rename from src/lib/gssapi/mechglue/gss_verify.c rename to src/lib/gssapi/mechglue/g_verify.c index 50784930b..1a5c149a7 100644 --- a/src/lib/gssapi/mechglue/gss_verify.c +++ b/src/lib/gssapi/mechglue/g_verify.c @@ -6,7 +6,7 @@ * All rights reserved. */ -#include "mechglueP.h" +#include "mglueP.h" OM_uint32 gss_verify (minor_status, @@ -56,3 +56,21 @@ int * qop_state; return(GSS_S_NO_CONTEXT); } + +OM_uint32 +gss_verify_misc (minor_status, + context_handle, + message_buffer, + token_buffer, + qop_state) + +OM_uint32 * minor_status; +gss_ctx_id_t context_handle; +gss_buffer_t message_buffer; +gss_buffer_t token_buffer; +gss_qop_t * qop_state; + +{ + return (gss_verify(minor_status, context_handle, + message_buffer, token_buffer, (int *) qop_state)); +} diff --git a/src/lib/gssapi/mechglue/get_mechanism.c b/src/lib/gssapi/mechglue/get_mechanism.c index b3f7b6900..b72020da2 100644 --- a/src/lib/gssapi/mechglue/get_mechanism.c +++ b/src/lib/gssapi/mechglue/get_mechanism.c @@ -9,11 +9,11 @@ * All rights reserved. */ -#include "mechglueP.h" +#include "mglueP.h" extern gss_mechanism *mechs_array; -gss_mechanism get_mechanism (const_gss_OID type) +gss_mechanism get_mechanism (gss_OID type) { int i; diff --git a/src/lib/gssapi/mechglue/get_mech_type.c b/src/lib/gssapi/mechglue/get_mtype.c similarity index 98% rename from src/lib/gssapi/mechglue/get_mech_type.c rename to src/lib/gssapi/mechglue/get_mtype.c index 0dc087512..6ac9b5db8 100644 --- a/src/lib/gssapi/mechglue/get_mech_type.c +++ b/src/lib/gssapi/mechglue/get_mtype.c @@ -6,7 +6,7 @@ * All rights reserved. */ -#include "mechglueP.h" +#include "mglueP.h" OM_uint32 get_mech_type(OID, token) diff --git a/src/lib/gssapi/mechglue/gssd_pname_to_uid.c b/src/lib/gssapi/mechglue/gssd_pname_to_uid.c index da0da92c7..e99e85f20 100644 --- a/src/lib/gssapi/mechglue/gssd_pname_to_uid.c +++ b/src/lib/gssapi/mechglue/gssd_pname_to_uid.c @@ -9,7 +9,7 @@ * All rights reserved. */ -#include "mechglueP.h" +#include "mglueP.h" int gssd_pname_to_uid(pname, name_type, mech_type, uid) diff --git a/src/lib/gssapi/mechglue/internal_name.c b/src/lib/gssapi/mechglue/internal_name.c index 0fba73fdb..7657a2b34 100644 --- a/src/lib/gssapi/mechglue/internal_name.c +++ b/src/lib/gssapi/mechglue/internal_name.c @@ -6,7 +6,7 @@ * All rights reserved. */ -#include "mechglueP.h" +#include "mglueP.h" OM_uint32 import_internal_name (minor_status, mech_type, union_name, internal_name) diff --git a/src/lib/gssapi/mechglue/mechglueP.h b/src/lib/gssapi/mechglue/mglueP.h similarity index 82% rename from src/lib/gssapi/mechglue/mechglueP.h rename to src/lib/gssapi/mechglue/mglueP.h index 34f007f28..a322f65c1 100644 --- a/src/lib/gssapi/mechglue/mechglueP.h +++ b/src/lib/gssapi/mechglue/mglueP.h @@ -90,7 +90,7 @@ typedef struct gss_config { gss_cred_id_t, /* claimant_cred_handle */ gss_ctx_id_t*, /* context_handle */ gss_name_t, /* target_name */ - const_gss_OID, /* mech_type */ + gss_OID, /* mech_type */ int, /* req_flags */ OM_uint32, /* time_req */ gss_channel_bindings_t, /* input_chan_bindings */ @@ -172,7 +172,7 @@ typedef struct gss_config { OM_uint32*, /* minor_status */ OM_uint32, /* status_value */ int, /* status_type */ - const_gss_OID, /* mech_type */ + gss_OID, /* mech_type */ int*, /* message_context */ gss_buffer_t /* status_string */ ); @@ -199,7 +199,7 @@ typedef struct gss_config { (void*, /* context */ OM_uint32*, /* minor_status */ gss_buffer_t, /* input_name_buffer */ - const_gss_OID, /* input_name_type */ + gss_OID, /* input_name_type */ gss_name_t* /* output_name */ ); OM_uint32 (*gss_release_name) @@ -216,6 +216,49 @@ typedef struct gss_config { int *, /* cred_usage */ gss_OID_set * /* mechanisms */ ); + OM_uint32 (*gss_add_cred) + (void*, /* context */ + OM_uint32 *, /* minor_status */ + gss_cred_id_t, /* input_cred_handle */ + gss_name_t, /* desired_name */ + gss_OID, /* desired_mech */ + gss_cred_usage_t, /* cred_usage */ + OM_uint32, /* initiator_time_req */ + OM_uint32, /* acceptor_time_req */ + gss_cred_id_t *, /* output_cred_handle */ + gss_OID_set *, /* actual_mechs */ + OM_uint32 *, /* initiator_time_rec */ + OM_uint32 * /* acceptor_time_rec */ + ); + OM_uint32 (*gss_export_sec_context) + (void*, /* context */ + OM_uint32 *, /* minor_status */ + gss_ctx_id_t *, /* context_handle */ + gss_buffer_t /* interprocess_token */ + ); + OM_uint32 (*gss_import_sec_context) + (void *, /* context */ + OM_uint32 *, /* minor_status */ + gss_buffer_t, /* interprocess_token */ + gss_ctx_id_t * /* context_handle */ + ); + OM_uint32 (*gss_inquire_cred_by_mech) + (void *, /* context */ + OM_uint32 *, /* minor_status */ + gss_cred_id_t, /* cred_handle */ + gss_OID, /* mech_type */ + gss_name_t *, /* name */ + OM_uint32 *, /* initiator_lifetime */ + OM_uint32 *, /* acceptor_lifetime */ + gss_cred_usage_t * /* cred_usage */ + ); + + OM_uint32 (*gss_inquire_names_for_mech) + (void *, /* context */ + OM_uint32 *, /* minor_status */ + gss_OID, /* mechanism */ + gss_OID_set * /* name_types */ + ); int (*pname_to_uid) (char *, /* pname */ gss_OID, /* name type */ @@ -227,7 +270,7 @@ typedef struct gss_config { /********************************************************/ /* Internal mechglue routines */ -gss_mechanism get_mechanism (const_gss_OID); +gss_mechanism get_mechanism (gss_OID); OM_uint32 add_mechanism (gss_mechanism, int); OM_uint32 get_mech_type(gss_OID *, gss_buffer_t); OM_uint32 import_internal_name (OM_uint32 *, gss_OID, gss_union_name_t,