1/* 2 * Copyright (c) 2005, 2013, Oracle and/or its affiliates. All rights reserved. 3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4 * 5 * This code is free software; you can redistribute it and/or modify it 6 * under the terms of the GNU General Public License version 2 only, as 7 * published by the Free Software Foundation. Oracle designates this 8 * particular file as subject to the "Classpath" exception as provided 9 * by Oracle in the LICENSE file that accompanied this code. 10 * 11 * This code is distributed in the hope that it will be useful, but WITHOUT 12 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 13 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 14 * version 2 for more details (a copy is included in the LICENSE file that 15 * accompanied this code). 16 * 17 * You should have received a copy of the GNU General Public License version 18 * 2 along with this work; if not, write to the Free Software Foundation, 19 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 20 * 21 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 22 * or visit www.oracle.com if you need additional information or have any 23 * questions. 24 */ 25 26/* This is the gssapi.h prologue. */ 27/* It contains some choice pieces of autoconf.h */ 28#define GSS_SIZEOF_INT 4 29#define GSS_SIZEOF_LONG 4 30#define GSS_SIZEOF_SHORT 2 31 32#ifndef _GSSAPI_H_ 33#define _GSSAPI_H_ 34 35#if defined(__MACH__) && defined(__APPLE__) 36# include <TargetConditionals.h> 37# if TARGET_RT_MAC_CFM 38# error "Use KfM 4.0 SDK headers for CFM compilation." 39# endif 40#endif 41 42#ifdef __cplusplus 43extern "C" { 44#endif /* __cplusplus */ 45 46#if TARGET_OS_MAC 47# pragma pack(push,2) 48#endif 49 50/* 51 * First, include stddef.h to get size_t defined. 52 */ 53#include <stddef.h> 54 55/* 56 * POSIX says that sys/types.h is where size_t is defined. 57 */ 58#include <sys/types.h> 59 60typedef void * gss_name_t; 61typedef void * gss_cred_id_t; 62typedef void * gss_ctx_id_t; 63 64/* 65 * The following type must be defined as the smallest natural unsigned integer 66 * supported by the platform that has at least 32 bits of precision. 67 */ 68#if (GSS_SIZEOF_SHORT == 4) 69typedef unsigned short gss_uint32; 70typedef short gss_int32; 71#elif (GSS_SIZEOF_INT == 4) 72typedef unsigned int gss_uint32; 73typedef int gss_int32; 74#elif (GSS_SIZEOF_LONG == 4) 75typedef unsigned long gss_uint32; 76typedef long gss_int32; 77#endif 78 79typedef gss_uint32 OM_uint32; 80 81typedef struct gss_OID_desc_struct { 82 OM_uint32 length; 83 void *elements; 84} gss_OID_desc, *gss_OID; 85 86typedef struct gss_OID_set_desc_struct { 87 size_t count; 88 gss_OID elements; 89} gss_OID_set_desc, *gss_OID_set; 90 91typedef struct gss_buffer_desc_struct { 92 size_t length; 93 void *value; 94} gss_buffer_desc, *gss_buffer_t; 95 96typedef struct gss_channel_bindings_struct { 97 OM_uint32 initiator_addrtype; 98 gss_buffer_desc initiator_address; 99 OM_uint32 acceptor_addrtype; 100 gss_buffer_desc acceptor_address; 101 gss_buffer_desc application_data; 102} *gss_channel_bindings_t; 103 104/* 105 * For now, define a QOP-type as an OM_uint32 106 */ 107typedef OM_uint32 gss_qop_t; 108typedef int gss_cred_usage_t; 109 110/* 111 * Flag bits for context-level services. 112 */ 113#define GSS_C_DELEG_FLAG 1 114#define GSS_C_MUTUAL_FLAG 2 115#define GSS_C_REPLAY_FLAG 4 116#define GSS_C_SEQUENCE_FLAG 8 117#define GSS_C_CONF_FLAG 16 118#define GSS_C_INTEG_FLAG 32 119#define GSS_C_ANON_FLAG 64 120#define GSS_C_PROT_READY_FLAG 128 121#define GSS_C_TRANS_FLAG 256 122 123/* 124 * Credential usage options 125 */ 126#define GSS_C_BOTH 0 127#define GSS_C_INITIATE 1 128#define GSS_C_ACCEPT 2 129 130/* 131 * Status code types for gss_display_status 132 */ 133#define GSS_C_GSS_CODE 1 134#define GSS_C_MECH_CODE 2 135 136/* 137 * The constant definitions for channel-bindings address families 138 */ 139#define GSS_C_AF_UNSPEC 0 140#define GSS_C_AF_LOCAL 1 141#define GSS_C_AF_INET 2 142#define GSS_C_AF_IMPLINK 3 143#define GSS_C_AF_PUP 4 144#define GSS_C_AF_CHAOS 5 145#define GSS_C_AF_NS 6 146#define GSS_C_AF_NBS 7 147#define GSS_C_AF_ECMA 8 148#define GSS_C_AF_DATAKIT 9 149#define GSS_C_AF_CCITT 10 150#define GSS_C_AF_SNA 11 151#define GSS_C_AF_DECnet 12 152#define GSS_C_AF_DLI 13 153#define GSS_C_AF_LAT 14 154#define GSS_C_AF_HYLINK 15 155#define GSS_C_AF_APPLETALK 16 156#define GSS_C_AF_BSC 17 157#define GSS_C_AF_DSS 18 158#define GSS_C_AF_OSI 19 159#define GSS_C_AF_X25 21 160 161#define GSS_C_AF_NULLADDR 255 162 163/* 164 * Various Null values. 165 */ 166#define GSS_C_NO_NAME ((gss_name_t) 0) 167#define GSS_C_NO_BUFFER ((gss_buffer_t) 0) 168#define GSS_C_NO_OID ((gss_OID) 0) 169#define GSS_C_NO_OID_SET ((gss_OID_set) 0) 170#define GSS_C_NO_CONTEXT ((gss_ctx_id_t) 0) 171#define GSS_C_NO_CREDENTIAL ((gss_cred_id_t) 0) 172#define GSS_C_NO_CHANNEL_BINDINGS ((gss_channel_bindings_t) 0) 173#define GSS_C_EMPTY_BUFFER {0, NULL} 174 175/* 176 * Some alternate names for a couple of the above values. These are defined 177 * for V1 compatibility. 178 */ 179#define GSS_C_NULL_OID GSS_C_NO_OID 180#define GSS_C_NULL_OID_SET GSS_C_NO_OID_SET 181 182/* 183 * Define the default Quality of Protection for per-message services. Note 184 * that an implementation that offers multiple levels of QOP may either reserve 185 * a value (for example zero, as assumed here) to mean "default protection", or 186 * alternatively may simply equate GSS_C_QOP_DEFAULT to a specific explicit 187 * QOP value. However a value of 0 should always be interpreted by a GSSAPI 188 * implementation as a request for the default protection level. 189 */ 190#define GSS_C_QOP_DEFAULT 0 191 192/* 193 * Expiration time of 2^32-1 seconds means infinite lifetime for a 194 * credential or security context 195 */ 196#define GSS_C_INDEFINITE ((OM_uint32) 0xfffffffful) 197 198 199/* Major status codes */ 200 201#define GSS_S_COMPLETE 0 202 203/* 204 * Some "helper" definitions to make the status code macros obvious. 205 */ 206#define GSS_C_CALLING_ERROR_OFFSET 24 207#define GSS_C_ROUTINE_ERROR_OFFSET 16 208#define GSS_C_SUPPLEMENTARY_OFFSET 0 209#define GSS_C_CALLING_ERROR_MASK ((OM_uint32) 0377ul) 210#define GSS_C_ROUTINE_ERROR_MASK ((OM_uint32) 0377ul) 211#define GSS_C_SUPPLEMENTARY_MASK ((OM_uint32) 0177777ul) 212 213/* 214 * The macros that test status codes for error conditions. Note that the 215 * GSS_ERROR() macro has changed slightly from the V1 GSSAPI so that it now 216 * evaluates its argument only once. 217 */ 218#define GSS_CALLING_ERROR(x) \ 219 ((x) & (GSS_C_CALLING_ERROR_MASK << GSS_C_CALLING_ERROR_OFFSET)) 220#define GSS_ROUTINE_ERROR(x) \ 221 ((x) & (GSS_C_ROUTINE_ERROR_MASK << GSS_C_ROUTINE_ERROR_OFFSET)) 222#define GSS_SUPPLEMENTARY_INFO(x) \ 223 ((x) & (GSS_C_SUPPLEMENTARY_MASK << GSS_C_SUPPLEMENTARY_OFFSET)) 224#define GSS_ERROR(x) \ 225 ((x) & ((GSS_C_CALLING_ERROR_MASK << GSS_C_CALLING_ERROR_OFFSET) | \ 226 (GSS_C_ROUTINE_ERROR_MASK << GSS_C_ROUTINE_ERROR_OFFSET))) 227 228/* 229 * Now the actual status code definitions 230 */ 231 232/* 233 * Calling errors: 234 */ 235#define GSS_S_CALL_INACCESSIBLE_READ \ 236 (((OM_uint32) 1ul) << GSS_C_CALLING_ERROR_OFFSET) 237#define GSS_S_CALL_INACCESSIBLE_WRITE \ 238 (((OM_uint32) 2ul) << GSS_C_CALLING_ERROR_OFFSET) 239#define GSS_S_CALL_BAD_STRUCTURE \ 240 (((OM_uint32) 3ul) << GSS_C_CALLING_ERROR_OFFSET) 241 242/* 243 * Routine errors: 244 */ 245#define GSS_S_BAD_MECH (((OM_uint32) 1ul) << GSS_C_ROUTINE_ERROR_OFFSET) 246#define GSS_S_BAD_NAME (((OM_uint32) 2ul) << GSS_C_ROUTINE_ERROR_OFFSET) 247#define GSS_S_BAD_NAMETYPE (((OM_uint32) 3ul) << GSS_C_ROUTINE_ERROR_OFFSET) 248#define GSS_S_BAD_BINDINGS (((OM_uint32) 4ul) << GSS_C_ROUTINE_ERROR_OFFSET) 249#define GSS_S_BAD_STATUS (((OM_uint32) 5ul) << GSS_C_ROUTINE_ERROR_OFFSET) 250#define GSS_S_BAD_SIG (((OM_uint32) 6ul) << GSS_C_ROUTINE_ERROR_OFFSET) 251#define GSS_S_NO_CRED (((OM_uint32) 7ul) << GSS_C_ROUTINE_ERROR_OFFSET) 252#define GSS_S_NO_CONTEXT (((OM_uint32) 8ul) << GSS_C_ROUTINE_ERROR_OFFSET) 253#define GSS_S_DEFECTIVE_TOKEN (((OM_uint32) 9ul) << GSS_C_ROUTINE_ERROR_OFFSET) 254#define GSS_S_DEFECTIVE_CREDENTIAL \ 255 (((OM_uint32) 10ul) << GSS_C_ROUTINE_ERROR_OFFSET) 256#define GSS_S_CREDENTIALS_EXPIRED \ 257 (((OM_uint32) 11ul) << GSS_C_ROUTINE_ERROR_OFFSET) 258#define GSS_S_CONTEXT_EXPIRED \ 259 (((OM_uint32) 12ul) << GSS_C_ROUTINE_ERROR_OFFSET) 260#define GSS_S_FAILURE (((OM_uint32) 13ul) << GSS_C_ROUTINE_ERROR_OFFSET) 261#define GSS_S_BAD_QOP (((OM_uint32) 14ul) << GSS_C_ROUTINE_ERROR_OFFSET) 262#define GSS_S_UNAUTHORIZED (((OM_uint32) 15ul) << GSS_C_ROUTINE_ERROR_OFFSET) 263#define GSS_S_UNAVAILABLE (((OM_uint32) 16ul) << GSS_C_ROUTINE_ERROR_OFFSET) 264#define GSS_S_DUPLICATE_ELEMENT \ 265 (((OM_uint32) 17ul) << GSS_C_ROUTINE_ERROR_OFFSET) 266#define GSS_S_NAME_NOT_MN \ 267 (((OM_uint32) 18ul) << GSS_C_ROUTINE_ERROR_OFFSET) 268 269/* 270 * Supplementary info bits: 271 */ 272#define GSS_S_CONTINUE_NEEDED (1 << (GSS_C_SUPPLEMENTARY_OFFSET + 0)) 273#define GSS_S_DUPLICATE_TOKEN (1 << (GSS_C_SUPPLEMENTARY_OFFSET + 1)) 274#define GSS_S_OLD_TOKEN (1 << (GSS_C_SUPPLEMENTARY_OFFSET + 2)) 275#define GSS_S_UNSEQ_TOKEN (1 << (GSS_C_SUPPLEMENTARY_OFFSET + 3)) 276#define GSS_S_GAP_TOKEN (1 << (GSS_C_SUPPLEMENTARY_OFFSET + 4)) 277 278 279/* 280 * Finally, function prototypes for the GSSAPI routines. 281 */ 282 283#if defined (_WIN32) && defined (_MSC_VER) 284# ifdef GSS_DLL_FILE 285# define GSS_DLLIMP __declspec(dllexport) 286# else 287# define GSS_DLLIMP __declspec(dllimport) 288# endif 289#else 290# define GSS_DLLIMP 291#endif 292 293/* Reserved static storage for GSS_oids. Comments are quotes from RFC 2744. 294 * 295 * The implementation must reserve static storage for a 296 * gss_OID_desc object containing the value 297 * {10, (void *)"\x2a\x86\x48\x86\xf7\x12\x01\x02\x01\x01"}, 298 * corresponding to an object-identifier value of 299 * {iso(1) member-body(2) United States(840) mit(113554) 300 * infosys(1) gssapi(2) generic(1) user_name(1)}. The constant 301 * GSS_C_NT_USER_NAME should be initialized to point 302 * to that gss_OID_desc. 303 */ 304GSS_DLLIMP extern gss_OID GSS_C_NT_USER_NAME; 305 306/* 307 * The implementation must reserve static storage for a 308 * gss_OID_desc object containing the value 309 * {10, (void *)"\x2a\x86\x48\x86\xf7\x12\x01\x02\x01\x02"}, 310 * corresponding to an object-identifier value of 311 * {iso(1) member-body(2) United States(840) mit(113554) 312 * infosys(1) gssapi(2) generic(1) machine_uid_name(2)}. 313 * The constant GSS_C_NT_MACHINE_UID_NAME should be 314 * initialized to point to that gss_OID_desc. 315 */ 316GSS_DLLIMP extern gss_OID GSS_C_NT_MACHINE_UID_NAME; 317 318/* 319 * The implementation must reserve static storage for a 320 * gss_OID_desc object containing the value 321 * {10, (void *)"\x2a\x86\x48\x86\xf7\x12\x01\x02\x01\x03"}, 322 * corresponding to an object-identifier value of 323 * {iso(1) member-body(2) United States(840) mit(113554) 324 * infosys(1) gssapi(2) generic(1) string_uid_name(3)}. 325 * The constant GSS_C_NT_STRING_UID_NAME should be 326 * initialized to point to that gss_OID_desc. 327 */ 328GSS_DLLIMP extern gss_OID GSS_C_NT_STRING_UID_NAME; 329 330/* 331 * The implementation must reserve static storage for a 332 * gss_OID_desc object containing the value 333 * {6, (void *)"\x2b\x06\x01\x05\x06\x02"}, 334 * corresponding to an object-identifier value of 335 * {iso(1) org(3) dod(6) internet(1) security(5) 336 * nametypes(6) gss-host-based-services(2)). The constant 337 * GSS_C_NT_HOSTBASED_SERVICE_X should be initialized to point 338 * to that gss_OID_desc. This is a deprecated OID value, and 339 * implementations wishing to support hostbased-service names 340 * should instead use the GSS_C_NT_HOSTBASED_SERVICE OID, 341 * defined below, to identify such names; 342 * GSS_C_NT_HOSTBASED_SERVICE_X should be accepted a synonym 343 * for GSS_C_NT_HOSTBASED_SERVICE when presented as an input 344 * parameter, but should not be emitted by GSS-API 345 * implementations 346 */ 347GSS_DLLIMP extern gss_OID GSS_C_NT_HOSTBASED_SERVICE_X; 348 349/* 350 * The implementation must reserve static storage for a 351 * gss_OID_desc object containing the value 352 * {10, (void *)"\x2a\x86\x48\x86\xf7\x12" 353 * "\x01\x02\x01\x04"}, corresponding to an 354 * object-identifier value of {iso(1) member-body(2) 355 * Unites States(840) mit(113554) infosys(1) gssapi(2) 356 * generic(1) service_name(4)}. The constant 357 * GSS_C_NT_HOSTBASED_SERVICE should be initialized 358 * to point to that gss_OID_desc. 359 */ 360GSS_DLLIMP extern gss_OID GSS_C_NT_HOSTBASED_SERVICE; 361 362/* 363 * The implementation must reserve static storage for a 364 * gss_OID_desc object containing the value 365 * {6, (void *)"\x2b\x06\01\x05\x06\x03"}, 366 * corresponding to an object identifier value of 367 * {1(iso), 3(org), 6(dod), 1(internet), 5(security), 368 * 6(nametypes), 3(gss-anonymous-name)}. The constant 369 * and GSS_C_NT_ANONYMOUS should be initialized to point 370 * to that gss_OID_desc. 371 */ 372GSS_DLLIMP extern gss_OID GSS_C_NT_ANONYMOUS; 373 374 375/* 376 * The implementation must reserve static storage for a 377 * gss_OID_desc object containing the value 378 * {6, (void *)"\x2b\x06\x01\x05\x06\x04"}, 379 * corresponding to an object-identifier value of 380 * {1(iso), 3(org), 6(dod), 1(internet), 5(security), 381 * 6(nametypes), 4(gss-api-exported-name)}. The constant 382 * GSS_C_NT_EXPORT_NAME should be initialized to point 383 * to that gss_OID_desc. 384 */ 385GSS_DLLIMP extern gss_OID GSS_C_NT_EXPORT_NAME; 386 387 388/* Function Prototypes */ 389 390OM_uint32 gss_acquire_cred( 391 OM_uint32 *, /* minor_status */ 392 gss_name_t, /* desired_name */ 393 OM_uint32, /* time_req */ 394 gss_OID_set, /* desired_mechs */ 395 gss_cred_usage_t, /* cred_usage */ 396 gss_cred_id_t *, /* output_cred_handle */ 397 gss_OID_set *, /* actual_mechs */ 398 OM_uint32 * /* time_rec */ 399); 400 401OM_uint32 gss_release_cred( 402 OM_uint32 *, /* minor_status */ 403 gss_cred_id_t * /* cred_handle */ 404); 405 406OM_uint32 gss_init_sec_context( 407 OM_uint32 *, /* minor_status */ 408 gss_cred_id_t, /* claimant_cred_handle */ 409 gss_ctx_id_t *, /* context_handle */ 410 gss_name_t, /* target_name */ 411 gss_OID, /* mech_type (used to be const) */ 412 OM_uint32, /* req_flags */ 413 OM_uint32, /* time_req */ 414 gss_channel_bindings_t, /* input_chan_bindings */ 415 gss_buffer_t, /* input_token */ 416 gss_OID *, /* actual_mech_type */ 417 gss_buffer_t, /* output_token */ 418 OM_uint32 *, /* ret_flags */ 419 OM_uint32 * /* time_rec */ 420); 421 422OM_uint32 gss_accept_sec_context( 423 OM_uint32 *, /* minor_status */ 424 gss_ctx_id_t *, /* context_handle */ 425 gss_cred_id_t, /* acceptor_cred_handle */ 426 gss_buffer_t, /* input_token_buffer */ 427 gss_channel_bindings_t, /* input_chan_bindings */ 428 gss_name_t *, /* src_name */ 429 gss_OID *, /* mech_type */ 430 gss_buffer_t, /* output_token */ 431 OM_uint32 *, /* ret_flags */ 432 OM_uint32 *, /* time_rec */ 433 gss_cred_id_t * /* delegated_cred_handle */ 434); 435 436OM_uint32 gss_process_context_token( 437 OM_uint32 *, /* minor_status */ 438 gss_ctx_id_t, /* context_handle */ 439 gss_buffer_t /* token_buffer */ 440); 441 442OM_uint32 gss_delete_sec_context( 443 OM_uint32 *, /* minor_status */ 444 gss_ctx_id_t *, /* context_handle */ 445 gss_buffer_t /* output_token */ 446); 447 448OM_uint32 gss_context_time( 449 OM_uint32 *, /* minor_status */ 450 gss_ctx_id_t, /* context_handle */ 451 OM_uint32 * /* time_rec */ 452); 453 454/* New for V2 */ 455OM_uint32 gss_get_mic( 456 OM_uint32 *, /* minor_status */ 457 gss_ctx_id_t, /* context_handle */ 458 gss_qop_t, /* qop_req */ 459 gss_buffer_t, /* message_buffer */ 460 gss_buffer_t /* message_token */ 461); 462 463/* New for V2 */ 464OM_uint32 gss_verify_mic( 465 OM_uint32 *, /* minor_status */ 466 gss_ctx_id_t, /* context_handle */ 467 gss_buffer_t, /* message_buffer */ 468 gss_buffer_t, /* message_token */ 469 gss_qop_t * /* qop_state */ 470); 471 472/* New for V2 */ 473OM_uint32 gss_wrap( 474 OM_uint32 *, /* minor_status */ 475 gss_ctx_id_t, /* context_handle */ 476 int, /* conf_req_flag */ 477 gss_qop_t, /* qop_req */ 478 gss_buffer_t, /* input_message_buffer */ 479 int *, /* conf_state */ 480 gss_buffer_t /* output_message_buffer */ 481); 482 483/* New for V2 */ 484OM_uint32 gss_unwrap( 485 OM_uint32 *, /* minor_status */ 486 gss_ctx_id_t, /* context_handle */ 487 gss_buffer_t, /* input_message_buffer */ 488 gss_buffer_t, /* output_message_buffer */ 489 int *, /* conf_state */ 490 gss_qop_t * /* qop_state */ 491); 492 493OM_uint32 gss_display_status( 494 OM_uint32 *, /* minor_status */ 495 OM_uint32, /* status_value */ 496 int, /* status_type */ 497 gss_OID, /* mech_type (used to be const) */ 498 OM_uint32 *, /* message_context */ 499 gss_buffer_t /* status_string */ 500); 501 502OM_uint32 gss_indicate_mechs( 503 OM_uint32 *, /* minor_status */ 504 gss_OID_set * /* mech_set */ 505); 506 507OM_uint32 gss_compare_name( 508 OM_uint32 *, /* minor_status */ 509 gss_name_t, /* name1 */ 510 gss_name_t, /* name2 */ 511 int * /* name_equal */ 512); 513 514OM_uint32 gss_display_name( 515 OM_uint32 *, /* minor_status */ 516 gss_name_t, /* input_name */ 517 gss_buffer_t, /* output_name_buffer */ 518 gss_OID * /* output_name_type */ 519); 520 521OM_uint32 gss_import_name( 522 OM_uint32 *, /* minor_status */ 523 gss_buffer_t, /* input_name_buffer */ 524 gss_OID, /* input_name_type(used to be const) */ 525 gss_name_t * /* output_name */ 526); 527 528OM_uint32 gss_release_name( 529 OM_uint32 *, /* minor_status */ 530 gss_name_t * /* input_name */ 531); 532 533OM_uint32 gss_release_buffer( 534 OM_uint32 *, /* minor_status */ 535 gss_buffer_t /* buffer */ 536); 537 538OM_uint32 gss_release_oid_set( 539 OM_uint32 *, /* minor_status */ 540 gss_OID_set * /* set */ 541); 542 543OM_uint32 gss_inquire_cred( 544 OM_uint32 *, /* minor_status */ 545 gss_cred_id_t, /* cred_handle */ 546 gss_name_t *, /* name */ 547 OM_uint32 *, /* lifetime */ 548 gss_cred_usage_t *, /* cred_usage */ 549 gss_OID_set * /* mechanisms */ 550); 551 552/* Last argument new for V2 */ 553OM_uint32 gss_inquire_context( 554 OM_uint32 *, /* minor_status */ 555 gss_ctx_id_t, /* context_handle */ 556 gss_name_t *, /* src_name */ 557 gss_name_t *, /* targ_name */ 558 OM_uint32 *, /* lifetime_rec */ 559 gss_OID *, /* mech_type */ 560 OM_uint32 *, /* ctx_flags */ 561 int *, /* locally_initiated */ 562 int * /* open */ 563); 564 565/* New for V2 */ 566OM_uint32 gss_wrap_size_limit( 567 OM_uint32 *, /* minor_status */ 568 gss_ctx_id_t, /* context_handle */ 569 int, /* conf_req_flag */ 570 gss_qop_t, /* qop_req */ 571 OM_uint32, /* req_output_size */ 572 OM_uint32 * /* max_input_size */ 573); 574 575/* New for V2 */ 576OM_uint32 gss_add_cred( 577 OM_uint32 *, /* minor_status */ 578 gss_cred_id_t, /* input_cred_handle */ 579 gss_name_t, /* desired_name */ 580 gss_OID, /* desired_mech */ 581 gss_cred_usage_t, /* cred_usage */ 582 OM_uint32, /* initiator_time_req */ 583 OM_uint32, /* acceptor_time_req */ 584 gss_cred_id_t *, /* output_cred_handle */ 585 gss_OID_set *, /* actual_mechs */ 586 OM_uint32 *, /* initiator_time_rec */ 587 OM_uint32 * /* acceptor_time_rec */ 588); 589 590/* New for V2 */ 591OM_uint32 gss_inquire_cred_by_mech( 592 OM_uint32 *, /* minor_status */ 593 gss_cred_id_t, /* cred_handle */ 594 gss_OID, /* mech_type */ 595 gss_name_t *, /* name */ 596 OM_uint32 *, /* initiator_lifetime */ 597 OM_uint32 *, /* acceptor_lifetime */ 598 gss_cred_usage_t * /* cred_usage */ 599); 600 601/* New for V2 */ 602OM_uint32 gss_export_sec_context( 603 OM_uint32 *, /* minor_status */ 604 gss_ctx_id_t *, /* context_handle */ 605 gss_buffer_t /* interprocess_token */ 606); 607 608/* New for V2 */ 609OM_uint32 gss_import_sec_context( 610 OM_uint32 *, /* minor_status */ 611 gss_buffer_t, /* interprocess_token */ 612 gss_ctx_id_t * /* context_handle */ 613); 614 615/* New for V2 */ 616OM_uint32 gss_release_oid( 617 OM_uint32 *, /* minor_status */ 618 gss_OID * /* oid */ 619); 620 621/* New for V2 */ 622OM_uint32 gss_create_empty_oid_set( 623 OM_uint32 *, /* minor_status */ 624 gss_OID_set * /* oid_set */ 625); 626 627/* New for V2 */ 628OM_uint32 gss_add_oid_set_member( 629 OM_uint32 *, /* minor_status */ 630 gss_OID, /* member_oid */ 631 gss_OID_set * /* oid_set */ 632); 633 634/* New for V2 */ 635OM_uint32 gss_test_oid_set_member( 636 OM_uint32 *, /* minor_status */ 637 gss_OID, /* member */ 638 gss_OID_set, /* set */ 639 int * /* present */ 640); 641 642/* New for V2 */ 643OM_uint32 gss_str_to_oid( 644 OM_uint32 *, /* minor_status */ 645 gss_buffer_t, /* oid_str */ 646 gss_OID * /* oid */ 647); 648 649/* New for V2 */ 650OM_uint32 gss_oid_to_str( 651 OM_uint32 *, /* minor_status */ 652 gss_OID, /* oid */ 653 gss_buffer_t /* oid_str */ 654); 655 656/* New for V2 */ 657OM_uint32 gss_inquire_names_for_mech( 658 OM_uint32 *, /* minor_status */ 659 gss_OID, /* mechanism */ 660 gss_OID_set * /* name_types */ 661); 662 663/* New for V2 */ 664OM_uint32 gss_export_name( 665 OM_uint32 *, /* minor_status */ 666 const gss_name_t, /* input_name */ 667 gss_buffer_t /* exported_name */ 668); 669 670/* New for V2 */ 671OM_uint32 gss_duplicate_name( 672 OM_uint32 *, /* minor_status */ 673 const gss_name_t, /* input_name */ 674 gss_name_t * /* dest_name */ 675); 676 677/* New for V2 */ 678OM_uint32 gss_canonicalize_name( 679 OM_uint32 *, /* minor_status */ 680 const gss_name_t, /* input_name */ 681 const gss_OID, /* mech_type */ 682 gss_name_t * /* output_name */ 683); 684 685#if TARGET_OS_MAC 686# pragma pack(pop) 687#endif 688 689#ifdef __cplusplus 690} 691#endif 692 693#endif /* _GSSAPI_H_ */ 694