Wed, 31 Dec 2014 06:09:35 +0100
Cloned upstream origin tor-browser at tor-browser-31.3.0esr-4.5-1-build1
revision ID fc1c9ff7c1b2defdbc039f12214767608f46423f for hacking purpose.
michael@0 | 1 | /* vim:set ts=4 sw=4 sts=4 et cindent: */ |
michael@0 | 2 | /* ***** BEGIN LICENSE BLOCK ***** |
michael@0 | 3 | * Copyright 1993 by OpenVision Technologies, Inc. |
michael@0 | 4 | * |
michael@0 | 5 | * Permission to use, copy, modify, distribute, and sell this software |
michael@0 | 6 | * and its documentation for any purpose is hereby granted without fee, |
michael@0 | 7 | * provided that the above copyright notice appears in all copies and |
michael@0 | 8 | * that both that copyright notice and this permission notice appear in |
michael@0 | 9 | * supporting documentation, and that the name of OpenVision not be used |
michael@0 | 10 | * in advertising or publicity pertaining to distribution of the software |
michael@0 | 11 | * without specific, written prior permission. OpenVision makes no |
michael@0 | 12 | * representations about the suitability of this software for any |
michael@0 | 13 | * purpose. It is provided "as is" without express or implied warranty. |
michael@0 | 14 | * |
michael@0 | 15 | * OPENVISION DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, |
michael@0 | 16 | * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO |
michael@0 | 17 | * EVENT SHALL OPENVISION BE LIABLE FOR ANY SPECIAL, INDIRECT OR |
michael@0 | 18 | * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF |
michael@0 | 19 | * USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR |
michael@0 | 20 | * OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR |
michael@0 | 21 | * PERFORMANCE OF THIS SOFTWARE. |
michael@0 | 22 | ****** END LICENSE BLOCK ***** */ |
michael@0 | 23 | |
michael@0 | 24 | #ifndef GSSAPI_H_ |
michael@0 | 25 | #define GSSAPI_H_ |
michael@0 | 26 | |
michael@0 | 27 | /* |
michael@0 | 28 | * Also define _GSSAPI_H_ as that is what the Kerberos 5 code defines and |
michael@0 | 29 | * what header files on some systems look for. |
michael@0 | 30 | */ |
michael@0 | 31 | #define _GSSAPI_H_ |
michael@0 | 32 | |
michael@0 | 33 | /* |
michael@0 | 34 | * On Mac OS X, Kerberos/Kerberos.h is used to gain access to certain |
michael@0 | 35 | * system-specific Kerberos functions, but on 10.4, that file also brings |
michael@0 | 36 | * in other headers that conflict with this one. |
michael@0 | 37 | */ |
michael@0 | 38 | #define _GSSAPI_GENERIC_H_ |
michael@0 | 39 | #define _GSSAPI_KRB5_H_ |
michael@0 | 40 | |
michael@0 | 41 | /* |
michael@0 | 42 | * Define windows specific needed parameters. |
michael@0 | 43 | */ |
michael@0 | 44 | |
michael@0 | 45 | #ifndef GSS_CALLCONV |
michael@0 | 46 | #if defined(_WIN32) |
michael@0 | 47 | #define GSS_CALLCONV __stdcall |
michael@0 | 48 | #define GSS_CALLCONV_C __cdecl |
michael@0 | 49 | #else |
michael@0 | 50 | #define GSS_CALLCONV |
michael@0 | 51 | #define GSS_CALLCONV_C |
michael@0 | 52 | #endif |
michael@0 | 53 | #endif /* GSS_CALLCONV */ |
michael@0 | 54 | |
michael@0 | 55 | #ifdef GSS_USE_FUNCTION_POINTERS |
michael@0 | 56 | #ifdef _WIN32 |
michael@0 | 57 | #undef GSS_CALLCONV |
michael@0 | 58 | #define GSS_CALLCONV |
michael@0 | 59 | #define GSS_FUNC(f) (__stdcall *f##_type) |
michael@0 | 60 | #else |
michael@0 | 61 | #define GSS_FUNC(f) (*f##_type) |
michael@0 | 62 | #endif |
michael@0 | 63 | #define GSS_MAKE_TYPEDEF typedef |
michael@0 | 64 | #else |
michael@0 | 65 | #define GSS_FUNC(f) f |
michael@0 | 66 | #define GSS_MAKE_TYPEDEF |
michael@0 | 67 | #endif |
michael@0 | 68 | |
michael@0 | 69 | /* |
michael@0 | 70 | * First, include stddef.h to get size_t defined. |
michael@0 | 71 | */ |
michael@0 | 72 | #include <stddef.h> |
michael@0 | 73 | |
michael@0 | 74 | /* |
michael@0 | 75 | * Configure set the following |
michael@0 | 76 | */ |
michael@0 | 77 | |
michael@0 | 78 | #ifndef SIZEOF_LONG |
michael@0 | 79 | #undef SIZEOF_LONG |
michael@0 | 80 | #endif |
michael@0 | 81 | #ifndef SIZEOF_SHORT |
michael@0 | 82 | #undef SIZEOF_SHORT |
michael@0 | 83 | #endif |
michael@0 | 84 | |
michael@0 | 85 | #ifndef EXTERN_C_BEGIN |
michael@0 | 86 | #ifdef __cplusplus |
michael@0 | 87 | #define EXTERN_C_BEGIN extern "C" { |
michael@0 | 88 | #define EXTERN_C_END } |
michael@0 | 89 | #else |
michael@0 | 90 | #define EXTERN_C_BEGIN |
michael@0 | 91 | #define EXTERN_C_END |
michael@0 | 92 | #endif |
michael@0 | 93 | #endif |
michael@0 | 94 | |
michael@0 | 95 | EXTERN_C_BEGIN |
michael@0 | 96 | |
michael@0 | 97 | #if defined(XP_MACOSX) |
michael@0 | 98 | # pragma pack(push,2) |
michael@0 | 99 | #endif |
michael@0 | 100 | |
michael@0 | 101 | /* |
michael@0 | 102 | * If the platform supports the xom.h header file, it should be |
michael@0 | 103 | * included here. |
michael@0 | 104 | */ |
michael@0 | 105 | /* #include <xom.h> */ |
michael@0 | 106 | |
michael@0 | 107 | |
michael@0 | 108 | /* |
michael@0 | 109 | * Now define the three implementation-dependent types. |
michael@0 | 110 | */ |
michael@0 | 111 | |
michael@0 | 112 | typedef void * gss_name_t ; |
michael@0 | 113 | typedef void * gss_ctx_id_t ; |
michael@0 | 114 | typedef void * gss_cred_id_t ; |
michael@0 | 115 | |
michael@0 | 116 | |
michael@0 | 117 | /* |
michael@0 | 118 | * The following type must be defined as the smallest natural |
michael@0 | 119 | * unsigned integer supported by the platform that has at least |
michael@0 | 120 | * 32 bits of precision. |
michael@0 | 121 | */ |
michael@0 | 122 | |
michael@0 | 123 | #if SIZEOF_LONG == 4 |
michael@0 | 124 | typedef unsigned long gss_uint32; |
michael@0 | 125 | #elif SIZEOF_SHORT == 4 |
michael@0 | 126 | typedef unsigned short gss_uint32; |
michael@0 | 127 | #else |
michael@0 | 128 | typedef unsigned int gss_uint32; |
michael@0 | 129 | #endif |
michael@0 | 130 | |
michael@0 | 131 | #ifdef OM_STRING |
michael@0 | 132 | |
michael@0 | 133 | /* |
michael@0 | 134 | * We have included the xom.h header file. Verify that OM_uint32 |
michael@0 | 135 | * is defined correctly. |
michael@0 | 136 | */ |
michael@0 | 137 | |
michael@0 | 138 | #if sizeof(gss_uint32) != sizeof(OM_uint32) |
michael@0 | 139 | #error Incompatible definition of OM_uint32 from xom.h |
michael@0 | 140 | #endif |
michael@0 | 141 | |
michael@0 | 142 | typedef OM_object_identifier gss_OID_desc, *gss_OID; |
michael@0 | 143 | |
michael@0 | 144 | #else /* !OM_STRING */ |
michael@0 | 145 | |
michael@0 | 146 | /* |
michael@0 | 147 | * We can't use X/Open definitions, so roll our own. |
michael@0 | 148 | */ |
michael@0 | 149 | typedef gss_uint32 OM_uint32; |
michael@0 | 150 | typedef struct gss_OID_desc_struct { |
michael@0 | 151 | OM_uint32 length; |
michael@0 | 152 | void *elements; |
michael@0 | 153 | } gss_OID_desc, *gss_OID; |
michael@0 | 154 | |
michael@0 | 155 | #endif /* !OM_STRING */ |
michael@0 | 156 | |
michael@0 | 157 | typedef struct gss_OID_set_desc_struct { |
michael@0 | 158 | size_t count; |
michael@0 | 159 | gss_OID elements; |
michael@0 | 160 | } gss_OID_set_desc, *gss_OID_set; |
michael@0 | 161 | |
michael@0 | 162 | |
michael@0 | 163 | /* |
michael@0 | 164 | * For now, define a QOP-type as an OM_uint32 |
michael@0 | 165 | */ |
michael@0 | 166 | typedef OM_uint32 gss_qop_t; |
michael@0 | 167 | |
michael@0 | 168 | typedef int gss_cred_usage_t; |
michael@0 | 169 | |
michael@0 | 170 | |
michael@0 | 171 | typedef struct gss_buffer_desc_struct { |
michael@0 | 172 | size_t length; |
michael@0 | 173 | void *value; |
michael@0 | 174 | } gss_buffer_desc, *gss_buffer_t; |
michael@0 | 175 | |
michael@0 | 176 | typedef struct gss_channel_bindings_struct { |
michael@0 | 177 | OM_uint32 initiator_addrtype; |
michael@0 | 178 | gss_buffer_desc initiator_address; |
michael@0 | 179 | OM_uint32 acceptor_addrtype; |
michael@0 | 180 | gss_buffer_desc acceptor_address; |
michael@0 | 181 | gss_buffer_desc application_data; |
michael@0 | 182 | } *gss_channel_bindings_t; |
michael@0 | 183 | |
michael@0 | 184 | |
michael@0 | 185 | /* |
michael@0 | 186 | * Flag bits for context-level services. |
michael@0 | 187 | */ |
michael@0 | 188 | #define GSS_C_DELEG_FLAG 1 |
michael@0 | 189 | #define GSS_C_MUTUAL_FLAG 2 |
michael@0 | 190 | #define GSS_C_REPLAY_FLAG 4 |
michael@0 | 191 | #define GSS_C_SEQUENCE_FLAG 8 |
michael@0 | 192 | #define GSS_C_CONF_FLAG 16 |
michael@0 | 193 | #define GSS_C_INTEG_FLAG 32 |
michael@0 | 194 | #define GSS_C_ANON_FLAG 64 |
michael@0 | 195 | #define GSS_C_PROT_READY_FLAG 128 |
michael@0 | 196 | #define GSS_C_TRANS_FLAG 256 |
michael@0 | 197 | |
michael@0 | 198 | /* |
michael@0 | 199 | * Credential usage options |
michael@0 | 200 | */ |
michael@0 | 201 | #define GSS_C_BOTH 0 |
michael@0 | 202 | #define GSS_C_INITIATE 1 |
michael@0 | 203 | #define GSS_C_ACCEPT 2 |
michael@0 | 204 | |
michael@0 | 205 | /* |
michael@0 | 206 | * Status code types for gss_display_status |
michael@0 | 207 | */ |
michael@0 | 208 | #define GSS_C_GSS_CODE 1 |
michael@0 | 209 | #define GSS_C_MECH_CODE 2 |
michael@0 | 210 | |
michael@0 | 211 | /* |
michael@0 | 212 | * The constant definitions for channel-bindings address families |
michael@0 | 213 | */ |
michael@0 | 214 | #define GSS_C_AF_UNSPEC 0 |
michael@0 | 215 | #define GSS_C_AF_LOCAL 1 |
michael@0 | 216 | #define GSS_C_AF_INET 2 |
michael@0 | 217 | #define GSS_C_AF_IMPLINK 3 |
michael@0 | 218 | #define GSS_C_AF_PUP 4 |
michael@0 | 219 | #define GSS_C_AF_CHAOS 5 |
michael@0 | 220 | #define GSS_C_AF_NS 6 |
michael@0 | 221 | #define GSS_C_AF_NBS 7 |
michael@0 | 222 | #define GSS_C_AF_ECMA 8 |
michael@0 | 223 | #define GSS_C_AF_DATAKIT 9 |
michael@0 | 224 | #define GSS_C_AF_CCITT 10 |
michael@0 | 225 | #define GSS_C_AF_SNA 11 |
michael@0 | 226 | #define GSS_C_AF_DECnet 12 |
michael@0 | 227 | #define GSS_C_AF_DLI 13 |
michael@0 | 228 | #define GSS_C_AF_LAT 14 |
michael@0 | 229 | #define GSS_C_AF_HYLINK 15 |
michael@0 | 230 | #define GSS_C_AF_APPLETALK 16 |
michael@0 | 231 | #define GSS_C_AF_BSC 17 |
michael@0 | 232 | #define GSS_C_AF_DSS 18 |
michael@0 | 233 | #define GSS_C_AF_OSI 19 |
michael@0 | 234 | #define GSS_C_AF_X25 21 |
michael@0 | 235 | |
michael@0 | 236 | #define GSS_C_AF_NULLADDR 255 |
michael@0 | 237 | |
michael@0 | 238 | /* |
michael@0 | 239 | * Various Null values |
michael@0 | 240 | */ |
michael@0 | 241 | #define GSS_C_NO_NAME ((gss_name_t) 0) |
michael@0 | 242 | #define GSS_C_NO_BUFFER ((gss_buffer_t) 0) |
michael@0 | 243 | #define GSS_C_NO_OID ((gss_OID) 0) |
michael@0 | 244 | #define GSS_C_NO_OID_SET ((gss_OID_set) 0) |
michael@0 | 245 | #define GSS_C_NO_CONTEXT ((gss_ctx_id_t) 0) |
michael@0 | 246 | #define GSS_C_NO_CREDENTIAL ((gss_cred_id_t) 0) |
michael@0 | 247 | #define GSS_C_NO_CHANNEL_BINDINGS ((gss_channel_bindings_t) 0) |
michael@0 | 248 | #define GSS_C_EMPTY_BUFFER {0, nullptr} |
michael@0 | 249 | |
michael@0 | 250 | /* |
michael@0 | 251 | * Some alternate names for a couple of the above |
michael@0 | 252 | * values. These are defined for V1 compatibility. |
michael@0 | 253 | */ |
michael@0 | 254 | #define GSS_C_NULL_OID GSS_C_NO_OID |
michael@0 | 255 | #define GSS_C_NULL_OID_SET GSS_C_NO_OID_SET |
michael@0 | 256 | |
michael@0 | 257 | /* |
michael@0 | 258 | * Define the default Quality of Protection for per-message |
michael@0 | 259 | * services. Note that an implementation that offers multiple |
michael@0 | 260 | * levels of QOP may define GSS_C_QOP_DEFAULT to be either zero |
michael@0 | 261 | * (as done here) to mean "default protection", or to a specific |
michael@0 | 262 | * explicit QOP value. However, a value of 0 should always be |
michael@0 | 263 | * interpreted by a GSSAPI implementation as a request for the |
michael@0 | 264 | * default protection level. |
michael@0 | 265 | */ |
michael@0 | 266 | #define GSS_C_QOP_DEFAULT 0 |
michael@0 | 267 | |
michael@0 | 268 | /* |
michael@0 | 269 | * Expiration time of 2^32-1 seconds means infinite lifetime for a |
michael@0 | 270 | * credential or security context |
michael@0 | 271 | */ |
michael@0 | 272 | #define GSS_C_INDEFINITE 0xfffffffful |
michael@0 | 273 | |
michael@0 | 274 | /* |
michael@0 | 275 | * The implementation must reserve static storage for a |
michael@0 | 276 | * gss_OID_desc object containing the value |
michael@0 | 277 | * {10, (void *)"\x2a\x86\x48\x86\xf7\x12" |
michael@0 | 278 | * "\x01\x02\x01\x01"}, |
michael@0 | 279 | * corresponding to an object-identifier value of |
michael@0 | 280 | * {iso(1) member-body(2) United States(840) mit(113554) |
michael@0 | 281 | * infosys(1) gssapi(2) generic(1) user_name(1)}. The constant |
michael@0 | 282 | * GSS_C_NT_USER_NAME should be initialized to point |
michael@0 | 283 | * to that gss_OID_desc. |
michael@0 | 284 | */ |
michael@0 | 285 | extern gss_OID GSS_C_NT_USER_NAME; |
michael@0 | 286 | |
michael@0 | 287 | /* |
michael@0 | 288 | * The implementation must reserve static storage for a |
michael@0 | 289 | * gss_OID_desc object containing the value |
michael@0 | 290 | * {10, (void *)"\x2a\x86\x48\x86\xf7\x12" |
michael@0 | 291 | * "\x01\x02\x01\x02"}, |
michael@0 | 292 | * corresponding to an object-identifier value of |
michael@0 | 293 | * {iso(1) member-body(2) United States(840) mit(113554) |
michael@0 | 294 | * infosys(1) gssapi(2) generic(1) machine_uid_name(2)}. |
michael@0 | 295 | * The constant GSS_C_NT_MACHINE_UID_NAME should be |
michael@0 | 296 | * initialized to point to that gss_OID_desc. |
michael@0 | 297 | */ |
michael@0 | 298 | extern gss_OID GSS_C_NT_MACHINE_UID_NAME; |
michael@0 | 299 | |
michael@0 | 300 | /* |
michael@0 | 301 | * The implementation must reserve static storage for a |
michael@0 | 302 | * gss_OID_desc object containing the value |
michael@0 | 303 | * {10, (void *)"\x2a\x86\x48\x86\xf7\x12" |
michael@0 | 304 | * "\x01\x02\x01\x03"}, |
michael@0 | 305 | * corresponding to an object-identifier value of |
michael@0 | 306 | * {iso(1) member-body(2) United States(840) mit(113554) |
michael@0 | 307 | * infosys(1) gssapi(2) generic(1) string_uid_name(3)}. |
michael@0 | 308 | * The constant GSS_C_NT_STRING_UID_NAME should be |
michael@0 | 309 | * initialized to point to that gss_OID_desc. |
michael@0 | 310 | */ |
michael@0 | 311 | extern gss_OID GSS_C_NT_STRING_UID_NAME; |
michael@0 | 312 | |
michael@0 | 313 | /* |
michael@0 | 314 | * The implementation must reserve static storage for a |
michael@0 | 315 | * gss_OID_desc object containing the value |
michael@0 | 316 | * {6, (void *)"\x2b\x06\x01\x05\x06\x02"}, |
michael@0 | 317 | * corresponding to an object-identifier value of |
michael@0 | 318 | * {iso(1) org(3) dod(6) internet(1) security(5) |
michael@0 | 319 | * nametypes(6) gss-host-based-services(2)). The constant |
michael@0 | 320 | * GSS_C_NT_HOSTBASED_SERVICE_X should be initialized to point |
michael@0 | 321 | * to that gss_OID_desc. This is a deprecated OID value, and |
michael@0 | 322 | * implementations wishing to support hostbased-service names |
michael@0 | 323 | * should instead use the GSS_C_NT_HOSTBASED_SERVICE OID, |
michael@0 | 324 | * defined below, to identify such names; |
michael@0 | 325 | * GSS_C_NT_HOSTBASED_SERVICE_X should be accepted a synonym |
michael@0 | 326 | * for GSS_C_NT_HOSTBASED_SERVICE when presented as an input |
michael@0 | 327 | * parameter, but should not be emitted by GSSAPI |
michael@0 | 328 | * implementations |
michael@0 | 329 | */ |
michael@0 | 330 | extern gss_OID GSS_C_NT_HOSTBASED_SERVICE_X; |
michael@0 | 331 | |
michael@0 | 332 | /* |
michael@0 | 333 | * The implementation must reserve static storage for a |
michael@0 | 334 | * gss_OID_desc object containing the value |
michael@0 | 335 | * {10, (void *)"\x2a\x86\x48\x86\xf7\x12" |
michael@0 | 336 | * "\x01\x02\x01\x04"}, corresponding to an |
michael@0 | 337 | * object-identifier value of {iso(1) member-body(2) |
michael@0 | 338 | * Unites States(840) mit(113554) infosys(1) gssapi(2) |
michael@0 | 339 | * generic(1) service_name(4)}. The constant |
michael@0 | 340 | * GSS_C_NT_HOSTBASED_SERVICE should be initialized |
michael@0 | 341 | * to point to that gss_OID_desc. |
michael@0 | 342 | */ |
michael@0 | 343 | extern gss_OID GSS_C_NT_HOSTBASED_SERVICE; |
michael@0 | 344 | |
michael@0 | 345 | |
michael@0 | 346 | /* |
michael@0 | 347 | * The implementation must reserve static storage for a |
michael@0 | 348 | * gss_OID_desc object containing the value |
michael@0 | 349 | * {6, (void *)"\x2b\x06\01\x05\x06\x03"}, |
michael@0 | 350 | * corresponding to an object identifier value of |
michael@0 | 351 | * {1(iso), 3(org), 6(dod), 1(internet), 5(security), |
michael@0 | 352 | * 6(nametypes), 3(gss-anonymous-name)}. The constant |
michael@0 | 353 | * and GSS_C_NT_ANONYMOUS should be initialized to point |
michael@0 | 354 | * to that gss_OID_desc. |
michael@0 | 355 | */ |
michael@0 | 356 | extern gss_OID GSS_C_NT_ANONYMOUS; |
michael@0 | 357 | |
michael@0 | 358 | /* |
michael@0 | 359 | * The implementation must reserve static storage for a |
michael@0 | 360 | * gss_OID_desc object containing the value |
michael@0 | 361 | * {6, (void *)"\x2b\x06\x01\x05\x06\x04"}, |
michael@0 | 362 | * corresponding to an object-identifier value of |
michael@0 | 363 | * {1(iso), 3(org), 6(dod), 1(internet), 5(security), |
michael@0 | 364 | * 6(nametypes), 4(gss-api-exported-name)}. The constant |
michael@0 | 365 | * GSS_C_NT_EXPORT_NAME should be initialized to point |
michael@0 | 366 | * to that gss_OID_desc. |
michael@0 | 367 | */ |
michael@0 | 368 | extern gss_OID GSS_C_NT_EXPORT_NAME; |
michael@0 | 369 | |
michael@0 | 370 | /* Major status codes */ |
michael@0 | 371 | |
michael@0 | 372 | #define GSS_S_COMPLETE 0 |
michael@0 | 373 | |
michael@0 | 374 | /* |
michael@0 | 375 | * Some "helper" definitions to make the status code macros obvious. |
michael@0 | 376 | */ |
michael@0 | 377 | #define GSS_C_CALLING_ERROR_OFFSET 24 |
michael@0 | 378 | #define GSS_C_ROUTINE_ERROR_OFFSET 16 |
michael@0 | 379 | #define GSS_C_SUPPLEMENTARY_OFFSET 0 |
michael@0 | 380 | #define GSS_C_CALLING_ERROR_MASK 0377ul |
michael@0 | 381 | #define GSS_C_ROUTINE_ERROR_MASK 0377ul |
michael@0 | 382 | #define GSS_C_SUPPLEMENTARY_MASK 0177777ul |
michael@0 | 383 | |
michael@0 | 384 | /* |
michael@0 | 385 | * The macros that test status codes for error conditions. |
michael@0 | 386 | * Note that the GSS_ERROR() macro has changed slightly from |
michael@0 | 387 | * the V1 GSSAPI so that it now evaluates its argument |
michael@0 | 388 | * only once. |
michael@0 | 389 | */ |
michael@0 | 390 | #define GSS_CALLING_ERROR(x) \ |
michael@0 | 391 | (x & (GSS_C_CALLING_ERROR_MASK << GSS_C_CALLING_ERROR_OFFSET)) |
michael@0 | 392 | #define GSS_ROUTINE_ERROR(x) \ |
michael@0 | 393 | (x & (GSS_C_ROUTINE_ERROR_MASK << GSS_C_ROUTINE_ERROR_OFFSET)) |
michael@0 | 394 | #define GSS_SUPPLEMENTARY_INFO(x) \ |
michael@0 | 395 | (x & (GSS_C_SUPPLEMENTARY_MASK << GSS_C_SUPPLEMENTARY_OFFSET)) |
michael@0 | 396 | #define GSS_ERROR(x) \ |
michael@0 | 397 | (x & ((GSS_C_CALLING_ERROR_MASK << GSS_C_CALLING_ERROR_OFFSET) | \ |
michael@0 | 398 | (GSS_C_ROUTINE_ERROR_MASK << GSS_C_ROUTINE_ERROR_OFFSET))) |
michael@0 | 399 | |
michael@0 | 400 | /* |
michael@0 | 401 | * Now the actual status code definitions |
michael@0 | 402 | */ |
michael@0 | 403 | |
michael@0 | 404 | /* |
michael@0 | 405 | * Calling errors: |
michael@0 | 406 | */ |
michael@0 | 407 | #define GSS_S_CALL_INACCESSIBLE_READ \ |
michael@0 | 408 | (1ul << GSS_C_CALLING_ERROR_OFFSET) |
michael@0 | 409 | #define GSS_S_CALL_INACCESSIBLE_WRITE \ |
michael@0 | 410 | (2ul << GSS_C_CALLING_ERROR_OFFSET) |
michael@0 | 411 | #define GSS_S_CALL_BAD_STRUCTURE \ |
michael@0 | 412 | (3ul << GSS_C_CALLING_ERROR_OFFSET) |
michael@0 | 413 | |
michael@0 | 414 | /* |
michael@0 | 415 | * Routine errors: |
michael@0 | 416 | */ |
michael@0 | 417 | #define GSS_S_BAD_MECH (1ul << GSS_C_ROUTINE_ERROR_OFFSET) |
michael@0 | 418 | #define GSS_S_BAD_NAME (2ul << GSS_C_ROUTINE_ERROR_OFFSET) |
michael@0 | 419 | #define GSS_S_BAD_NAMETYPE (3ul << GSS_C_ROUTINE_ERROR_OFFSET) |
michael@0 | 420 | #define GSS_S_BAD_BINDINGS (4ul << GSS_C_ROUTINE_ERROR_OFFSET) |
michael@0 | 421 | #define GSS_S_BAD_STATUS (5ul << GSS_C_ROUTINE_ERROR_OFFSET) |
michael@0 | 422 | #define GSS_S_BAD_SIG (6ul << GSS_C_ROUTINE_ERROR_OFFSET) |
michael@0 | 423 | #define GSS_S_BAD_MIC GSS_S_BAD_SIG |
michael@0 | 424 | #define GSS_S_NO_CRED (7ul << GSS_C_ROUTINE_ERROR_OFFSET) |
michael@0 | 425 | #define GSS_S_NO_CONTEXT (8ul << GSS_C_ROUTINE_ERROR_OFFSET) |
michael@0 | 426 | #define GSS_S_DEFECTIVE_TOKEN (9ul << GSS_C_ROUTINE_ERROR_OFFSET) |
michael@0 | 427 | #define GSS_S_DEFECTIVE_CREDENTIAL (10ul << GSS_C_ROUTINE_ERROR_OFFSET) |
michael@0 | 428 | #define GSS_S_CREDENTIALS_EXPIRED (11ul << GSS_C_ROUTINE_ERROR_OFFSET) |
michael@0 | 429 | #define GSS_S_CONTEXT_EXPIRED (12ul << GSS_C_ROUTINE_ERROR_OFFSET) |
michael@0 | 430 | #define GSS_S_FAILURE (13ul << GSS_C_ROUTINE_ERROR_OFFSET) |
michael@0 | 431 | #define GSS_S_BAD_QOP (14ul << GSS_C_ROUTINE_ERROR_OFFSET) |
michael@0 | 432 | #define GSS_S_UNAUTHORIZED (15ul << GSS_C_ROUTINE_ERROR_OFFSET) |
michael@0 | 433 | #define GSS_S_UNAVAILABLE (16ul << GSS_C_ROUTINE_ERROR_OFFSET) |
michael@0 | 434 | #define GSS_S_DUPLICATE_ELEMENT (17ul << GSS_C_ROUTINE_ERROR_OFFSET) |
michael@0 | 435 | #define GSS_S_NAME_NOT_MN (18ul << GSS_C_ROUTINE_ERROR_OFFSET) |
michael@0 | 436 | |
michael@0 | 437 | /* |
michael@0 | 438 | * Supplementary info bits: |
michael@0 | 439 | */ |
michael@0 | 440 | #define GSS_S_CONTINUE_NEEDED (1ul << (GSS_C_SUPPLEMENTARY_OFFSET + 0)) |
michael@0 | 441 | #define GSS_S_DUPLICATE_TOKEN (1ul << (GSS_C_SUPPLEMENTARY_OFFSET + 1)) |
michael@0 | 442 | #define GSS_S_OLD_TOKEN (1ul << (GSS_C_SUPPLEMENTARY_OFFSET + 2)) |
michael@0 | 443 | #define GSS_S_UNSEQ_TOKEN (1ul << (GSS_C_SUPPLEMENTARY_OFFSET + 3)) |
michael@0 | 444 | #define GSS_S_GAP_TOKEN (1ul << (GSS_C_SUPPLEMENTARY_OFFSET + 4)) |
michael@0 | 445 | |
michael@0 | 446 | /* |
michael@0 | 447 | * Finally, function prototypes for the GSS-API routines. |
michael@0 | 448 | */ |
michael@0 | 449 | |
michael@0 | 450 | GSS_MAKE_TYPEDEF |
michael@0 | 451 | OM_uint32 |
michael@0 | 452 | GSS_CALLCONV GSS_FUNC(gss_acquire_cred) |
michael@0 | 453 | (OM_uint32 *, /* minor_status */ |
michael@0 | 454 | const gss_name_t, /* desired_name */ |
michael@0 | 455 | OM_uint32, /* time_req */ |
michael@0 | 456 | const gss_OID_set, /* desired_mechs */ |
michael@0 | 457 | gss_cred_usage_t, /* cred_usage */ |
michael@0 | 458 | gss_cred_id_t *, /* output_cred_handle */ |
michael@0 | 459 | gss_OID_set *, /* actual_mechs */ |
michael@0 | 460 | OM_uint32 * /* time_rec */ |
michael@0 | 461 | ); |
michael@0 | 462 | |
michael@0 | 463 | GSS_MAKE_TYPEDEF |
michael@0 | 464 | OM_uint32 |
michael@0 | 465 | GSS_CALLCONV GSS_FUNC(gss_release_cred) |
michael@0 | 466 | (OM_uint32 *, /* minor_status */ |
michael@0 | 467 | gss_cred_id_t * /* cred_handle */ |
michael@0 | 468 | ); |
michael@0 | 469 | |
michael@0 | 470 | GSS_MAKE_TYPEDEF |
michael@0 | 471 | OM_uint32 |
michael@0 | 472 | GSS_CALLCONV GSS_FUNC(gss_init_sec_context) |
michael@0 | 473 | (OM_uint32 *, /* minor_status */ |
michael@0 | 474 | const gss_cred_id_t, /* initiator_cred_handle */ |
michael@0 | 475 | gss_ctx_id_t *, /* context_handle */ |
michael@0 | 476 | const gss_name_t, /* target_name */ |
michael@0 | 477 | const gss_OID, /* mech_type */ |
michael@0 | 478 | OM_uint32, /* req_flags */ |
michael@0 | 479 | OM_uint32, /* time_req */ |
michael@0 | 480 | const gss_channel_bindings_t, /* input_chan_bindings */ |
michael@0 | 481 | const gss_buffer_t, /* input_token */ |
michael@0 | 482 | gss_OID *, /* actual_mech_type */ |
michael@0 | 483 | gss_buffer_t, /* output_token */ |
michael@0 | 484 | OM_uint32 *, /* ret_flags */ |
michael@0 | 485 | OM_uint32 * /* time_rec */ |
michael@0 | 486 | ); |
michael@0 | 487 | |
michael@0 | 488 | GSS_MAKE_TYPEDEF |
michael@0 | 489 | OM_uint32 |
michael@0 | 490 | GSS_CALLCONV GSS_FUNC(gss_accept_sec_context) |
michael@0 | 491 | (OM_uint32 *, /* minor_status */ |
michael@0 | 492 | gss_ctx_id_t *, /* context_handle */ |
michael@0 | 493 | const gss_cred_id_t, /* acceptor_cred_handle */ |
michael@0 | 494 | const gss_buffer_t, /* input_token_buffer */ |
michael@0 | 495 | const gss_channel_bindings_t, /* input_chan_bindings */ |
michael@0 | 496 | gss_name_t *, /* src_name */ |
michael@0 | 497 | gss_OID *, /* mech_type */ |
michael@0 | 498 | gss_buffer_t, /* output_token */ |
michael@0 | 499 | OM_uint32 *, /* ret_flags */ |
michael@0 | 500 | OM_uint32 *, /* time_rec */ |
michael@0 | 501 | gss_cred_id_t * /* delegated_cred_handle */ |
michael@0 | 502 | ); |
michael@0 | 503 | |
michael@0 | 504 | GSS_MAKE_TYPEDEF |
michael@0 | 505 | OM_uint32 |
michael@0 | 506 | GSS_CALLCONV GSS_FUNC(gss_process_context_token) |
michael@0 | 507 | (OM_uint32 *, /* minor_status */ |
michael@0 | 508 | const gss_ctx_id_t, /* context_handle */ |
michael@0 | 509 | const gss_buffer_t /* token_buffer */ |
michael@0 | 510 | ); |
michael@0 | 511 | |
michael@0 | 512 | GSS_MAKE_TYPEDEF |
michael@0 | 513 | OM_uint32 |
michael@0 | 514 | GSS_CALLCONV GSS_FUNC(gss_delete_sec_context) |
michael@0 | 515 | (OM_uint32 *, /* minor_status */ |
michael@0 | 516 | gss_ctx_id_t *, /* context_handle */ |
michael@0 | 517 | gss_buffer_t /* output_token */ |
michael@0 | 518 | ); |
michael@0 | 519 | |
michael@0 | 520 | GSS_MAKE_TYPEDEF |
michael@0 | 521 | OM_uint32 |
michael@0 | 522 | GSS_CALLCONV GSS_FUNC(gss_context_time) |
michael@0 | 523 | (OM_uint32 *, /* minor_status */ |
michael@0 | 524 | const gss_ctx_id_t, /* context_handle */ |
michael@0 | 525 | OM_uint32 * /* time_rec */ |
michael@0 | 526 | ); |
michael@0 | 527 | |
michael@0 | 528 | GSS_MAKE_TYPEDEF |
michael@0 | 529 | OM_uint32 |
michael@0 | 530 | GSS_CALLCONV GSS_FUNC(gss_get_mic) |
michael@0 | 531 | (OM_uint32 *, /* minor_status */ |
michael@0 | 532 | const gss_ctx_id_t, /* context_handle */ |
michael@0 | 533 | gss_qop_t, /* qop_req */ |
michael@0 | 534 | const gss_buffer_t, /* message_buffer */ |
michael@0 | 535 | gss_buffer_t /* message_token */ |
michael@0 | 536 | ); |
michael@0 | 537 | |
michael@0 | 538 | |
michael@0 | 539 | GSS_MAKE_TYPEDEF |
michael@0 | 540 | OM_uint32 |
michael@0 | 541 | GSS_CALLCONV GSS_FUNC(gss_verify_mic) |
michael@0 | 542 | (OM_uint32 *, /* minor_status */ |
michael@0 | 543 | const gss_ctx_id_t, /* context_handle */ |
michael@0 | 544 | const gss_buffer_t, /* message_buffer */ |
michael@0 | 545 | const gss_buffer_t, /* token_buffer */ |
michael@0 | 546 | gss_qop_t * /* qop_state */ |
michael@0 | 547 | ); |
michael@0 | 548 | |
michael@0 | 549 | GSS_MAKE_TYPEDEF |
michael@0 | 550 | OM_uint32 |
michael@0 | 551 | GSS_CALLCONV GSS_FUNC(gss_wrap) |
michael@0 | 552 | (OM_uint32 *, /* minor_status */ |
michael@0 | 553 | const gss_ctx_id_t, /* context_handle */ |
michael@0 | 554 | int, /* conf_req_flag */ |
michael@0 | 555 | gss_qop_t, /* qop_req */ |
michael@0 | 556 | const gss_buffer_t, /* input_message_buffer */ |
michael@0 | 557 | int *, /* conf_state */ |
michael@0 | 558 | gss_buffer_t /* output_message_buffer */ |
michael@0 | 559 | ); |
michael@0 | 560 | |
michael@0 | 561 | |
michael@0 | 562 | GSS_MAKE_TYPEDEF |
michael@0 | 563 | OM_uint32 |
michael@0 | 564 | GSS_CALLCONV GSS_FUNC(gss_unwrap) |
michael@0 | 565 | (OM_uint32 *, /* minor_status */ |
michael@0 | 566 | const gss_ctx_id_t, /* context_handle */ |
michael@0 | 567 | const gss_buffer_t, /* input_message_buffer */ |
michael@0 | 568 | gss_buffer_t, /* output_message_buffer */ |
michael@0 | 569 | int *, /* conf_state */ |
michael@0 | 570 | gss_qop_t * /* qop_state */ |
michael@0 | 571 | ); |
michael@0 | 572 | |
michael@0 | 573 | GSS_MAKE_TYPEDEF |
michael@0 | 574 | OM_uint32 |
michael@0 | 575 | GSS_CALLCONV GSS_FUNC(gss_display_status) |
michael@0 | 576 | (OM_uint32 *, /* minor_status */ |
michael@0 | 577 | OM_uint32, /* status_value */ |
michael@0 | 578 | int, /* status_type */ |
michael@0 | 579 | const gss_OID, /* mech_type */ |
michael@0 | 580 | OM_uint32 *, /* message_context */ |
michael@0 | 581 | gss_buffer_t /* status_string */ |
michael@0 | 582 | ); |
michael@0 | 583 | |
michael@0 | 584 | GSS_MAKE_TYPEDEF |
michael@0 | 585 | OM_uint32 |
michael@0 | 586 | GSS_CALLCONV GSS_FUNC(gss_indicate_mechs) |
michael@0 | 587 | (OM_uint32 *, /* minor_status */ |
michael@0 | 588 | gss_OID_set * /* mech_set */ |
michael@0 | 589 | ); |
michael@0 | 590 | |
michael@0 | 591 | GSS_MAKE_TYPEDEF |
michael@0 | 592 | OM_uint32 |
michael@0 | 593 | GSS_CALLCONV GSS_FUNC(gss_compare_name) |
michael@0 | 594 | (OM_uint32 *, /* minor_status */ |
michael@0 | 595 | const gss_name_t, /* name1 */ |
michael@0 | 596 | const gss_name_t, /* name2 */ |
michael@0 | 597 | int * /* name_equal */ |
michael@0 | 598 | ); |
michael@0 | 599 | |
michael@0 | 600 | GSS_MAKE_TYPEDEF |
michael@0 | 601 | OM_uint32 |
michael@0 | 602 | GSS_CALLCONV GSS_FUNC(gss_display_name) |
michael@0 | 603 | (OM_uint32 *, /* minor_status */ |
michael@0 | 604 | const gss_name_t, /* input_name */ |
michael@0 | 605 | gss_buffer_t, /* output_name_buffer */ |
michael@0 | 606 | gss_OID * /* output_name_type */ |
michael@0 | 607 | ); |
michael@0 | 608 | |
michael@0 | 609 | GSS_MAKE_TYPEDEF |
michael@0 | 610 | OM_uint32 |
michael@0 | 611 | GSS_CALLCONV GSS_FUNC(gss_import_name) |
michael@0 | 612 | (OM_uint32 *, /* minor_status */ |
michael@0 | 613 | const gss_buffer_t, /* input_name_buffer */ |
michael@0 | 614 | const gss_OID, /* input_name_type */ |
michael@0 | 615 | gss_name_t * /* output_name */ |
michael@0 | 616 | ); |
michael@0 | 617 | |
michael@0 | 618 | GSS_MAKE_TYPEDEF |
michael@0 | 619 | OM_uint32 |
michael@0 | 620 | GSS_CALLCONV GSS_FUNC(gss_export_name) |
michael@0 | 621 | (OM_uint32 *, /* minor_status */ |
michael@0 | 622 | const gss_name_t, /* input_name */ |
michael@0 | 623 | gss_buffer_t /* exported_name */ |
michael@0 | 624 | ); |
michael@0 | 625 | |
michael@0 | 626 | GSS_MAKE_TYPEDEF |
michael@0 | 627 | OM_uint32 |
michael@0 | 628 | GSS_CALLCONV GSS_FUNC(gss_release_name) |
michael@0 | 629 | (OM_uint32 *, /* minor_status */ |
michael@0 | 630 | gss_name_t * /* input_name */ |
michael@0 | 631 | ); |
michael@0 | 632 | |
michael@0 | 633 | GSS_MAKE_TYPEDEF |
michael@0 | 634 | OM_uint32 |
michael@0 | 635 | GSS_CALLCONV GSS_FUNC(gss_release_buffer) |
michael@0 | 636 | (OM_uint32 *, /* minor_status */ |
michael@0 | 637 | gss_buffer_t /* buffer */ |
michael@0 | 638 | ); |
michael@0 | 639 | |
michael@0 | 640 | GSS_MAKE_TYPEDEF |
michael@0 | 641 | OM_uint32 |
michael@0 | 642 | GSS_CALLCONV GSS_FUNC(gss_release_oid_set) |
michael@0 | 643 | (OM_uint32 *, /* minor_status */ |
michael@0 | 644 | gss_OID_set * /* set */ |
michael@0 | 645 | ); |
michael@0 | 646 | |
michael@0 | 647 | GSS_MAKE_TYPEDEF |
michael@0 | 648 | OM_uint32 |
michael@0 | 649 | GSS_CALLCONV GSS_FUNC(gss_inquire_cred) |
michael@0 | 650 | (OM_uint32 *, /* minor_status */ |
michael@0 | 651 | const gss_cred_id_t, /* cred_handle */ |
michael@0 | 652 | gss_name_t *, /* name */ |
michael@0 | 653 | OM_uint32 *, /* lifetime */ |
michael@0 | 654 | gss_cred_usage_t *, /* cred_usage */ |
michael@0 | 655 | gss_OID_set * /* mechanisms */ |
michael@0 | 656 | ); |
michael@0 | 657 | |
michael@0 | 658 | GSS_MAKE_TYPEDEF |
michael@0 | 659 | OM_uint32 |
michael@0 | 660 | GSS_CALLCONV GSS_FUNC(gss_inquire_context) |
michael@0 | 661 | (OM_uint32 *, /* minor_status */ |
michael@0 | 662 | const gss_ctx_id_t, /* context_handle */ |
michael@0 | 663 | gss_name_t *, /* src_name */ |
michael@0 | 664 | gss_name_t *, /* targ_name */ |
michael@0 | 665 | OM_uint32 *, /* lifetime_rec */ |
michael@0 | 666 | gss_OID *, /* mech_type */ |
michael@0 | 667 | OM_uint32 *, /* ctx_flags */ |
michael@0 | 668 | int *, /* locally_initiated */ |
michael@0 | 669 | int * /* open */ |
michael@0 | 670 | ); |
michael@0 | 671 | |
michael@0 | 672 | GSS_MAKE_TYPEDEF |
michael@0 | 673 | OM_uint32 |
michael@0 | 674 | GSS_CALLCONV GSS_FUNC(gss_wrap_size_limit) |
michael@0 | 675 | (OM_uint32 *, /* minor_status */ |
michael@0 | 676 | const gss_ctx_id_t, /* context_handle */ |
michael@0 | 677 | int, /* conf_req_flag */ |
michael@0 | 678 | gss_qop_t, /* qop_req */ |
michael@0 | 679 | OM_uint32, /* req_output_size */ |
michael@0 | 680 | OM_uint32 * /* max_input_size */ |
michael@0 | 681 | ); |
michael@0 | 682 | |
michael@0 | 683 | GSS_MAKE_TYPEDEF |
michael@0 | 684 | OM_uint32 |
michael@0 | 685 | GSS_CALLCONV GSS_FUNC(gss_add_cred) |
michael@0 | 686 | (OM_uint32 *, /* minor_status */ |
michael@0 | 687 | const gss_cred_id_t, /* input_cred_handle */ |
michael@0 | 688 | const gss_name_t, /* desired_name */ |
michael@0 | 689 | const gss_OID, /* desired_mech */ |
michael@0 | 690 | gss_cred_usage_t, /* cred_usage */ |
michael@0 | 691 | OM_uint32, /* initiator_time_req */ |
michael@0 | 692 | OM_uint32, /* acceptor_time_req */ |
michael@0 | 693 | gss_cred_id_t *, /* output_cred_handle */ |
michael@0 | 694 | gss_OID_set *, /* actual_mechs */ |
michael@0 | 695 | OM_uint32 *, /* initiator_time_rec */ |
michael@0 | 696 | OM_uint32 * /* acceptor_time_rec */ |
michael@0 | 697 | ); |
michael@0 | 698 | |
michael@0 | 699 | GSS_MAKE_TYPEDEF |
michael@0 | 700 | OM_uint32 |
michael@0 | 701 | GSS_CALLCONV GSS_FUNC(gss_inquire_cred_by_mech) |
michael@0 | 702 | (OM_uint32 *, /* minor_status */ |
michael@0 | 703 | const gss_cred_id_t, /* cred_handle */ |
michael@0 | 704 | const gss_OID, /* mech_type */ |
michael@0 | 705 | gss_name_t *, /* name */ |
michael@0 | 706 | OM_uint32 *, /* initiator_lifetime */ |
michael@0 | 707 | OM_uint32 *, /* acceptor_lifetime */ |
michael@0 | 708 | gss_cred_usage_t * /* cred_usage */ |
michael@0 | 709 | ); |
michael@0 | 710 | |
michael@0 | 711 | GSS_MAKE_TYPEDEF |
michael@0 | 712 | OM_uint32 |
michael@0 | 713 | GSS_CALLCONV GSS_FUNC(gss_export_sec_context) |
michael@0 | 714 | (OM_uint32 *, /* minor_status */ |
michael@0 | 715 | gss_ctx_id_t *, /* context_handle */ |
michael@0 | 716 | gss_buffer_t /* interprocess_token */ |
michael@0 | 717 | ); |
michael@0 | 718 | |
michael@0 | 719 | GSS_MAKE_TYPEDEF |
michael@0 | 720 | OM_uint32 |
michael@0 | 721 | GSS_CALLCONV GSS_FUNC(gss_import_sec_context) |
michael@0 | 722 | (OM_uint32 *, /* minor_status */ |
michael@0 | 723 | const gss_buffer_t, /* interprocess_token */ |
michael@0 | 724 | gss_ctx_id_t * /* context_handle */ |
michael@0 | 725 | ); |
michael@0 | 726 | |
michael@0 | 727 | GSS_MAKE_TYPEDEF |
michael@0 | 728 | OM_uint32 |
michael@0 | 729 | GSS_CALLCONV GSS_FUNC(gss_create_empty_oid_set) |
michael@0 | 730 | (OM_uint32 *, /* minor_status */ |
michael@0 | 731 | gss_OID_set * /* oid_set */ |
michael@0 | 732 | ); |
michael@0 | 733 | |
michael@0 | 734 | GSS_MAKE_TYPEDEF |
michael@0 | 735 | OM_uint32 |
michael@0 | 736 | GSS_CALLCONV GSS_FUNC(gss_add_oid_set_member) |
michael@0 | 737 | (OM_uint32 *, /* minor_status */ |
michael@0 | 738 | const gss_OID, /* member_oid */ |
michael@0 | 739 | gss_OID_set * /* oid_set */ |
michael@0 | 740 | ); |
michael@0 | 741 | |
michael@0 | 742 | GSS_MAKE_TYPEDEF |
michael@0 | 743 | OM_uint32 |
michael@0 | 744 | GSS_CALLCONV GSS_FUNC(gss_test_oid_set_member) |
michael@0 | 745 | (OM_uint32 *, /* minor_status */ |
michael@0 | 746 | const gss_OID, /* member */ |
michael@0 | 747 | const gss_OID_set, /* set */ |
michael@0 | 748 | int * /* present */ |
michael@0 | 749 | ); |
michael@0 | 750 | |
michael@0 | 751 | GSS_MAKE_TYPEDEF |
michael@0 | 752 | OM_uint32 |
michael@0 | 753 | GSS_CALLCONV GSS_FUNC(gss_inquire_names_for_mech) |
michael@0 | 754 | (OM_uint32 *, /* minor_status */ |
michael@0 | 755 | const gss_OID, /* mechanism */ |
michael@0 | 756 | gss_OID_set * /* name_types */ |
michael@0 | 757 | ); |
michael@0 | 758 | |
michael@0 | 759 | GSS_MAKE_TYPEDEF |
michael@0 | 760 | OM_uint32 |
michael@0 | 761 | GSS_CALLCONV GSS_FUNC(gss_inquire_mechs_for_name) |
michael@0 | 762 | (OM_uint32 *, /* minor_status */ |
michael@0 | 763 | const gss_name_t, /* input_name */ |
michael@0 | 764 | gss_OID_set * /* mech_types */ |
michael@0 | 765 | ); |
michael@0 | 766 | |
michael@0 | 767 | GSS_MAKE_TYPEDEF |
michael@0 | 768 | OM_uint32 |
michael@0 | 769 | GSS_CALLCONV GSS_FUNC(gss_canonicalize_name) |
michael@0 | 770 | (OM_uint32 *, /* minor_status */ |
michael@0 | 771 | const gss_name_t, /* input_name */ |
michael@0 | 772 | const gss_OID, /* mech_type */ |
michael@0 | 773 | gss_name_t * /* output_name */ |
michael@0 | 774 | ); |
michael@0 | 775 | |
michael@0 | 776 | GSS_MAKE_TYPEDEF |
michael@0 | 777 | OM_uint32 |
michael@0 | 778 | GSS_CALLCONV GSS_FUNC(gss_duplicate_name) |
michael@0 | 779 | (OM_uint32 *, /* minor_status */ |
michael@0 | 780 | const gss_name_t, /* src_name */ |
michael@0 | 781 | gss_name_t * /* dest_name */ |
michael@0 | 782 | ); |
michael@0 | 783 | |
michael@0 | 784 | /* |
michael@0 | 785 | * The following routines are obsolete variants of gss_get_mic, |
michael@0 | 786 | * gss_verify_mic, gss_wrap and gss_unwrap. They should be |
michael@0 | 787 | * provided by GSSAPI V2 implementations for backwards |
michael@0 | 788 | * compatibility with V1 applications. Distinct entrypoints |
michael@0 | 789 | * (as opposed to #defines) should be provided, both to allow |
michael@0 | 790 | * GSSAPI V1 applications to link against GSSAPI V2 implementations, |
michael@0 | 791 | * and to retain the slight parameter type differences between the |
michael@0 | 792 | * obsolete versions of these routines and their current forms. |
michael@0 | 793 | */ |
michael@0 | 794 | |
michael@0 | 795 | GSS_MAKE_TYPEDEF |
michael@0 | 796 | OM_uint32 |
michael@0 | 797 | GSS_CALLCONV GSS_FUNC(gss_sign) |
michael@0 | 798 | (OM_uint32 *, /* minor_status */ |
michael@0 | 799 | gss_ctx_id_t, /* context_handle */ |
michael@0 | 800 | int, /* qop_req */ |
michael@0 | 801 | gss_buffer_t, /* message_buffer */ |
michael@0 | 802 | gss_buffer_t /* message_token */ |
michael@0 | 803 | ); |
michael@0 | 804 | |
michael@0 | 805 | |
michael@0 | 806 | GSS_MAKE_TYPEDEF |
michael@0 | 807 | OM_uint32 |
michael@0 | 808 | GSS_CALLCONV GSS_FUNC(gss_verify) |
michael@0 | 809 | (OM_uint32 *, /* minor_status */ |
michael@0 | 810 | gss_ctx_id_t, /* context_handle */ |
michael@0 | 811 | gss_buffer_t, /* message_buffer */ |
michael@0 | 812 | gss_buffer_t, /* token_buffer */ |
michael@0 | 813 | int * /* qop_state */ |
michael@0 | 814 | ); |
michael@0 | 815 | |
michael@0 | 816 | GSS_MAKE_TYPEDEF |
michael@0 | 817 | OM_uint32 |
michael@0 | 818 | GSS_CALLCONV GSS_FUNC(gss_seal) |
michael@0 | 819 | (OM_uint32 *, /* minor_status */ |
michael@0 | 820 | gss_ctx_id_t, /* context_handle */ |
michael@0 | 821 | int, /* conf_req_flag */ |
michael@0 | 822 | int, /* qop_req */ |
michael@0 | 823 | gss_buffer_t, /* input_message_buffer */ |
michael@0 | 824 | int *, /* conf_state */ |
michael@0 | 825 | gss_buffer_t /* output_message_buffer */ |
michael@0 | 826 | ); |
michael@0 | 827 | |
michael@0 | 828 | |
michael@0 | 829 | GSS_MAKE_TYPEDEF |
michael@0 | 830 | OM_uint32 |
michael@0 | 831 | GSS_CALLCONV GSS_FUNC(gss_unseal) |
michael@0 | 832 | (OM_uint32 *, /* minor_status */ |
michael@0 | 833 | gss_ctx_id_t, /* context_handle */ |
michael@0 | 834 | gss_buffer_t, /* input_message_buffer */ |
michael@0 | 835 | gss_buffer_t, /* output_message_buffer */ |
michael@0 | 836 | int *, /* conf_state */ |
michael@0 | 837 | int * /* qop_state */ |
michael@0 | 838 | ); |
michael@0 | 839 | |
michael@0 | 840 | |
michael@0 | 841 | #if defined(XP_MACOSX) |
michael@0 | 842 | # pragma pack(pop) |
michael@0 | 843 | #endif |
michael@0 | 844 | |
michael@0 | 845 | EXTERN_C_END |
michael@0 | 846 | |
michael@0 | 847 | #endif /* GSSAPI_H_ */ |
michael@0 | 848 |