6722928: Support SSPI as a native GSS-API provider

Reviewed-by: erikj, nwilliams, valeriep
This commit is contained in:
Weijun Wang 2019-06-13 10:06:07 +08:00
parent 118fd65d44
commit 475996adc2
8 changed files with 1702 additions and 111 deletions

View file

@ -1,5 +1,5 @@
# #
# Copyright (c) 2011, 2018, Oracle and/or its affiliates. All rights reserved. # Copyright (c) 2011, 2019, Oracle and/or its affiliates. All rights reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
# #
# This code is free software; you can redistribute it and/or modify it # This code is free software; you can redistribute it and/or modify it
@ -57,6 +57,17 @@ ifneq ($(BUILD_CRYPTO), false)
)) ))
TARGETS += $(BUILD_LIBW2K_LSA_AUTH) TARGETS += $(BUILD_LIBW2K_LSA_AUTH)
$(eval $(call SetupJdkLibrary, BUILD_LIBSSPI_BRIDGE, \
NAME := sspi_bridge, \
OPTIMIZATION := LOW, \
CFLAGS := $(CFLAGS_JDKLIB) \
-I$(TOPDIR)/src/java.security.jgss/share/native/libj2gss, \
LDFLAGS := $(LDFLAGS_JDKLIB) \
$(call SET_SHARED_LIBRARY_ORIGIN) \
))
TARGETS += $(BUILD_LIBSSPI_BRIDGE)
endif endif
ifeq ($(call isTargetOs, macosx), true) ifeq ($(call isTargetOs, macosx), true)

View file

@ -1,5 +1,5 @@
/* /*
* Copyright (c) 2005, 2011, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2005, 2019, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
@ -26,7 +26,6 @@
package sun.security.jgss.spnego; package sun.security.jgss.spnego;
import java.io.*; import java.io.*;
import java.util.*;
import org.ietf.jgss.*; import org.ietf.jgss.*;
import sun.security.jgss.*; import sun.security.jgss.*;
import sun.security.util.*; import sun.security.util.*;
@ -113,18 +112,6 @@ public class NegTokenTarg extends SpNegoToken {
mic.putOctetString(mechListMIC); mic.putOctetString(mechListMIC);
targToken.write(DerValue.createTag(DerValue.TAG_CONTEXT, targToken.write(DerValue.createTag(DerValue.TAG_CONTEXT,
true, (byte) 0x03), mic); true, (byte) 0x03), mic);
} else if (GSSUtil.useMSInterop()) {
// required for MS-interoperability
if (responseToken != null) {
if (DEBUG) {
System.out.println("SpNegoToken NegTokenTarg: " +
"sending additional token for MS Interop");
}
DerOutputStream rspToken = new DerOutputStream();
rspToken.putOctetString(responseToken);
targToken.write(DerValue.createTag(DerValue.TAG_CONTEXT,
true, (byte) 0x03), rspToken);
}
} }
// insert in a SEQUENCE // insert in a SEQUENCE

View file

@ -1,5 +1,5 @@
/* /*
* Copyright (c) 2005, 2018, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2005, 2019, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
@ -66,7 +66,7 @@ public final class SunNativeProvider extends Provider {
static { static {
MECH_MAP = MECH_MAP =
AccessController.doPrivileged( AccessController.doPrivileged(
new PrivilegedAction<HashMap<String, String>>() { new PrivilegedAction<>() {
public HashMap<String, String> run() { public HashMap<String, String> run() {
DEBUG = Boolean.parseBoolean( DEBUG = Boolean.parseBoolean(
System.getProperty("sun.security.nativegss.debug")); System.getProperty("sun.security.nativegss.debug"));
@ -77,7 +77,7 @@ public final class SunNativeProvider extends Provider {
if (DEBUG) err.printStackTrace(); if (DEBUG) err.printStackTrace();
return null; return null;
} }
String[] gssLibs = new String[0]; String[] gssLibs;
String defaultLib String defaultLib
= System.getProperty("sun.security.jgss.lib"); = System.getProperty("sun.security.jgss.lib");
if (defaultLib == null || defaultLib.trim().equals("")) { if (defaultLib == null || defaultLib.trim().equals("")) {
@ -95,6 +95,12 @@ public final class SunNativeProvider extends Provider {
"libgssapi_krb5.dylib", "libgssapi_krb5.dylib",
"/usr/lib/sasl2/libgssapiv2.2.so", "/usr/lib/sasl2/libgssapiv2.2.so",
}; };
} else if (osname.contains("Windows")) {
// Full path needed, DLL is in jre/bin
gssLibs = new String[]{ System.getProperty("java.home")
+ "\\bin\\sspi_bridge.dll" };
} else {
gssLibs = new String[0];
} }
} else { } else {
gssLibs = new String[]{ defaultLib }; gssLibs = new String[]{ defaultLib };
@ -103,8 +109,7 @@ public final class SunNativeProvider extends Provider {
if (GSSLibStub.init(libName, DEBUG)) { if (GSSLibStub.init(libName, DEBUG)) {
debug("Loaded GSS library: " + libName); debug("Loaded GSS library: " + libName);
Oid[] mechs = GSSLibStub.indicateMechs(); Oid[] mechs = GSSLibStub.indicateMechs();
HashMap<String, String> map = HashMap<String,String> map = new HashMap<>();
new HashMap<String, String>();
for (int i = 0; i < mechs.length; i++) { for (int i = 0; i < mechs.length; i++) {
debug("Native MF for " + mechs[i]); debug("Native MF for " + mechs[i]);
map.put("GssApiMechanism." + mechs[i], map.put("GssApiMechanism." + mechs[i],

View file

@ -1,5 +1,5 @@
/* /*
* Copyright (c) 2005, 2018, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2005, 2019, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
@ -982,7 +982,7 @@ Java_sun_security_jgss_wrapper_GSSLibStub_acceptContext(JNIEnv *env,
OM_uint32 aFlags; OM_uint32 aFlags;
OM_uint32 aTime; OM_uint32 aTime;
gss_cred_id_t delCred; gss_cred_id_t delCred;
jobject jsrcName=GSS_C_NO_NAME; jobject jsrcName = NULL;
jobject jdelCred; jobject jdelCred;
jobject jMech; jobject jMech;
jboolean setTarget; jboolean setTarget;

View file

@ -1,5 +1,5 @@
/* /*
* Copyright (c) 2005, 2018, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2005, 2019, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
@ -57,38 +57,38 @@ typedef OM_uint32 (*RELEASE_NAME_FN_PTR)
typedef OM_uint32 (*IMPORT_NAME_FN_PTR) typedef OM_uint32 (*IMPORT_NAME_FN_PTR)
(OM_uint32 *minor_status, (OM_uint32 *minor_status,
gss_buffer_t input_name_buffer, const gss_buffer_t input_name_buffer,
gss_OID input_name_type, const gss_OID input_name_type,
gss_name_t *output_name); gss_name_t *output_name);
typedef OM_uint32 (*COMPARE_NAME_FN_PTR) typedef OM_uint32 (*COMPARE_NAME_FN_PTR)
(OM_uint32 *minor_status, (OM_uint32 *minor_status,
gss_name_t name1, gss_const_name_t name1,
gss_name_t name2, gss_const_name_t name2,
int *name_equal); int *name_equal);
typedef OM_uint32 (*CANONICALIZE_NAME_FN_PTR) typedef OM_uint32 (*CANONICALIZE_NAME_FN_PTR)
(OM_uint32 *minor_status, (OM_uint32 *minor_status,
gss_name_t input_name, gss_const_name_t input_name,
gss_OID mech_type, const gss_OID mech_type,
gss_name_t *output_name); gss_name_t *output_name);
typedef OM_uint32 (*EXPORT_NAME_FN_PTR) typedef OM_uint32 (*EXPORT_NAME_FN_PTR)
(OM_uint32 *minor_status, (OM_uint32 *minor_status,
gss_name_t input_name, gss_const_name_t input_name,
gss_buffer_t exported_name); gss_buffer_t exported_name);
typedef OM_uint32 (*DISPLAY_NAME_FN_PTR) typedef OM_uint32 (*DISPLAY_NAME_FN_PTR)
(OM_uint32 *minor_status, (OM_uint32 *minor_status,
gss_name_t input_name, gss_const_name_t input_name,
gss_buffer_t output_name_buffer, gss_buffer_t output_name_buffer,
gss_OID *output_name_type); gss_OID *output_name_type);
typedef OM_uint32 (*ACQUIRE_CRED_FN_PTR) typedef OM_uint32 (*ACQUIRE_CRED_FN_PTR)
(OM_uint32 *minor_status, (OM_uint32 *minor_status,
gss_name_t desired_name, gss_const_name_t desired_name,
OM_uint32 time_req, OM_uint32 time_req,
gss_OID_set desired_mech, const gss_OID_set desired_mech,
gss_cred_usage_t cred_usage, gss_cred_usage_t cred_usage,
gss_cred_id_t *output_cred_handle, gss_cred_id_t *output_cred_handle,
gss_OID_set *actual_mechs, gss_OID_set *actual_mechs,
@ -100,7 +100,7 @@ typedef OM_uint32 (*RELEASE_CRED_FN_PTR)
typedef OM_uint32 (*INQUIRE_CRED_FN_PTR) typedef OM_uint32 (*INQUIRE_CRED_FN_PTR)
(OM_uint32 *minor_status, (OM_uint32 *minor_status,
gss_cred_id_t cred_handle, gss_const_cred_id_t cred_handle,
gss_name_t *name, gss_name_t *name,
OM_uint32 *lifetime, OM_uint32 *lifetime,
gss_cred_usage_t *cred_usage, gss_cred_usage_t *cred_usage,
@ -108,19 +108,19 @@ typedef OM_uint32 (*INQUIRE_CRED_FN_PTR)
typedef OM_uint32 (*IMPORT_SEC_CONTEXT_FN_PTR) typedef OM_uint32 (*IMPORT_SEC_CONTEXT_FN_PTR)
(OM_uint32 *minor_status, (OM_uint32 *minor_status,
gss_buffer_t interprocess_token, const gss_buffer_t interprocess_token,
gss_ctx_id_t *context_handle); gss_ctx_id_t *context_handle);
typedef OM_uint32 (*INIT_SEC_CONTEXT_FN_PTR) typedef OM_uint32 (*INIT_SEC_CONTEXT_FN_PTR)
(OM_uint32 *minor_status, (OM_uint32 *minor_status,
gss_cred_id_t initiator_cred_handle, gss_const_cred_id_t initiator_cred_handle,
gss_ctx_id_t *context_handle, gss_ctx_id_t *context_handle,
gss_name_t *target_name, gss_const_name_t target_name,
gss_OID mech_type, const gss_OID mech_type,
OM_uint32 req_flags, OM_uint32 req_flags,
OM_uint32 time_req, OM_uint32 time_req,
gss_channel_bindings_t input_chan_bindings, const gss_channel_bindings_t input_chan_bindings,
gss_buffer_t input_token, const gss_buffer_t input_token,
gss_OID *actual_mech_type, gss_OID *actual_mech_type,
gss_buffer_t output_token, gss_buffer_t output_token,
OM_uint32 *ret_flags, OM_uint32 *ret_flags,
@ -129,9 +129,9 @@ typedef OM_uint32 (*INIT_SEC_CONTEXT_FN_PTR)
typedef OM_uint32 (*ACCEPT_SEC_CONTEXT_FN_PTR) typedef OM_uint32 (*ACCEPT_SEC_CONTEXT_FN_PTR)
(OM_uint32 *minor_status, (OM_uint32 *minor_status,
gss_ctx_id_t *context_handle, gss_ctx_id_t *context_handle,
gss_cred_id_t acceptor_cred_handle, gss_const_cred_id_t acceptor_cred_handle,
gss_buffer_t input_token, const gss_buffer_t input_token,
gss_channel_bindings_t input_chan_bindings, const gss_channel_bindings_t input_chan_bindings,
gss_name_t *src_name, gss_name_t *src_name,
gss_OID *mech_type, gss_OID *mech_type,
gss_buffer_t output_token, gss_buffer_t output_token,
@ -141,7 +141,7 @@ typedef OM_uint32 (*ACCEPT_SEC_CONTEXT_FN_PTR)
typedef OM_uint32 (*INQUIRE_CONTEXT_FN_PTR) typedef OM_uint32 (*INQUIRE_CONTEXT_FN_PTR)
(OM_uint32 *minor_status, (OM_uint32 *minor_status,
gss_ctx_id_t context_handle, gss_const_ctx_id_t context_handle,
gss_name_t *src_name, gss_name_t *src_name,
gss_name_t *targ_name, gss_name_t *targ_name,
OM_uint32 *lifetime_rec, OM_uint32 *lifetime_rec,
@ -157,12 +157,12 @@ typedef OM_uint32 (*DELETE_SEC_CONTEXT_FN_PTR)
typedef OM_uint32 (*CONTEXT_TIME_FN_PTR) typedef OM_uint32 (*CONTEXT_TIME_FN_PTR)
(OM_uint32 *minor_status, (OM_uint32 *minor_status,
gss_ctx_id_t *context_handle, gss_const_ctx_id_t context_handle,
OM_uint32 *time_rec); OM_uint32 *time_rec);
typedef OM_uint32 (*WRAP_SIZE_LIMIT_FN_PTR) typedef OM_uint32 (*WRAP_SIZE_LIMIT_FN_PTR)
(OM_uint32 *minor_status, (OM_uint32 *minor_status,
gss_ctx_id_t context_handle, gss_const_ctx_id_t context_handle,
int conf_req_flag, int conf_req_flag,
gss_qop_t qop_req, gss_qop_t qop_req,
OM_uint32 req_output_size, OM_uint32 req_output_size,
@ -175,31 +175,31 @@ typedef OM_uint32 (*EXPORT_SEC_CONTEXT_FN_PTR)
typedef OM_uint32 (*GET_MIC_FN_PTR) typedef OM_uint32 (*GET_MIC_FN_PTR)
(OM_uint32 *minor_status, (OM_uint32 *minor_status,
gss_ctx_id_t context_handle, gss_const_ctx_id_t context_handle,
gss_qop_t qop_req, gss_qop_t qop_req,
gss_buffer_t message_buffer, const gss_buffer_t message_buffer,
gss_buffer_t msg_token); gss_buffer_t msg_token);
typedef OM_uint32 (*VERIFY_MIC_FN_PTR) typedef OM_uint32 (*VERIFY_MIC_FN_PTR)
(OM_uint32 *minor_status, (OM_uint32 *minor_status,
gss_ctx_id_t context_handle, gss_const_ctx_id_t context_handle,
gss_buffer_t message_buffer, const gss_buffer_t message_buffer,
gss_buffer_t token_buffer, const gss_buffer_t token_buffer,
gss_qop_t *qop_state); gss_qop_t *qop_state);
typedef OM_uint32 (*WRAP_FN_PTR) typedef OM_uint32 (*WRAP_FN_PTR)
(OM_uint32 *minor_status, (OM_uint32 *minor_status,
gss_ctx_id_t context_handle, gss_const_ctx_id_t context_handle,
int conf_req_flag, int conf_req_flag,
gss_qop_t qop_req, gss_qop_t qop_req,
gss_buffer_t input_message_buffer, const gss_buffer_t input_message_buffer,
int *conf_state, int *conf_state,
gss_buffer_t output_message_buffer); gss_buffer_t output_message_buffer);
typedef OM_uint32 (*UNWRAP_FN_PTR) typedef OM_uint32 (*UNWRAP_FN_PTR)
(OM_uint32 *minor_status, (OM_uint32 *minor_status,
gss_ctx_id_t context_handle, gss_const_ctx_id_t context_handle,
gss_buffer_t input_message_buffer, const gss_buffer_t input_message_buffer,
gss_buffer_t output_message_buffer, gss_buffer_t output_message_buffer,
int *conf_state, int *conf_state,
gss_qop_t *qop_state); gss_qop_t *qop_state);
@ -215,14 +215,14 @@ typedef OM_uint32 (*INQUIRE_NAMES_FOR_MECH_FN_PTR)
typedef OM_uint32 (*ADD_OID_SET_MEMBER_FN_PTR) typedef OM_uint32 (*ADD_OID_SET_MEMBER_FN_PTR)
(OM_uint32 *minor_status, (OM_uint32 *minor_status,
gss_OID member_oid, const gss_OID member_oid,
gss_OID_set *oid_set); gss_OID_set *oid_set);
typedef OM_uint32 (*DISPLAY_STATUS_FN_PTR) typedef OM_uint32 (*DISPLAY_STATUS_FN_PTR)
(OM_uint32 *minor_status, (OM_uint32 *minor_status,
OM_uint32 status_value, OM_uint32 status_value,
int status_type, int status_type,
gss_OID mech_type, const gss_OID mech_type,
OM_uint32 *message_context, OM_uint32 *message_context,
gss_buffer_t status_string); gss_buffer_t status_string);

View file

@ -1,5 +1,5 @@
/* /*
* Copyright (c) 2005, 2018, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2005, 2019, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
@ -83,10 +83,10 @@ extern "C" {
extern jfieldID FID_NativeGSSContext_flags; extern jfieldID FID_NativeGSSContext_flags;
extern jfieldID FID_NativeGSSContext_lifetime; extern jfieldID FID_NativeGSSContext_lifetime;
extern jfieldID FID_NativeGSSContext_actualMech; extern jfieldID FID_NativeGSSContext_actualMech;
#define TRACE0(s) { if (JGSS_DEBUG) { puts(s); fflush(stdout); }} #define TRACE0(s) { if (JGSS_DEBUG) { printf("[GSSLibStub:%d] %s\n", __LINE__, s); fflush(stdout); }}
#define TRACE1(s, p1) { if (JGSS_DEBUG) { printf(s"\n", p1); fflush(stdout); }} #define TRACE1(s, p1) { if (JGSS_DEBUG) { printf("[GSSLibStub:%d] "s"\n", __LINE__, p1); fflush(stdout); }}
#define TRACE2(s, p1, p2) { if (JGSS_DEBUG) { printf(s"\n", p1, p2); fflush(stdout); }} #define TRACE2(s, p1, p2) { if (JGSS_DEBUG) { printf("[GSSLibStub:%d] "s"\n", __LINE__, p1, p2); fflush(stdout); }}
#define TRACE3(s, p1, p2, p3) { if (JGSS_DEBUG) { printf(s"\n", p1, p2, p3); fflush(stdout); }} #define TRACE3(s, p1, p2, p3) { if (JGSS_DEBUG) { printf("[GSSLibStub:%d] "s"\n", __LINE__, p1, p2, p3); fflush(stdout); }}
#ifdef __cplusplus #ifdef __cplusplus

View file

@ -1,5 +1,5 @@
/* /*
* Copyright (c) 2005, 2013, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2005, 2019, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
@ -57,9 +57,17 @@ extern "C" {
*/ */
#include <sys/types.h> #include <sys/types.h>
typedef void * gss_name_t; struct gss_name_struct;
typedef void * gss_cred_id_t; typedef struct gss_name_struct * gss_name_t;
typedef void * gss_ctx_id_t; typedef const struct gss_name_struct *gss_const_name_t;
struct gss_cred_id_struct;
typedef struct gss_cred_id_struct * gss_cred_id_t;
typedef const struct gss_cred_id_struct *gss_const_cred_id_t;
struct gss_ctx_id_struct;
typedef struct gss_ctx_id_struct * gss_ctx_id_t;
typedef const struct gss_ctx_id_struct *gss_const_ctx_id_t;
/* /*
* The following type must be defined as the smallest natural unsigned integer * The following type must be defined as the smallest natural unsigned integer
@ -82,16 +90,19 @@ typedef struct gss_OID_desc_struct {
OM_uint32 length; OM_uint32 length;
void *elements; void *elements;
} gss_OID_desc, *gss_OID; } gss_OID_desc, *gss_OID;
typedef const gss_OID_desc * gss_const_OID;
typedef struct gss_OID_set_desc_struct { typedef struct gss_OID_set_desc_struct {
size_t count; size_t count;
gss_OID elements; gss_OID elements;
} gss_OID_set_desc, *gss_OID_set; } gss_OID_set_desc, *gss_OID_set;
typedef const gss_OID_set_desc * gss_const_OID_set;
typedef struct gss_buffer_desc_struct { typedef struct gss_buffer_desc_struct {
size_t length; size_t length;
void *value; void *value;
} gss_buffer_desc, *gss_buffer_t; } gss_buffer_desc, *gss_buffer_t;
typedef const gss_buffer_desc * gss_const_buffer_t;
typedef struct gss_channel_bindings_struct { typedef struct gss_channel_bindings_struct {
OM_uint32 initiator_addrtype; OM_uint32 initiator_addrtype;
@ -100,6 +111,7 @@ typedef struct gss_channel_bindings_struct {
gss_buffer_desc acceptor_address; gss_buffer_desc acceptor_address;
gss_buffer_desc application_data; gss_buffer_desc application_data;
} *gss_channel_bindings_t; } *gss_channel_bindings_t;
typedef const struct gss_channel_bindings_struct *gss_const_channel_bindings_t;
/* /*
* For now, define a QOP-type as an OM_uint32 * For now, define a QOP-type as an OM_uint32
@ -119,6 +131,7 @@ typedef int gss_cred_usage_t;
#define GSS_C_ANON_FLAG 64 #define GSS_C_ANON_FLAG 64
#define GSS_C_PROT_READY_FLAG 128 #define GSS_C_PROT_READY_FLAG 128
#define GSS_C_TRANS_FLAG 256 #define GSS_C_TRANS_FLAG 256
#define GSS_C_DELEG_POLICY_FLAG 32768
/* /*
* Credential usage options * Credential usage options
@ -389,9 +402,9 @@ GSS_DLLIMP extern gss_OID GSS_C_NT_EXPORT_NAME;
GSS_DLLIMP OM_uint32 gss_acquire_cred( GSS_DLLIMP OM_uint32 gss_acquire_cred(
OM_uint32 *, /* minor_status */ OM_uint32 *, /* minor_status */
gss_name_t, /* desired_name */ gss_const_name_t, /* desired_name */
OM_uint32, /* time_req */ OM_uint32, /* time_req */
gss_OID_set, /* desired_mechs */ const gss_OID_set, /* desired_mechs */
gss_cred_usage_t, /* cred_usage */ gss_cred_usage_t, /* cred_usage */
gss_cred_id_t *, /* output_cred_handle */ gss_cred_id_t *, /* output_cred_handle */
gss_OID_set *, /* actual_mechs */ gss_OID_set *, /* actual_mechs */
@ -405,14 +418,14 @@ GSS_DLLIMP OM_uint32 gss_release_cred(
GSS_DLLIMP OM_uint32 gss_init_sec_context( GSS_DLLIMP OM_uint32 gss_init_sec_context(
OM_uint32 *, /* minor_status */ OM_uint32 *, /* minor_status */
gss_cred_id_t, /* claimant_cred_handle */ gss_const_cred_id_t, /* claimant_cred_handle */
gss_ctx_id_t *, /* context_handle */ gss_ctx_id_t *, /* context_handle */
gss_name_t, /* target_name */ gss_const_name_t, /* target_name */
gss_OID, /* mech_type (used to be const) */ const gss_OID, /* mech_type */
OM_uint32, /* req_flags */ OM_uint32, /* req_flags */
OM_uint32, /* time_req */ OM_uint32, /* time_req */
gss_channel_bindings_t, /* input_chan_bindings */ const gss_channel_bindings_t, /* input_chan_bindings */
gss_buffer_t, /* input_token */ const gss_buffer_t, /* input_token */
gss_OID *, /* actual_mech_type */ gss_OID *, /* actual_mech_type */
gss_buffer_t, /* output_token */ gss_buffer_t, /* output_token */
OM_uint32 *, /* ret_flags */ OM_uint32 *, /* ret_flags */
@ -422,9 +435,9 @@ GSS_DLLIMP OM_uint32 gss_init_sec_context(
GSS_DLLIMP OM_uint32 gss_accept_sec_context( GSS_DLLIMP OM_uint32 gss_accept_sec_context(
OM_uint32 *, /* minor_status */ OM_uint32 *, /* minor_status */
gss_ctx_id_t *, /* context_handle */ gss_ctx_id_t *, /* context_handle */
gss_cred_id_t, /* acceptor_cred_handle */ gss_const_cred_id_t, /* acceptor_cred_handle */
gss_buffer_t, /* input_token_buffer */ const gss_buffer_t, /* input_token_buffer */
gss_channel_bindings_t, /* input_chan_bindings */ const gss_channel_bindings_t, /* input_chan_bindings */
gss_name_t *, /* src_name */ gss_name_t *, /* src_name */
gss_OID *, /* mech_type */ gss_OID *, /* mech_type */
gss_buffer_t, /* output_token */ gss_buffer_t, /* output_token */
@ -435,8 +448,8 @@ GSS_DLLIMP OM_uint32 gss_accept_sec_context(
GSS_DLLIMP OM_uint32 gss_process_context_token( GSS_DLLIMP OM_uint32 gss_process_context_token(
OM_uint32 *, /* minor_status */ OM_uint32 *, /* minor_status */
gss_ctx_id_t, /* context_handle */ gss_const_ctx_id_t, /* context_handle */
gss_buffer_t /* token_buffer */ const gss_buffer_t /* token_buffer */
); );
GSS_DLLIMP OM_uint32 gss_delete_sec_context( GSS_DLLIMP OM_uint32 gss_delete_sec_context(
@ -447,35 +460,35 @@ GSS_DLLIMP OM_uint32 gss_delete_sec_context(
GSS_DLLIMP OM_uint32 gss_context_time( GSS_DLLIMP OM_uint32 gss_context_time(
OM_uint32 *, /* minor_status */ OM_uint32 *, /* minor_status */
gss_ctx_id_t, /* context_handle */ gss_const_ctx_id_t, /* context_handle */
OM_uint32 * /* time_rec */ OM_uint32 * /* time_rec */
); );
/* New for V2 */ /* New for V2 */
GSS_DLLIMP OM_uint32 gss_get_mic( GSS_DLLIMP OM_uint32 gss_get_mic(
OM_uint32 *, /* minor_status */ OM_uint32 *, /* minor_status */
gss_ctx_id_t, /* context_handle */ gss_const_ctx_id_t, /* context_handle */
gss_qop_t, /* qop_req */ gss_qop_t, /* qop_req */
gss_buffer_t, /* message_buffer */ const gss_buffer_t, /* message_buffer */
gss_buffer_t /* message_token */ gss_buffer_t /* message_token */
); );
/* New for V2 */ /* New for V2 */
GSS_DLLIMP OM_uint32 gss_verify_mic( GSS_DLLIMP OM_uint32 gss_verify_mic(
OM_uint32 *, /* minor_status */ OM_uint32 *, /* minor_status */
gss_ctx_id_t, /* context_handle */ gss_const_ctx_id_t, /* context_handle */
gss_buffer_t, /* message_buffer */ const gss_buffer_t, /* message_buffer */
gss_buffer_t, /* message_token */ const gss_buffer_t, /* message_token */
gss_qop_t * /* qop_state */ gss_qop_t * /* qop_state */
); );
/* New for V2 */ /* New for V2 */
GSS_DLLIMP OM_uint32 gss_wrap( GSS_DLLIMP OM_uint32 gss_wrap(
OM_uint32 *, /* minor_status */ OM_uint32 *, /* minor_status */
gss_ctx_id_t, /* context_handle */ gss_const_ctx_id_t, /* context_handle */
int, /* conf_req_flag */ int, /* conf_req_flag */
gss_qop_t, /* qop_req */ gss_qop_t, /* qop_req */
gss_buffer_t, /* input_message_buffer */ const gss_buffer_t, /* input_message_buffer */
int *, /* conf_state */ int *, /* conf_state */
gss_buffer_t /* output_message_buffer */ gss_buffer_t /* output_message_buffer */
); );
@ -483,8 +496,8 @@ GSS_DLLIMP OM_uint32 gss_wrap(
/* New for V2 */ /* New for V2 */
GSS_DLLIMP OM_uint32 gss_unwrap( GSS_DLLIMP OM_uint32 gss_unwrap(
OM_uint32 *, /* minor_status */ OM_uint32 *, /* minor_status */
gss_ctx_id_t, /* context_handle */ gss_const_ctx_id_t, /* context_handle */
gss_buffer_t, /* input_message_buffer */ const gss_buffer_t, /* input_message_buffer */
gss_buffer_t, /* output_message_buffer */ gss_buffer_t, /* output_message_buffer */
int *, /* conf_state */ int *, /* conf_state */
gss_qop_t * /* qop_state */ gss_qop_t * /* qop_state */
@ -494,7 +507,7 @@ GSS_DLLIMP OM_uint32 gss_display_status(
OM_uint32 *, /* minor_status */ OM_uint32 *, /* minor_status */
OM_uint32, /* status_value */ OM_uint32, /* status_value */
int, /* status_type */ int, /* status_type */
gss_OID, /* mech_type (used to be const) */ const gss_OID, /* mech_type (used to be const) */
OM_uint32 *, /* message_context */ OM_uint32 *, /* message_context */
gss_buffer_t /* status_string */ gss_buffer_t /* status_string */
); );
@ -506,22 +519,22 @@ GSS_DLLIMP OM_uint32 gss_indicate_mechs(
GSS_DLLIMP OM_uint32 gss_compare_name( GSS_DLLIMP OM_uint32 gss_compare_name(
OM_uint32 *, /* minor_status */ OM_uint32 *, /* minor_status */
gss_name_t, /* name1 */ gss_const_name_t, /* name1 */
gss_name_t, /* name2 */ gss_const_name_t, /* name2 */
int * /* name_equal */ int * /* name_equal */
); );
GSS_DLLIMP OM_uint32 gss_display_name( GSS_DLLIMP OM_uint32 gss_display_name(
OM_uint32 *, /* minor_status */ OM_uint32 *, /* minor_status */
gss_name_t, /* input_name */ gss_const_name_t, /* input_name */
gss_buffer_t, /* output_name_buffer */ gss_buffer_t, /* output_name_buffer */
gss_OID * /* output_name_type */ gss_OID * /* output_name_type */
); );
GSS_DLLIMP OM_uint32 gss_import_name( GSS_DLLIMP OM_uint32 gss_import_name(
OM_uint32 *, /* minor_status */ OM_uint32 *, /* minor_status */
gss_buffer_t, /* input_name_buffer */ const gss_buffer_t, /* input_name_buffer */
gss_OID, /* input_name_type(used to be const) */ const gss_OID, /* input_name_type(used to be const) */
gss_name_t * /* output_name */ gss_name_t * /* output_name */
); );
@ -542,7 +555,7 @@ GSS_DLLIMP OM_uint32 gss_release_oid_set(
GSS_DLLIMP OM_uint32 gss_inquire_cred( GSS_DLLIMP OM_uint32 gss_inquire_cred(
OM_uint32 *, /* minor_status */ OM_uint32 *, /* minor_status */
gss_cred_id_t, /* cred_handle */ gss_const_cred_id_t, /* cred_handle */
gss_name_t *, /* name */ gss_name_t *, /* name */
OM_uint32 *, /* lifetime */ OM_uint32 *, /* lifetime */
gss_cred_usage_t *, /* cred_usage */ gss_cred_usage_t *, /* cred_usage */
@ -552,7 +565,7 @@ GSS_DLLIMP OM_uint32 gss_inquire_cred(
/* Last argument new for V2 */ /* Last argument new for V2 */
GSS_DLLIMP OM_uint32 gss_inquire_context( GSS_DLLIMP OM_uint32 gss_inquire_context(
OM_uint32 *, /* minor_status */ OM_uint32 *, /* minor_status */
gss_ctx_id_t, /* context_handle */ gss_const_ctx_id_t, /* context_handle */
gss_name_t *, /* src_name */ gss_name_t *, /* src_name */
gss_name_t *, /* targ_name */ gss_name_t *, /* targ_name */
OM_uint32 *, /* lifetime_rec */ OM_uint32 *, /* lifetime_rec */
@ -565,7 +578,7 @@ GSS_DLLIMP OM_uint32 gss_inquire_context(
/* New for V2 */ /* New for V2 */
GSS_DLLIMP OM_uint32 gss_wrap_size_limit( GSS_DLLIMP OM_uint32 gss_wrap_size_limit(
OM_uint32 *, /* minor_status */ OM_uint32 *, /* minor_status */
gss_ctx_id_t, /* context_handle */ gss_const_ctx_id_t, /* context_handle */
int, /* conf_req_flag */ int, /* conf_req_flag */
gss_qop_t, /* qop_req */ gss_qop_t, /* qop_req */
OM_uint32, /* req_output_size */ OM_uint32, /* req_output_size */
@ -575,9 +588,9 @@ GSS_DLLIMP OM_uint32 gss_wrap_size_limit(
/* New for V2 */ /* New for V2 */
GSS_DLLIMP OM_uint32 gss_add_cred( GSS_DLLIMP OM_uint32 gss_add_cred(
OM_uint32 *, /* minor_status */ OM_uint32 *, /* minor_status */
gss_cred_id_t, /* input_cred_handle */ gss_const_cred_id_t, /* input_cred_handle */
gss_name_t, /* desired_name */ gss_const_name_t, /* desired_name */
gss_OID, /* desired_mech */ const gss_OID, /* desired_mech */
gss_cred_usage_t, /* cred_usage */ gss_cred_usage_t, /* cred_usage */
OM_uint32, /* initiator_time_req */ OM_uint32, /* initiator_time_req */
OM_uint32, /* acceptor_time_req */ OM_uint32, /* acceptor_time_req */
@ -590,8 +603,8 @@ GSS_DLLIMP OM_uint32 gss_add_cred(
/* New for V2 */ /* New for V2 */
GSS_DLLIMP OM_uint32 gss_inquire_cred_by_mech( GSS_DLLIMP OM_uint32 gss_inquire_cred_by_mech(
OM_uint32 *, /* minor_status */ OM_uint32 *, /* minor_status */
gss_cred_id_t, /* cred_handle */ gss_const_cred_id_t, /* cred_handle */
gss_OID, /* mech_type */ const gss_OID, /* mech_type */
gss_name_t *, /* name */ gss_name_t *, /* name */
OM_uint32 *, /* initiator_lifetime */ OM_uint32 *, /* initiator_lifetime */
OM_uint32 *, /* acceptor_lifetime */ OM_uint32 *, /* acceptor_lifetime */
@ -608,7 +621,7 @@ GSS_DLLIMP OM_uint32 gss_export_sec_context(
/* New for V2 */ /* New for V2 */
GSS_DLLIMP OM_uint32 gss_import_sec_context( GSS_DLLIMP OM_uint32 gss_import_sec_context(
OM_uint32 *, /* minor_status */ OM_uint32 *, /* minor_status */
gss_buffer_t, /* interprocess_token */ const gss_buffer_t, /* interprocess_token */
gss_ctx_id_t * /* context_handle */ gss_ctx_id_t * /* context_handle */
); );
@ -627,22 +640,22 @@ GSS_DLLIMP OM_uint32 gss_create_empty_oid_set(
/* New for V2 */ /* New for V2 */
GSS_DLLIMP OM_uint32 gss_add_oid_set_member( GSS_DLLIMP OM_uint32 gss_add_oid_set_member(
OM_uint32 *, /* minor_status */ OM_uint32 *, /* minor_status */
gss_OID, /* member_oid */ const gss_OID, /* member_oid */
gss_OID_set * /* oid_set */ gss_OID_set * /* oid_set */
); );
/* New for V2 */ /* New for V2 */
GSS_DLLIMP OM_uint32 gss_test_oid_set_member( GSS_DLLIMP OM_uint32 gss_test_oid_set_member(
OM_uint32 *, /* minor_status */ OM_uint32 *, /* minor_status */
gss_OID, /* member */ const gss_OID, /* member */
gss_OID_set, /* set */ const gss_OID_set, /* set */
int * /* present */ int * /* present */
); );
/* New for V2 */ /* New for V2 */
GSS_DLLIMP OM_uint32 gss_str_to_oid( GSS_DLLIMP OM_uint32 gss_str_to_oid(
OM_uint32 *, /* minor_status */ OM_uint32 *, /* minor_status */
gss_buffer_t, /* oid_str */ const gss_buffer_t, /* oid_str */
gss_OID * /* oid */ gss_OID * /* oid */
); );
@ -656,28 +669,28 @@ GSS_DLLIMP OM_uint32 gss_oid_to_str(
/* New for V2 */ /* New for V2 */
GSS_DLLIMP OM_uint32 gss_inquire_names_for_mech( GSS_DLLIMP OM_uint32 gss_inquire_names_for_mech(
OM_uint32 *, /* minor_status */ OM_uint32 *, /* minor_status */
gss_OID, /* mechanism */ const gss_OID, /* mechanism */
gss_OID_set * /* name_types */ gss_OID_set * /* name_types */
); );
/* New for V2 */ /* New for V2 */
GSS_DLLIMP OM_uint32 gss_export_name( GSS_DLLIMP OM_uint32 gss_export_name(
OM_uint32 *, /* minor_status */ OM_uint32 *, /* minor_status */
const gss_name_t, /* input_name */ gss_const_name_t, /* input_name */
gss_buffer_t /* exported_name */ gss_buffer_t /* exported_name */
); );
/* New for V2 */ /* New for V2 */
GSS_DLLIMP OM_uint32 gss_duplicate_name( GSS_DLLIMP OM_uint32 gss_duplicate_name(
OM_uint32 *, /* minor_status */ OM_uint32 *, /* minor_status */
const gss_name_t, /* input_name */ gss_const_name_t, /* input_name */
gss_name_t * /* dest_name */ gss_name_t * /* dest_name */
); );
/* New for V2 */ /* New for V2 */
GSS_DLLIMP OM_uint32 gss_canonicalize_name( GSS_DLLIMP OM_uint32 gss_canonicalize_name(
OM_uint32 *, /* minor_status */ OM_uint32 *, /* minor_status */
const gss_name_t, /* input_name */ gss_const_name_t, /* input_name */
const gss_OID, /* mech_type */ const gss_OID, /* mech_type */
gss_name_t * /* output_name */ gss_name_t * /* output_name */
); );

File diff suppressed because it is too large Load diff