AbstractPasswordItem
public class AbstractPasswordItem
This class implements common functionality for Keychain password items. Attributes defined in this class are available for generic and internet passwords.
-
The account used with a given service or on a given web site, for which for which the password is used.
See
kSecAttrAccount
Declaration
Swift
public let account: String?
-
A comment for the item stored in the Keychain. This value is not stored securely and can be read without authorization.
See
kSecAttrComment
Declaration
Swift
public let comment: String?
-
A description or purpose of the Keychain item. In the macOS Keychain Access application the description will be shown in the
Kind
field of items. The default value shown there depends on the itemstype
, e.g.,application password
for generic passwords, orInternet password
for internet passwords.Declaration
Swift
public let description: String?
-
Initializes attributes shared between Keychain password items.
Declaration
Swift
public init(for account: String? = nil, with description: String? = nil, and comment: String? = nil)
Parameters
account
The account for which the password is used.
description
A description or purpose of the item.
comment
A comment.