1/* 2 * KerberosHelperContext.h 3 * KerberosHelper 4 */ 5 6/* 7 * Copyright (c) 2006-2007 Apple Inc. All rights reserved. 8 * 9 * @APPLE_LICENSE_HEADER_START@ 10 * 11 * This file contains Original Code and/or Modifications of Original Code 12 * as defined in and that are subject to the Apple Public Source License 13 * Version 2.0 (the 'License'). You may not use this file except in 14 * compliance with the License. Please obtain a copy of the License at 15 * http://www.opensource.apple.com/apsl/ and read it before using this 16 * file. 17 * 18 * The Original Code and all software distributed under the License are 19 * distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER 20 * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, 21 * INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, 22 * FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. 23 * Please see the License for the specific language governing rights and 24 * limitations under the License. 25 * 26 * @APPLE_LICENSE_HEADER_END@ 27 */ 28 29#include <Heimdal/krb5.h> 30#include <Heimdal/hx509.h> 31 32struct realm_mappings { 33 int lkdc; 34 char *hostname; 35 char *realm; 36}; 37 38 39typedef struct KRBhelperContext { 40 CFStringRef inHostName; /* User input string, still printable */ 41 CFStringRef hostname; /* calculated hostname */ 42 struct addrinfo *addr; 43 CFStringRef realm; /* calculated realmname */ 44 struct { 45 struct realm_mappings *data; 46 size_t len; 47 } realms; 48 CFStringRef inAdvertisedPrincipal; 49 char *useName, *useInstance, *useRealm, *defaultRealm; 50 krb5_context krb5_ctx; 51 hx509_context hx_ctx; 52 unsigned noGuessing:1; 53} KRBhelperContext; 54 55OSStatus 56KRBCredChangeReferenceCount(CFStringRef clientPrincipal, int change, int excl); 57 58#define kGSSAPIMechSupportsAppleLKDC CFSTR("1.2.752.43.14.3") 59