Global Variable


A dictionary key whose value is the shared password.


let kSecSharedPassword: CFString


The dictionary returned by the SecRequestSharedWebCredential(_:_:_:) function includes this key to provide you with the password.

You can also access the server’s URL and the user name from this dictionary. To access the server, use the kSecAttrServer constant. To access the user name, use the kSecAttrAccount constant. These constants are part of the Keychain Services API, and in particular are listed among the Item Attribute Keys and Values.

See Also

Password Sharing

func SecAddSharedWebCredential(CFString, CFString, CFString?, (CFError?) -> Void)

Asynchronously stores (or updates) a shared password for a website.

func SecRequestSharedWebCredential(CFString?, CFString?, (CFArray?, CFError?) -> Void)

Asynchronously obtains one or more shared passwords for a website.

func SecCreateSharedWebCredentialPassword() -> CFString?

Returns a randomly generated password.