]>
Commit | Line | Data |
---|---|---|
bac41a7b A |
1 | divert(-1) |
2 | changecom(/*, */) | |
3 | /* | |
29654253 | 4 | * Copyright (c) 2000-2002 Apple Computer, Inc. All Rights Reserved. |
bac41a7b A |
5 | * |
6 | * The contents of this file constitute Original Code as defined in and are | |
7 | * subject to the Apple Public Source License Version 1.2 (the 'License'). | |
8 | * You may not use this file except in compliance with the License. Please obtain | |
9 | * a copy of the License at http://www.apple.com/publicsource and read it before | |
10 | * using this file. | |
11 | * | |
12 | * This Original Code and all software distributed under the License are | |
13 | * distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESS | |
14 | * OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, INCLUDING WITHOUT | |
15 | * LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR | |
16 | * PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. Please see the License for the | |
17 | * specific language governing rights and limitations under the License. | |
18 | */ | |
19 | ||
20 | define(`startClass', | |
21 | `define(`arrayIndex', 0)dnl | |
22 | define(`class', $1)dnl | |
23 | divert(0)dnl | |
24 | // $1 password attributes | |
25 | static const CSSM_DB_ATTRIBUTE_INFO $1Attributes[] = | |
26 | { | |
27 | divert(1)dnl | |
28 | // $1 password indices | |
29 | static const CSSM_DB_INDEX_INFO $1Indices[] = | |
30 | {') | |
31 | ||
32 | define(`endClass', | |
33 | `divert(0)dnl | |
34 | }; | |
35 | ||
36 | divert(1)dnl | |
37 | ` // Unique (primary) index' | |
38 | undivert(3) | |
39 | ` // Secondary indices' | |
40 | undivert(4)dnl | |
41 | }; | |
42 | ||
43 | divert(-1)') | |
44 | ||
45 | define(`attributeBody', | |
46 | ` { | |
47 | ifelse(index(`$1',`s'),-1, | |
48 | ` CSSM_DB_ATTRIBUTE_NAME_AS_INTEGER, | |
49 | {(char *)$3},', | |
50 | ` CSSM_DB_ATTRIBUTE_NAME_AS_STRING, | |
51 | {$4},') | |
52 | CSSM_DB_ATTRIBUTE_FORMAT_$7 | |
53 | }') | |
54 | ||
55 | define(`simpleAttribute', | |
56 | `const CSSM_DB_ATTRIBUTE_INFO $2 = | |
57 | attributeBody($*); | |
58 | ') | |
59 | ||
60 | define(`attribute', | |
61 | `ifelse(index(`$1',`U'),-1,`', | |
62 | `divert(3)dnl | |
63 | { | |
64 | CSSM_DB_INDEX_UNIQUE, | |
65 | CSSM_DB_INDEX_ON_ATTRIBUTE, | |
66 | attributeBody($*) | |
67 | }, | |
68 | ')dnl | |
69 | ifelse(index(`$1',`I'),-1,`', | |
70 | `divert(4)dnl | |
71 | { | |
72 | CSSM_DB_INDEX_NONUNIQUE, | |
73 | CSSM_DB_INDEX_ON_ATTRIBUTE, | |
74 | attributeBody($*) | |
75 | }, | |
76 | ')dnl | |
77 | divert(2)dnl | |
78 | dnl const CSSM_DB_ATTRIBUTE_INFO &`k'class()$2 = class()Attributes[arrayIndex()]; | |
79 | `#define k'class()$2 class()Attributes[arrayIndex()]; | |
80 | divert(0)dnl | |
81 | attributeBody($*),dnl | |
82 | define(`arrayIndex', incr(arrayIndex))dnl | |
83 | ') | |
84 | ||
85 | define(`attrInfo', | |
86 | `{ | |
87 | $1, | |
88 | sizeof($2Attributes) / sizeof(CSSM_DB_ATTRIBUTE_INFO), | |
89 | const_cast<CSSM_DB_ATTRIBUTE_INFO_PTR>($2Attributes) | |
90 | }') | |
91 | ||
92 | define(`indexInfo', | |
93 | `{ | |
94 | $1, | |
95 | sizeof($2Indices) / sizeof(CSSM_DB_INDEX_INFO), | |
96 | const_cast<CSSM_DB_INDEX_INFO_PTR>($2Indices) | |
97 | }') | |
98 | ||
99 | define(`parseInfo', | |
100 | `{ | |
101 | CSSM_DB_RECORDTYPE_APP_DEFINED_START, | |
102 | { | |
103 | {0,0,0,{0}}, | |
104 | {0,0}, | |
105 | 0, | |
106 | 0 | |
107 | } | |
108 | }') | |
109 | ||
29654253 A |
110 | define(`startNewClass', |
111 | `define(`indexIndex', 0)dnl | |
112 | define(`class', $1)dnl | |
113 | divert(2)dnl | |
114 | // $1 attributes | |
115 | const CSSM_DB_SCHEMA_ATTRIBUTE_INFO $1SchemaAttributeList[] = | |
116 | { | |
117 | divert(3)dnl | |
118 | // $1 indices | |
119 | const CSSM_DB_SCHEMA_INDEX_INFO $1SchemaIndexList[] = | |
120 | {') | |
121 | ||
122 | define(`endNewClass', | |
123 | `divert(2)dnl | |
124 | }; | |
125 | ||
126 | const uint32 class()SchemaAttributeCount = sizeof(class()SchemaAttributeList) / sizeof(CSSM_DB_SCHEMA_ATTRIBUTE_INFO); | |
127 | ||
128 | divert(3)dnl | |
129 | ` // Unique (primary) index' | |
130 | undivert(5) | |
131 | ` // Secondary indices' | |
132 | undivert(6)dnl | |
133 | }; | |
134 | ||
135 | const uint32 class()SchemaIndexCount = sizeof(class()SchemaIndexList) / sizeof(CSSM_DB_SCHEMA_INDEX_INFO); | |
136 | ||
137 | undivert(4)dnl | |
138 | divert(0)dnl | |
139 | undivert(2)dnl | |
140 | undivert(3)dnl') | |
141 | ||
142 | define(`newAttributeBody', | |
143 | `{ | |
144 | ifelse(index(`$1',`s'),-1, | |
145 | ` CSSM_DB_ATTRIBUTE_NAME_AS_INTEGER, | |
146 | {(char *)$3},', | |
147 | ` CSSM_DB_ATTRIBUTE_NAME_AS_STRING, | |
148 | {$4},') | |
149 | CSSM_DB_ATTRIBUTE_FORMAT_$7 | |
150 | }') | |
151 | ||
152 | define(`simpleNewAttribute', | |
153 | `const CSSM_DB_ATTRIBUTE_INFO `k'class()$2 = | |
154 | newAttributeBody($*); | |
155 | ') | |
156 | ||
157 | define(`newAttribute', | |
158 | `divert(2)dnl | |
159 | { $3, $4, { $5, $6 }, CSSM_DB_ATTRIBUTE_FORMAT_$7 }, | |
160 | divert(-1) | |
161 | ifelse(index(`$1',`S'),-1,`', | |
162 | `divert(4)dnl | |
163 | simpleNewAttribute($*) | |
164 | divert(-1)')dnl | |
165 | ||
166 | ifelse(index(`$1',`U'),-1,`', | |
167 | `divert(5)dnl | |
168 | { $3, 0, CSSM_DB_INDEX_UNIQUE, CSSM_DB_INDEX_ON_ATTRIBUTE }, | |
169 | divert(-1)')dnl | |
170 | ifelse(index(`$1',`I'),-1,`', | |
171 | `define(`indexIndex', incr(indexIndex))dnl | |
172 | divert(6)dnl | |
173 | { $3, indexIndex(), CSSM_DB_INDEX_NONUNIQUE, CSSM_DB_INDEX_ON_ATTRIBUTE }, | |
174 | divert(-1)')') | |
175 | ||
bac41a7b A |
176 | /* Start of actual output */ |
177 | divert(0)dnl | |
178 | /* | |
179 | * Generated by m4 from Schema.m4 please do not edit this file. | |
180 | */ | |
181 | ||
182 | `#include <Security/Schema.h>' | |
183 | ||
29654253 A |
184 | `#include <Security/SecCertificate.h>' |
185 | `#include <Security/TrustItem.h>' | |
bac41a7b A |
186 | `#include <Security/SecKeychainAPIPriv.h>' |
187 | `#include <Security/cssmapple.h>' | |
188 | `#include <Security/utilities.h>' | |
189 | ||
190 | namespace Security { | |
191 | ||
192 | namespace KeychainCore { | |
193 | ||
194 | namespace Schema { | |
195 | ||
196 | // Meta attributes | |
197 | simpleAttribute(` s', RelationID, 0, "RelationID", 0, NULL, UINT32) | |
198 | simpleAttribute(` s', RelationName, 1, "RelationName", 0, NULL, STRING) | |
199 | simpleAttribute(` s', AttributeID, 1, "AttributeID", 0, NULL, UINT32) | |
200 | simpleAttribute(` s', AttributeNameFormat, 2, "AttributeNameFormat", 0, NULL, UINT32) | |
201 | simpleAttribute(` s', AttributeName, 3, "AttributeName", 0, NULL, STRING) | |
202 | simpleAttribute(` s', AttributeNameID, 4, "AttributeNameID", 0, NULL, BLOB) | |
203 | simpleAttribute(` s', AttributeFormat, 5, "AttributeFormat", 0, NULL, UINT32) | |
204 | simpleAttribute(` s', IndexType, 3, "IndexType", 0, NULL, UINT32) | |
205 | ||
206 | divert(-1) | |
207 | startClass(Generic) | |
208 | attribute(` i', CreationDate, kSecCreationDateItemAttr, "CreationDate", 0, NULL, TIME_DATE) | |
209 | attribute(` i', ModDate, kSecModDateItemAttr, "ModDate", 0, NULL, TIME_DATE) | |
210 | attribute(` i', Description, kSecDescriptionItemAttr, "Description", 0, NULL, BLOB) | |
211 | attribute(` i', Comment, kSecCommentItemAttr, "Comment", 0, NULL, BLOB) | |
212 | attribute(` i', Creator, kSecCreatorItemAttr, "Creator", 0, NULL, UINT32) | |
213 | attribute(` i', Type, kSecTypeItemAttr, "Type", 0, NULL, UINT32) | |
214 | attribute(` i', ScriptCode, kSecScriptCodeItemAttr, "ScriptCode", 0, NULL, SINT32) | |
215 | attribute(` s', PrintName, kSecLabelItemAttr, "PrintName", 0, NULL, BLOB) | |
216 | attribute(` s', Alias, kSecAliasItemAttr, "Alias", 0, NULL, BLOB) | |
217 | attribute(` i', Invisible, kSecInvisibleItemAttr, "Invisible", 0, NULL, SINT32) | |
218 | attribute(` i', Negative, kSecNegativeItemAttr, "Negative", 0, NULL, SINT32) | |
219 | attribute(` i', CustomIcon, kSecCustomIconItemAttr, "CustomIcon", 0, NULL, SINT32) | |
220 | attribute(` i', Protected, kSecProtectedDataItemAttr, "Protected", 0, NULL, BLOB) | |
221 | attribute(`UIi', Account, kSecAccountItemAttr, "Account", 0, NULL, BLOB) | |
222 | attribute(`UIi', Service, kSecServiceItemAttr, "Service", 0, NULL, BLOB) | |
223 | attribute(` i', Generic, kSecGenericItemAttr, "Generic", 0, NULL, BLOB) | |
224 | endClass() | |
225 | ||
226 | startClass(Appleshare) | |
227 | attribute(` i', CreationDate, kSecCreationDateItemAttr, "CreationDate", 0, NULL, TIME_DATE) | |
228 | attribute(` i', ModDate, kSecModDateItemAttr, "ModDate", 0, NULL, TIME_DATE) | |
229 | attribute(` i', Description, kSecDescriptionItemAttr, "Description", 0, NULL, BLOB) | |
230 | attribute(` i', Comment, kSecCommentItemAttr, "Comment", 0, NULL, BLOB) | |
231 | attribute(` i', Creator, kSecCreatorItemAttr, "Creator", 0, NULL, UINT32) | |
232 | attribute(` i', Type, kSecTypeItemAttr, "Type", 0, NULL, UINT32) | |
233 | attribute(` i', ScriptCode, kSecScriptCodeItemAttr, "ScriptCode", 0, NULL, SINT32) | |
234 | attribute(` s', PrintName, kSecLabelItemAttr, "PrintName", 0, NULL, BLOB) | |
235 | attribute(` s', Alias, kSecAliasItemAttr, "Alias", 0, NULL, BLOB) | |
236 | attribute(` i', Invisible, kSecInvisibleItemAttr, "Invisible", 0, NULL, SINT32) | |
237 | attribute(` i', Negative, kSecNegativeItemAttr, "Negative", 0, NULL, SINT32) | |
238 | attribute(` i', CustomIcon, kSecCustomIconItemAttr, "CustomIcon", 0, NULL, SINT32) | |
239 | attribute(` i', Protected, kSecProtectedDataItemAttr, "Protected", 0, NULL, BLOB) | |
240 | attribute(`UIi', Account, kSecAccountItemAttr, "Account", 0, NULL, BLOB) | |
241 | attribute(`UIi', Volume, kSecVolumeItemAttr, "Volume", 0, NULL, BLOB) | |
242 | attribute(` i', Server, kSecServerItemAttr, "Server", 0, NULL, BLOB) | |
243 | attribute(` i', Protocol, kSecProtocolItemAttr, "Protocol", 0, NULL, UINT32) | |
244 | attribute(`UIi', Address, kSecAddressItemAttr, "Address", 0, NULL, BLOB) | |
245 | attribute(`UIi', Signature, kSecSignatureItemAttr, "Signature", 0, NULL, BLOB) | |
246 | endClass() | |
247 | ||
248 | startClass(Internet) | |
249 | attribute(` i', CreationDate, kSecCreationDateItemAttr, "CreationDate", 0, NULL, TIME_DATE) | |
250 | attribute(` i', ModDate, kSecModDateItemAttr, "ModDate", 0, NULL, TIME_DATE) | |
251 | attribute(` i', Description, kSecDescriptionItemAttr, "Description", 0, NULL, BLOB) | |
252 | attribute(` i', Comment, kSecCommentItemAttr, "Comment", 0, NULL, BLOB) | |
253 | attribute(` i', Creator, kSecCreatorItemAttr, "Creator", 0, NULL, UINT32) | |
254 | attribute(` i', Type, kSecTypeItemAttr, "Type", 0, NULL, UINT32) | |
255 | attribute(` i', ScriptCode, kSecScriptCodeItemAttr, "ScriptCode", 0, NULL, SINT32) | |
256 | attribute(` s', PrintName, kSecLabelItemAttr, "PrintName", 0, NULL, BLOB) | |
257 | attribute(` s', Alias, kSecAliasItemAttr, "Alias", 0, NULL, BLOB) | |
258 | attribute(` i', Invisible, kSecInvisibleItemAttr, "Invisible", 0, NULL, SINT32) | |
259 | attribute(` i', Negative, kSecNegativeItemAttr, "Negative", 0, NULL, SINT32) | |
260 | attribute(` i', CustomIcon, kSecCustomIconItemAttr, "CustomIcon", 0, NULL, SINT32) | |
261 | attribute(` i', Protected, kSecProtectedDataItemAttr, "Protected", 0, NULL, BLOB) | |
262 | attribute(`UIi', Account, kSecAccountItemAttr, "Account", 0, NULL, BLOB) | |
263 | attribute(`UIi', SecurityDomain, kSecSecurityDomainItemAttr, "SecurityDomain", 0, NULL, BLOB) | |
264 | attribute(`UIi', Server, kSecServerItemAttr, "Server", 0, NULL, BLOB) | |
265 | attribute(`UIi', Protocol, kSecProtocolItemAttr, "Protocol", 0, NULL, UINT32) | |
29654253 | 266 | attribute(`UIi', AuthType, kSecAuthenticationTypeItemAttr, "AuthType", 0, NULL, BLOB) |
bac41a7b A |
267 | attribute(`UIi', Port, kSecPortItemAttr, "Port", 0, NULL, UINT32) |
268 | attribute(`UIi', Path, kSecPathItemAttr, "Path", 0, NULL, BLOB) | |
269 | endClass() | |
270 | ||
29654253 A |
271 | startNewClass(X509Certificate) |
272 | newAttribute(`UISs', CertType, kSecCertTypeItemAttr, "CertType", 0, NULL, UINT32) | |
273 | newAttribute(` Ss', CertEncoding, kSecCertEncodingItemAttr, "CertEncoding", 0, NULL, UINT32) | |
274 | newAttribute(` Ss', PrintName, kSecLabelItemAttr, "PrintName", 0, NULL, BLOB) | |
275 | newAttribute(` Ss', Alias, kSecAliasItemAttr, "Alias", 0, NULL, BLOB) | |
276 | newAttribute(` ISs', Subject, kSecSubjectItemAttr, "Subject", 0, NULL, BLOB) | |
277 | newAttribute(`UISs', Issuer, kSecIssuerItemAttr, "Issuer", 0, NULL, BLOB) | |
278 | newAttribute(`UISs', SerialNumber, kSecSerialNumberItemAttr, "SerialNumber", 0, NULL, BLOB) | |
279 | newAttribute(` ISs', SubjectKeyIdentifier, kSecSubjectKeyIdentifierItemAttr, "SubjectKeyIdentifier", 0, NULL, BLOB) | |
280 | newAttribute(` ISs', PublicKeyHash, kSecPublicKeyHashItemAttr, "PublicKeyHash", 0, NULL, BLOB) | |
281 | endNewClass() | |
282 | ||
283 | startNewClass(UserTrust) | |
284 | newAttribute(`UISs', TrustedCertificate, kSecTrustCertAttr, "TrustedCertificate", 0, NULL, BLOB) | |
285 | newAttribute(`UISs', TrustedPolicy, kSecTrustPolicyAttr, "TrustedPolicy", 0, NULL, BLOB) | |
286 | newAttribute(` Ss', PrintName, kSecLabelItemAttr, "PrintName", 0, NULL, BLOB) | |
287 | endNewClass() | |
288 | ||
289 | ||
bac41a7b A |
290 | divert(3) |
291 | static const CSSM_DB_RECORD_ATTRIBUTE_INFO Attributes[] = | |
292 | { | |
293 | attrInfo(CSSM_DL_DB_RECORD_GENERIC_PASSWORD, Generic), | |
294 | attrInfo(CSSM_DL_DB_RECORD_APPLESHARE_PASSWORD, Appleshare), | |
295 | attrInfo(CSSM_DL_DB_RECORD_INTERNET_PASSWORD, Internet) | |
296 | }; | |
297 | ||
298 | static const CSSM_DB_RECORD_INDEX_INFO Indices[] = | |
299 | { | |
300 | indexInfo(CSSM_DL_DB_RECORD_GENERIC_PASSWORD, Generic), | |
301 | indexInfo(CSSM_DL_DB_RECORD_APPLESHARE_PASSWORD, Appleshare), | |
302 | indexInfo(CSSM_DL_DB_RECORD_INTERNET_PASSWORD, Internet) | |
303 | }; | |
304 | ||
305 | static const CSSM_DB_PARSING_MODULE_INFO ParseInfos[] = | |
306 | { | |
307 | parseInfo(), | |
308 | parseInfo(), | |
309 | parseInfo() | |
310 | }; | |
311 | ||
312 | // | |
313 | // Public stuff | |
314 | // | |
315 | const CSSM_DBINFO DBInfo = | |
316 | { | |
317 | sizeof(Attributes) / sizeof(CSSM_DB_RECORD_ATTRIBUTE_INFO), | |
318 | const_cast<CSSM_DB_PARSING_MODULE_INFO_PTR>(ParseInfos), | |
319 | const_cast<CSSM_DB_RECORD_ATTRIBUTE_INFO_PTR>(Attributes), | |
320 | const_cast<CSSM_DB_RECORD_INDEX_INFO_PTR>(Indices), | |
321 | CSSM_TRUE, | |
322 | NULL, | |
323 | NULL | |
324 | }; | |
325 | ||
326 | // | |
327 | // Schema methods | |
328 | // | |
329 | CSSM_DB_RECORDTYPE | |
330 | recordTypeFor(SecItemClass itemClass) | |
331 | { | |
332 | switch (itemClass) | |
333 | { | |
334 | case kSecGenericPasswordItemClass: return CSSM_DL_DB_RECORD_GENERIC_PASSWORD; | |
335 | case kSecInternetPasswordItemClass: return CSSM_DL_DB_RECORD_INTERNET_PASSWORD; | |
336 | case kSecAppleSharePasswordItemClass: return CSSM_DL_DB_RECORD_APPLESHARE_PASSWORD; | |
29654253 | 337 | default: return CSSM_DB_RECORDTYPE(itemClass); |
bac41a7b A |
338 | } |
339 | } | |
340 | ||
341 | SecItemClass | |
342 | itemClassFor(CSSM_DB_RECORDTYPE recordType) | |
343 | { | |
344 | switch (recordType) | |
345 | { | |
346 | case CSSM_DL_DB_RECORD_GENERIC_PASSWORD: return kSecGenericPasswordItemClass; | |
347 | case CSSM_DL_DB_RECORD_INTERNET_PASSWORD: return kSecInternetPasswordItemClass; | |
348 | case CSSM_DL_DB_RECORD_APPLESHARE_PASSWORD: return kSecAppleSharePasswordItemClass; | |
29654253 | 349 | default: return SecItemClass(recordType); |
bac41a7b A |
350 | } |
351 | } | |
352 | ||
353 | const CSSM_DB_ATTRIBUTE_INFO & | |
354 | attributeInfo(SecKeychainAttrType attrType) | |
355 | { | |
356 | switch (attrType) | |
357 | { | |
358 | case kSecCreationDateItemAttr: return kGenericCreationDate; | |
359 | case kSecModDateItemAttr: return kGenericModDate; | |
360 | case kSecDescriptionItemAttr: return kGenericDescription; | |
361 | case kSecCommentItemAttr: return kGenericComment; | |
362 | case kSecCreatorItemAttr: return kGenericCreator; | |
363 | case kSecTypeItemAttr: return kGenericType; | |
364 | case kSecScriptCodeItemAttr: return kGenericScriptCode; | |
365 | case kSecLabelItemAttr: return kGenericPrintName; | |
366 | case kSecAliasItemAttr: return kGenericAlias; | |
367 | case kSecInvisibleItemAttr: return kGenericInvisible; | |
368 | case kSecNegativeItemAttr: return kGenericNegative; | |
369 | case kSecCustomIconItemAttr: return kGenericCustomIcon; | |
370 | /* Unique Generic password attributes */ | |
371 | case kSecAccountItemAttr: return kGenericAccount; | |
372 | case kSecServiceItemAttr: return kGenericService; | |
373 | case kSecGenericItemAttr: return kGenericGeneric; | |
374 | /* Unique Appleshare password attributes */ | |
375 | case kSecVolumeItemAttr: return kAppleshareVolume; | |
376 | case kSecAddressItemAttr: return kAppleshareAddress; | |
377 | case kSecSignatureItemAttr: return kAppleshareSignature; | |
378 | /* Unique AppleShare and Internet attributes */ | |
379 | case kSecServerItemAttr: return kAppleshareServer; | |
380 | case kSecProtocolItemAttr: return kAppleshareProtocol; | |
381 | /* Unique Internet password attributes */ | |
382 | case kSecSecurityDomainItemAttr: return kInternetSecurityDomain; | |
29654253 | 383 | case kSecAuthenticationTypeItemAttr: return kInternetAuthType; |
bac41a7b A |
384 | case kSecPortItemAttr: return kInternetPort; |
385 | case kSecPathItemAttr: return kInternetPath; | |
29654253 A |
386 | /* Unique Certificate attributes */ |
387 | case kSecCertTypeItemAttr: return kX509CertificateCertType; | |
388 | case kSecCertEncodingItemAttr: return kX509CertificateCertEncoding; | |
389 | case kSecSubjectItemAttr: return kX509CertificateSubject; | |
390 | case kSecIssuerItemAttr: return kX509CertificateIssuer; | |
391 | case kSecSerialNumberItemAttr: return kX509CertificateSerialNumber; | |
392 | case kSecSubjectKeyIdentifierItemAttr: return kX509CertificateSubjectKeyIdentifier; | |
393 | case kSecPublicKeyHashItemAttr: return kX509CertificatePublicKeyHash; | |
394 | /* Unique UserTrust attributes */ | |
395 | case kSecTrustCertAttr: return kUserTrustTrustedCertificate; | |
396 | case kSecTrustPolicyAttr: return kUserTrustTrustedPolicy; | |
bac41a7b A |
397 | default: MacOSError::throwMe(errSecNoSuchAttr); // @@@ Not really but whatever. |
398 | } | |
399 | } | |
400 | ||
401 | } // end namespace Schema | |
402 | ||
403 | } // end namespace KeychainCore | |
404 | ||
405 | } // end namespace Security |