blob: cf2adbd3c4a98937585271809486fd4ae04bbf9d [file] [log] [blame]
[email protected]32d0ef52009-05-26 20:17:501// Copyright (c) 2009 The Chromium Authors. All rights reserved.
2// Use of this source code is governed by a BSD-style license that can be
3// found in the LICENSE file.
4
5#include "chrome/browser/keychain_mac.h"
6
7OSStatus MacKeychain::ItemCopyAttributesAndData(
8 SecKeychainItemRef itemRef, SecKeychainAttributeInfo *info,
9 SecItemClass *itemClass, SecKeychainAttributeList **attrList,
10 UInt32 *length, void **outData) const {
11 return SecKeychainItemCopyAttributesAndData(itemRef, info, itemClass,
12 attrList, length, outData);
13}
14
15OSStatus MacKeychain::ItemFreeAttributesAndData(
16 SecKeychainAttributeList *attrList, void *data) const {
17 return SecKeychainItemFreeAttributesAndData(attrList, data);
18}
19
20OSStatus MacKeychain::SearchCreateFromAttributes(
21 CFTypeRef keychainOrArray, SecItemClass itemClass,
22 const SecKeychainAttributeList *attrList,
23 SecKeychainSearchRef *searchRef) const {
24 return SecKeychainSearchCreateFromAttributes(keychainOrArray, itemClass,
25 attrList, searchRef);
26}
27
28OSStatus MacKeychain::SearchCopyNext(SecKeychainSearchRef searchRef,
29 SecKeychainItemRef *itemRef) const {
30 return SecKeychainSearchCopyNext(searchRef, itemRef);
31}
32
33void MacKeychain::Free(CFTypeRef ref) const {
34 if (ref) {
35 CFRelease(ref);
36 }
37}