use GSSAPI_CALLCONV for exported SPIs
authorLuke Howard <lukeh@padl.com>
Sat, 10 Sep 2011 17:45:48 +0000 (18:45 +0100)
committerLuke Howard <lukeh@padl.com>
Sat, 10 Sep 2011 17:45:48 +0000 (18:45 +0100)
55 files changed:
moonshot/mech_eap/accept_sec_context.c
moonshot/mech_eap/acquire_cred.c
moonshot/mech_eap/acquire_cred_with_password.c
moonshot/mech_eap/add_cred.c
moonshot/mech_eap/add_cred_with_password.c
moonshot/mech_eap/authorize_localname.c
moonshot/mech_eap/canonicalize_name.c
moonshot/mech_eap/compare_name.c
moonshot/mech_eap/context_time.c
moonshot/mech_eap/delete_name_attribute.c
moonshot/mech_eap/delete_sec_context.c
moonshot/mech_eap/display_name.c
moonshot/mech_eap/display_name_ext.c
moonshot/mech_eap/display_status.c
moonshot/mech_eap/duplicate_name.c
moonshot/mech_eap/export_name.c
moonshot/mech_eap/export_name_composite.c
moonshot/mech_eap/export_sec_context.c
moonshot/mech_eap/get_mic.c
moonshot/mech_eap/get_name_attribute.c
moonshot/mech_eap/import_name.c
moonshot/mech_eap/import_sec_context.c
moonshot/mech_eap/indicate_mechs.c
moonshot/mech_eap/init_sec_context.c
moonshot/mech_eap/inquire_attrs_for_mech.c
moonshot/mech_eap/inquire_context.c
moonshot/mech_eap/inquire_cred.c
moonshot/mech_eap/inquire_cred_by_mech.c
moonshot/mech_eap/inquire_cred_by_oid.c
moonshot/mech_eap/inquire_mech_for_saslname.c
moonshot/mech_eap/inquire_mechs_for_name.c
moonshot/mech_eap/inquire_name.c
moonshot/mech_eap/inquire_names_for_mech.c
moonshot/mech_eap/inquire_saslname_for_mech.c
moonshot/mech_eap/inquire_sec_context_by_oid.c
moonshot/mech_eap/map_name_to_any.c
moonshot/mech_eap/mech_invoke.c
moonshot/mech_eap/process_context_token.c
moonshot/mech_eap/pseudo_random.c
moonshot/mech_eap/release_any_name_mapping.c
moonshot/mech_eap/release_cred.c
moonshot/mech_eap/release_name.c
moonshot/mech_eap/release_oid.c
moonshot/mech_eap/set_cred_option.c
moonshot/mech_eap/set_name_attribute.c
moonshot/mech_eap/set_sec_context_option.c
moonshot/mech_eap/store_cred.c
moonshot/mech_eap/unwrap.c
moonshot/mech_eap/unwrap_iov.c
moonshot/mech_eap/util.h
moonshot/mech_eap/verify_mic.c
moonshot/mech_eap/wrap.c
moonshot/mech_eap/wrap_iov.c
moonshot/mech_eap/wrap_iov_length.c
moonshot/mech_eap/wrap_size_limit.c

index 21ce614..afcd4d3 100644 (file)
@@ -858,7 +858,7 @@ static struct gss_eap_sm eapGssAcceptorSm[] = {
     },
 };
 
-OM_uint32
+OM_uint32 GSSAPI_CALLCONV
 gss_accept_sec_context(OM_uint32 *minor,
                        gss_ctx_id_t *context_handle,
                        gss_cred_id_t cred,
index 9e3f027..ae2648e 100644 (file)
@@ -36,7 +36,7 @@
 
 #include "gssapiP_eap.h"
 
-OM_uint32
+OM_uint32 GSSAPI_CALLCONV
 gss_acquire_cred(OM_uint32 *minor,
                  gss_name_t desired_name,
                  OM_uint32 time_req,
index 466473b..8e08358 100644 (file)
@@ -36,7 +36,7 @@
 
 #include "gssapiP_eap.h"
 
-OM_uint32
+OM_uint32 GSSAPI_CALLCONV
 gssspi_acquire_cred_with_password(OM_uint32 *minor,
                                   const gss_name_t desired_name,
                                   const gss_buffer_t password,
index f1598ed..64d97c0 100644 (file)
@@ -41,7 +41,7 @@
  * apart from the mechanism glue layer. However, Heimdal does call into the
  * mechanism here.
  */
-OM_uint32
+OM_uint32 GSSAPI_CALLCONV
 gss_add_cred(OM_uint32 *minor,
              gss_cred_id_t input_cred_handle GSSEAP_UNUSED,
              gss_name_t desired_name,
index f634f96..b982f0d 100644 (file)
@@ -36,7 +36,7 @@
 
 #include "gssapiP_eap.h"
 
-OM_uint32
+OM_uint32 GSSAPI_CALLCONV
 gss_add_cred_with_password(OM_uint32 *minor,
                            const gss_cred_id_t input_cred_handle GSSEAP_UNUSED,
                            const gss_name_t desired_name,
index ef5788e..0037e2b 100644 (file)
@@ -36,7 +36,7 @@
 
 #include "gssapiP_eap.h"
 
-OM_uint32
+OM_uint32 GSSAPI_CALLCONV
 gssspi_authorize_localname(OM_uint32 *minor,
                            const gss_name_t name GSSEAP_UNUSED,
                            gss_const_buffer_t local_user GSSEAP_UNUSED,
index 82d96b6..5e66798 100644 (file)
@@ -36,7 +36,7 @@
 
 #include "gssapiP_eap.h"
 
-OM_uint32
+OM_uint32 GSSAPI_CALLCONV
 gss_canonicalize_name(OM_uint32 *minor,
                       const gss_name_t input_name,
                       const gss_OID mech_type,
index 1da4d98..edadf3e 100644 (file)
@@ -36,7 +36,7 @@
 
 #include "gssapiP_eap.h"
 
-OM_uint32
+OM_uint32 GSSAPI_CALLCONV
 gss_compare_name(OM_uint32 *minor,
                  gss_name_t name1,
                  gss_name_t name2,
index 1486065..ae47d6c 100644 (file)
@@ -36,7 +36,7 @@
 
 #include "gssapiP_eap.h"
 
-OM_uint32
+OM_uint32 GSSAPI_CALLCONV
 gss_context_time(OM_uint32 *minor,
                  gss_ctx_id_t ctx,
                  OM_uint32 *time_rec)
index 88cade3..fe0ff8f 100644 (file)
@@ -36,7 +36,7 @@
 
 #include "gssapiP_eap.h"
 
-OM_uint32
+OM_uint32 GSSAPI_CALLCONV
 gss_delete_name_attribute(OM_uint32 *minor,
                           gss_name_t name,
                           gss_buffer_t attr)
index 7bd9cfb..ab3c54f 100644 (file)
@@ -36,7 +36,7 @@
 
 #include "gssapiP_eap.h"
 
-OM_uint32
+OM_uint32 GSSAPI_CALLCONV
 gss_delete_sec_context(OM_uint32 *minor,
                        gss_ctx_id_t *context_handle,
                        gss_buffer_t output_token)
index 427dcf2..2d87e66 100644 (file)
@@ -36,7 +36,7 @@
 
 #include "gssapiP_eap.h"
 
-OM_uint32
+OM_uint32 GSSAPI_CALLCONV
 gss_display_name(OM_uint32 *minor,
                  gss_name_t name,
                  gss_buffer_t output_name_buffer,
index dff525f..d6791d4 100644 (file)
@@ -36,7 +36,7 @@
 
 #include "gssapiP_eap.h"
 
-OM_uint32
+OM_uint32 GSSAPI_CALLCONV
 gss_display_name_ext(OM_uint32 *minor,
                      gss_name_t name GSSEAP_UNUSED,
                      gss_OID display_as_name_type GSSEAP_UNUSED,
index 584eac9..78738ff 100644 (file)
@@ -140,7 +140,7 @@ gssEapSaveStatusInfo(OM_uint32 minor, const char *format, ...)
     saveStatusInfoNoCopy(minor, s);
 }
 
-OM_uint32
+OM_uint32 GSSAPI_CALLCONV
 gss_display_status(OM_uint32 *minor,
                    OM_uint32 status_value,
                    int status_type,
index b618b3d..303619e 100644 (file)
@@ -36,7 +36,7 @@
 
 #include "gssapiP_eap.h"
 
-OM_uint32
+OM_uint32 GSSAPI_CALLCONV
 gss_duplicate_name(OM_uint32 *minor,
                    const gss_name_t input_name,
                    gss_name_t *dest_name)
index 7a37e30..d91033f 100644 (file)
@@ -36,7 +36,7 @@
 
 #include "gssapiP_eap.h"
 
-OM_uint32
+OM_uint32 GSSAPI_CALLCONV
 gss_export_name(OM_uint32 *minor,
                 const gss_name_t input_name,
                 gss_buffer_t exported_name)
index 7fb9840..b2a90ae 100644 (file)
@@ -36,7 +36,7 @@
 
 #include "gssapiP_eap.h"
 
-OM_uint32
+OM_uint32 GSSAPI_CALLCONV
 gss_export_name_composite(OM_uint32 *minor,
                           gss_name_t input_name,
                           gss_buffer_t exported_name)
index 43f3f28..8695bf6 100644 (file)
@@ -208,7 +208,7 @@ cleanup:
     return major;
 }
 
-OM_uint32
+OM_uint32 GSSAPI_CALLCONV
 gss_export_sec_context(OM_uint32 *minor,
                        gss_ctx_id_t *context_handle,
                        gss_buffer_t interprocess_token)
index c19e68f..7161e9c 100644 (file)
@@ -36,7 +36,7 @@
 
 #include "gssapiP_eap.h"
 
-OM_uint32
+OM_uint32 GSSAPI_CALLCONV
 gss_get_mic(OM_uint32 *minor,
             gss_ctx_id_t ctx,
             gss_qop_t qop_req,
index 8273368..a885823 100644 (file)
@@ -36,7 +36,7 @@
  * Wrapper for retrieving a naming attribute.
  */
 
-OM_uint32
+OM_uint32 GSSAPI_CALLCONV
 gss_get_name_attribute(OM_uint32 *minor,
                        gss_name_t name,
                        gss_buffer_t attr,
index 87f0830..8049e01 100644 (file)
@@ -36,7 +36,7 @@
 
 #include "gssapiP_eap.h"
 
-OM_uint32
+OM_uint32 GSSAPI_CALLCONV
 gss_import_name(OM_uint32 *minor,
                 gss_buffer_t import_name_buffer,
                 gss_OID input_name_type,
index d571bca..9d6ae3d 100644 (file)
@@ -325,7 +325,7 @@ gssEapImportContext(OM_uint32 *minor,
     return major;
 }
 
-OM_uint32
+OM_uint32 GSSAPI_CALLCONV
 gss_import_sec_context(OM_uint32 *minor,
                        gss_buffer_t interprocess_token,
                        gss_ctx_id_t *context_handle)
index ff88b4d..d4d275e 100644 (file)
@@ -36,7 +36,7 @@
 
 #include "gssapiP_eap.h"
 
-OM_uint32
+OM_uint32 GSSAPI_CALLCONV
 gss_indicate_mechs(OM_uint32 *minor,
                    gss_OID_set *mech_set)
 {
index 061bd38..23795fc 100644 (file)
@@ -943,7 +943,7 @@ static struct gss_eap_sm eapGssInitiatorSm[] = {
     }
 };
 
-OM_uint32
+OM_uint32 GSSAPI_CALLCONV
 gss_init_sec_context(OM_uint32 *minor,
                      gss_cred_id_t cred,
                      gss_ctx_id_t *context_handle,
index b85953b..a359f68 100644 (file)
@@ -45,7 +45,7 @@
 #define MA_SUPPORTED(ma)    MA_ADD((ma), mech_attrs)
 #define MA_KNOWN(ma)        MA_ADD((ma), known_mech_attrs)
 
-OM_uint32
+OM_uint32 GSSAPI_CALLCONV
 gss_inquire_attrs_for_mech(OM_uint32 *minor,
                            gss_const_OID mech_oid,
                            gss_OID_set *mech_attrs,
index 0e7b586..d37818d 100644 (file)
@@ -36,7 +36,7 @@
 
 #include "gssapiP_eap.h"
 
-OM_uint32
+OM_uint32 GSSAPI_CALLCONV
 gss_inquire_context(OM_uint32 *minor,
                     gss_ctx_id_t ctx,
                     gss_name_t *src_name,
index 6c0114b..227ab16 100644 (file)
@@ -36,7 +36,7 @@
 
 #include "gssapiP_eap.h"
 
-OM_uint32
+OM_uint32 GSSAPI_CALLCONV
 gss_inquire_cred(OM_uint32 *minor,
                  gss_cred_id_t cred,
                  gss_name_t *name,
index 24da201..191902d 100644 (file)
@@ -36,7 +36,7 @@
 
 #include "gssapiP_eap.h"
 
-OM_uint32
+OM_uint32 GSSAPI_CALLCONV
 gss_inquire_cred_by_mech(OM_uint32 *minor,
                          gss_cred_id_t cred,
                          gss_OID mech_type,
index b4a95f8..3898f8c 100644 (file)
@@ -43,7 +43,7 @@ static struct {
 } inquireCredOps[] = {
 };
 
-OM_uint32
+OM_uint32 GSSAPI_CALLCONV
 gss_inquire_cred_by_oid(OM_uint32 *minor,
                         const gss_cred_id_t cred_handle,
                         const gss_OID desired_object,
index c2f7914..bd518c0 100644 (file)
@@ -36,7 +36,7 @@
 
 #include "gssapiP_eap.h"
 
-OM_uint32
+OM_uint32 GSSAPI_CALLCONV
 gss_inquire_saslname_for_mech(OM_uint32 *minor,
                               const gss_OID mech,
                               gss_buffer_t sasl_mech_name,
index ca5d365..89c869c 100644 (file)
@@ -36,7 +36,7 @@
 
 #include "gssapiP_eap.h"
 
-OM_uint32
+OM_uint32 GSSAPI_CALLCONV
 gss_inquire_mechs_for_name(OM_uint32 *minor,
                            const gss_name_t input_name,
                            gss_OID_set *mech_types)
index 2a4e0e3..78b08a0 100644 (file)
 
 #include "gssapiP_eap.h"
 
-OM_uint32 gss_inquire_name(OM_uint32 *minor,
-                           gss_name_t name,
-                           int *name_is_MN,
-                           gss_OID *MN_mech,
-                           gss_buffer_set_t *attrs)
+OM_uint32 GSSAPI_CALLCONV
+gss_inquire_name(OM_uint32 *minor,
+                 gss_name_t name,
+                 int *name_is_MN,
+                 gss_OID *MN_mech,
+                 gss_buffer_set_t *attrs)
 {
     OM_uint32 major, tmpMinor;
 
index e01740a..0e60340 100644 (file)
@@ -36,7 +36,7 @@
 
 #include "gssapiP_eap.h"
 
-OM_uint32
+OM_uint32 GSSAPI_CALLCONV
 gss_inquire_names_for_mech(OM_uint32 *minor,
                            gss_OID mechanism,
                            gss_OID_set *ret_name_types)
index aec2a85..d6d7c14 100644 (file)
@@ -36,7 +36,7 @@
 
 #include "gssapiP_eap.h"
 
-OM_uint32
+OM_uint32 GSSAPI_CALLCONV
 gss_inquire_mech_for_saslname(OM_uint32 *minor,
                               const gss_buffer_t sasl_mech_name,
                               gss_OID *mech_type)
index a69b9e9..67b2ec8 100644 (file)
@@ -104,7 +104,7 @@ static struct {
     },
 };
 
-OM_uint32
+OM_uint32 GSSAPI_CALLCONV
 gss_inquire_sec_context_by_oid(OM_uint32 *minor,
                                const gss_ctx_id_t ctx,
                                const gss_OID desired_object,
index 6f952e3..2a8a96c 100644 (file)
@@ -32,7 +32,7 @@
 
 #include "gssapiP_eap.h"
 
-OM_uint32
+OM_uint32 GSSAPI_CALLCONV
 gss_map_name_to_any(OM_uint32 *minor,
                     gss_name_t name,
                     int authenticated,
index 2b7fb7e..bc9bba3 100644 (file)
@@ -32,7 +32,7 @@
 
 #include "gssapiP_eap.h"
 
-OM_uint32
+OM_uint32 GSSAPI_CALLCONV
 gssspi_mech_invoke(OM_uint32 *minor,
                    const gss_OID desired_mech,
                    const gss_OID desired_object,
index 5bad3c0..02a4b6d 100644 (file)
@@ -32,7 +32,7 @@
 
 #include "gssapiP_eap.h"
 
-OM_uint32
+OM_uint32 GSSAPI_CALLCONV
 gss_process_context_token(OM_uint32 *minor,
                           gss_ctx_id_t ctx,
                           gss_buffer_t token_buffer)
index 4bbf542..a90d972 100644 (file)
@@ -59,7 +59,7 @@
 
 #include "gssapiP_eap.h"
 
-OM_uint32
+OM_uint32 GSSAPI_CALLCONV
 gss_pseudo_random(OM_uint32 *minor,
                   gss_ctx_id_t ctx,
                   int prf_key,
index 54d3162..d68fb45 100644 (file)
@@ -32,7 +32,7 @@
 
 #include "gssapiP_eap.h"
 
-OM_uint32
+OM_uint32 GSSAPI_CALLCONV
 gss_release_any_name_mapping(OM_uint32 *minor,
                              gss_name_t name,
                              gss_buffer_t type_id,
index 57ba829..8bb7e54 100644 (file)
@@ -36,7 +36,7 @@
 
 #include "gssapiP_eap.h"
 
-OM_uint32
+OM_uint32 GSSAPI_CALLCONV
 gss_release_cred(OM_uint32 *minor,
                  gss_cred_id_t *cred_handle)
 {
index fb267a5..3d527ce 100644 (file)
@@ -36,7 +36,7 @@
 
 #include "gssapiP_eap.h"
 
-OM_uint32
+OM_uint32 GSSAPI_CALLCONV
 gss_release_name(OM_uint32 *minor,
                  gss_name_t *name)
 {
index 4e0d4f0..291da40 100644 (file)
@@ -36,7 +36,7 @@
 
 #include "gssapiP_eap.h"
 
-OM_uint32
+OM_uint32 GSSAPI_CALLCONV
 gss_internal_release_oid(OM_uint32 *minor,
                          gss_OID *oid)
 {
index dd87a1f..03c95fd 100644 (file)
@@ -138,7 +138,7 @@ gss_OID GSS_EAP_CRED_SET_RADIUS_CONFIG_FILE     = &setCredOps[0].oid;
 gss_OID GSS_EAP_CRED_SET_RADIUS_CONFIG_STANZA   = &setCredOps[1].oid;
 gss_OID GSS_EAP_CRED_SET_CRED_FLAG              = &setCredOps[2].oid;
 
-OM_uint32
+OM_uint32 GSSAPI_CALLCONV
 gssspi_set_cred_option(OM_uint32 *minor,
                        gss_cred_id_t *pCred,
                        const gss_OID desired_object,
index 6dd9434..2ccf5d7 100644 (file)
@@ -36,7 +36,7 @@
 
 #include "gssapiP_eap.h"
 
-OM_uint32
+OM_uint32 GSSAPI_CALLCONV
 gss_set_name_attribute(OM_uint32 *minor,
                        gss_name_t name,
                        int complete,
index 45ef266..118d2d2 100644 (file)
@@ -43,7 +43,7 @@ static struct {
 } setCtxOps[] = {
 };
 
-OM_uint32
+OM_uint32 GSSAPI_CALLCONV
 gss_set_sec_context_option(OM_uint32 *minor,
                            gss_ctx_id_t *pCtx,
                            const gss_OID desired_object,
index 2847f42..d17a3ac 100644 (file)
@@ -32,7 +32,7 @@
 
 #include "gssapiP_eap.h"
 
-OM_uint32
+OM_uint32 GSSAPI_CALLCONV
 gss_store_cred(OM_uint32 *minor,
                const gss_cred_id_t cred,
                gss_cred_usage_t input_usage,
index ae35bf9..a185035 100644 (file)
@@ -36,7 +36,7 @@
 
 #include "gssapiP_eap.h"
 
-OM_uint32
+OM_uint32 GSSAPI_CALLCONV
 gss_unwrap(OM_uint32 *minor,
            gss_ctx_id_t ctx,
            gss_buffer_t input_message_buffer,
index 2156e51..9e3ef19 100644 (file)
@@ -528,7 +528,7 @@ gssEapUnwrapOrVerifyMIC(OM_uint32 *minor,
     return major;
 }
 
-OM_uint32
+OM_uint32 GSSAPI_CALLCONV
 gss_unwrap_iov(OM_uint32 *minor,
                gss_ctx_id_t ctx,
                int *conf_state,
index 2242735..4c0756e 100644 (file)
@@ -744,6 +744,10 @@ verifyTokenHeader(OM_uint32 *minor,
 #define GSSEAP_FREE                     free
 #define GSSEAP_REALLOC                  realloc
 
+#ifndef GSSAPI_CALLCONV
+#define GSSAPI_CALLCONV                 KRB5_CALLCONV
+#endif
+
 #define GSSEAP_NOT_IMPLEMENTED          do {            \
         assert(0 && "not implemented");                 \
         *minor = ENOSYS;                                \
index 0a56949..d72c57e 100644 (file)
@@ -36,7 +36,7 @@
 
 #include "gssapiP_eap.h"
 
-OM_uint32
+OM_uint32 GSSAPI_CALLCONV
 gss_verify_mic(OM_uint32 *minor,
                gss_ctx_id_t ctx,
                gss_buffer_t message_buffer,
index a89bcb6..2e27fb3 100644 (file)
@@ -36,7 +36,7 @@
 
 #include "gssapiP_eap.h"
 
-OM_uint32
+OM_uint32 GSSAPI_CALLCONV
 gss_wrap(OM_uint32 *minor,
          gss_ctx_id_t ctx,
          int conf_req_flag,
index 31450fc..a40b980 100644 (file)
@@ -336,7 +336,7 @@ cleanup:
     return (code == 0) ? GSS_S_COMPLETE : GSS_S_FAILURE;
 }
 
-OM_uint32
+OM_uint32 GSSAPI_CALLCONV
 gss_wrap_iov(OM_uint32 *minor,
              gss_ctx_id_t ctx,
              int conf_req_flag,
index 229fec7..65bb6ec 100644 (file)
@@ -196,7 +196,7 @@ gssEapWrapIovLength(OM_uint32 *minor,
     return GSS_S_COMPLETE;
 }
 
-OM_uint32
+OM_uint32 GSSAPI_CALLCONV
 gss_wrap_iov_length(OM_uint32 *minor,
                     gss_ctx_id_t ctx,
                     int conf_req_flag,
index aadf1b4..d11fd63 100644 (file)
@@ -36,7 +36,7 @@
 
 #include "gssapiP_eap.h"
 
-OM_uint32
+OM_uint32 GSSAPI_CALLCONV
 gss_wrap_size_limit(OM_uint32 *minor,
                     gss_ctx_id_t ctx,
                     int conf_req_flag,