SecKeychainSetSearchList(_:)
Specifies the list of keychains to use in the default keychain search list.
Declaration
func SecKeychainSetSearchList(_ searchList: CFArray) -> OSStatusParameters
- searchList:
An array of keychain references (of type Seckeychain) specifying the list of keychains to use in the default keychain search list. Passing an empty array clears the search list.
Return Value
A result code. See Security Framework Result Codes.
Discussion
The default keychain search list is used by several functions; see for example SecKeychainSearchCreateFromAttributes, SecKeychainFindInternetPassword(_:_:_:_:_:_:_:_:_:_:_:_:_:_:_:), or SecKeychainFindGenericPassword(_:_:_:_:_:_:_:_:). To obtain the current default keychain search list, use the SecKeychainCopySearchList(_:) function.
The default keychain search list is displayed as the keychain list in the Keychain Access utility. If you use SecKeychainSetSearchList(_:) to change the keychain search list, the list displayed in Keychain Access changes accordingly.