1/* 2 * Copyright (c) 2000-2004 Apple Computer, Inc. All Rights Reserved. 3 * 4 * @APPLE_LICENSE_HEADER_START@ 5 * 6 * This file contains Original Code and/or Modifications of Original Code 7 * as defined in and that are subject to the Apple Public Source License 8 * Version 2.0 (the 'License'). You may not use this file except in 9 * compliance with the License. Please obtain a copy of the License at 10 * http://www.opensource.apple.com/apsl/ and read it before using this 11 * file. 12 * 13 * The Original Code and all software distributed under the License are 14 * distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER 15 * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, 16 * INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, 17 * FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. 18 * Please see the License for the specific language governing rights and 19 * limitations under the License. 20 * 21 * @APPLE_LICENSE_HEADER_END@ 22 * 23 * cssmapple.h -- CSSM features specific to Apple's Implementation 24 */ 25 26#ifndef _CSSMAPPLE_H_ 27#define _CSSMAPPLE_H_ 1 28 29 30#ifdef __cplusplus 31extern "C" { 32#endif 33 34/* First, an array of bits indicating various status of the cert. */ 35typedef uint32 CSSM_TP_APPLE_CERT_STATUS; 36enum 37{ 38 CSSM_CERT_STATUS_EXPIRED = 0x00000001, 39 CSSM_CERT_STATUS_NOT_VALID_YET = 0x00000002, 40 CSSM_CERT_STATUS_IS_IN_INPUT_CERTS = 0x00000004, 41 CSSM_CERT_STATUS_IS_IN_ANCHORS = 0x00000008, 42 CSSM_CERT_STATUS_IS_ROOT = 0x00000010, 43 CSSM_CERT_STATUS_IS_FROM_NET = 0x00000020, 44 /* settings found in per-user Trust Settings */ 45 CSSM_CERT_STATUS_TRUST_SETTINGS_FOUND_USER = 0x00000040, 46 /* settings found in Admin Trust Settings */ 47 CSSM_CERT_STATUS_TRUST_SETTINGS_FOUND_ADMIN = 0x00000080, 48 /* settings found in System Trust Settings */ 49 CSSM_CERT_STATUS_TRUST_SETTINGS_FOUND_SYSTEM = 0x00000100, 50 /* Trust Settings result = Trust */ 51 CSSM_CERT_STATUS_TRUST_SETTINGS_TRUST = 0x00000200, 52 /* Trust Settings result = Deny */ 53 CSSM_CERT_STATUS_TRUST_SETTINGS_DENY = 0x00000400, 54 /* Per-cert error ignored due to Trust Settings */ 55 CSSM_CERT_STATUS_TRUST_SETTINGS_IGNORED_ERROR = 0x00000800 56}; 57 58typedef struct { 59 CSSM_TP_APPLE_CERT_STATUS StatusBits; 60 uint32 NumStatusCodes; 61 CSSM_RETURN *StatusCodes; 62 63 /* index into raw cert group or AnchorCerts depending on IS_IN_ANCHORS */ 64 uint32 Index; 65 66 /* nonzero if cert came from a DLDB */ 67 CSSM_DL_DB_HANDLE DlDbHandle; 68 CSSM_DB_UNIQUE_RECORD_PTR UniqueRecord; 69} CSSM_TP_APPLE_EVIDENCE_INFO; 70 71 72#ifdef __cplusplus 73} 74#endif // __cplusplus 75 76#endif /* _CSSMAPPLE_H_ */ 77