Carbon


Keychain Item Attribute Tag Constants

Header: Keychain.h

Represent tags that identify keychain item attribute values.

enum {
    kClassKCItemAttr = ''clas'',
    kCreationDateKCItemAttr = ''cdat'',
    kModDateKCItemAttr = ''mdat'',
    kDescriptionKCItemAttr = ''desc'',
    kCommentKCItemAttr = ''icmt'',
    kCreatorKCItemAttr = ''crtr'',
    kTypeKCItemAttr = ''type'',
    kScriptCodeKCItemAttr = ''scrp'',
    kLabelKCItemAttr = ''labl'',
    kInvisibleKCItemAttr = ''invi'',
    kNegativeKCItemAttr = ''nega'',
    kCustomIconKCItemAttr = ''cusi'',
    kAccountKCItemAttr = ''acct'',
    kServiceKCItemAttr = ''svce'',
    kGenericKCItemAttr = ''gena'',
    kSecurityDomainKCItemAttr = ''sdmn'',
    kServerKCItemAttr = ''srvr'',
    kAuthTypeKCItemAttr = ''atyp'',
    kPortKCItemAttr = ''port'',
    kPathKCItemAttr = ''path'',
    kVolumeKCItemAttr = ''vlme'',
    kAddressKCItemAttr = ''addr'',
    kSignatureKCItemAttr = ''ssig'',
    kProtocolKCItemAttr = ''ptcl'',
    kSubjectKCItemAttr = ''subj'',
    kCommonNameKCItemAttr = ''cn  '',
    kIssuerKCItemAttr = ''issu'',
    kSerialNumberKCItemAttr = ''snbr'',
    kEMailKCItemAttr = ''mail'',
    kPublicKeyHashKCItemAttr = ''hpky'',
    kIssuerURLKCItemAttr = ''iurl'',
    kEncryptKCItemAttr = ''encr'',
    kDecryptKCItemAttr = ''decr'',
    kSignKCItemAttr = ''sign'',
    kVerifyKCItemAttr = ''veri'',
    kWrapKCItemAttr = ''wrap'',
    kUnwrapKCItemAttr = ''unwr'',
    kStartDateKCItemAttr = ''sdat'',
    kEndDateKCItemAttr = ''edat''
};

Constant descriptions

kClassKCItemAttr

Identifies the class attribute. You use this tag to set or get a value of type KCItemClass that indicates whether the item is an AppleShare, Internet, or generic password, or a certificate. See “Keychain Item Type Constants” for a description of possible values.

kCreationDateKCItemAttr

Identifies the creation date attribute. You use this tag to set or get a value of type UInt32 that indicates the date the item was created.

kModDateKCItemAttr

Identifies the modification date attribute. You use this tag to set or get a value of type UInt32 that indicates the last time the item was updated.

kDescriptionKCItemAttr

Identifies the description attribute. You use this tag to set or get a value of type string that represents a user-visible string describing this item.

kCommentKCItemAttr

Identifies the comment attribute. You use this tag to set or get a value of type string that represents a user-editable string containing comments for this item.

kCreatorKCItemAttr

Identifies the creator attribute. You use this tag to set or get a value of type OSType that represents the item’s creator.

kTypeKCItemAttr

Identifies the type attribute. You use this tag to set or get a value of type OSType that represents the item’s type.

kScriptCodeKCItemAttr

Identifies the script code attribute. You use this tag to set or get a value of type ScriptCode that represents the script code for all strings.

kLabelKCItemAttr

Identifies the label attribute. You use this tag to set or get a value of type string that represents a user-editable string containing the label for this item.

kInvisibleKCItemAttr

Identifies the invisible attribute. You use this tag to set or get a value of type Boolean that indicates whether the item is invisible.

kNegativeKCItemAttr

Identifies the negative attribute. You use this tag to set or get a value of type Boolean that indicates whether there is a valid password associated with this keychain item. This is useful if your application doesn't want a password for some particular service to be stored in the keychain, but prefers that it always be entered by the user. The item (typically invisible and with zero-length data) acts as a placeholder to say “don't use me.”

kCustomIconKCItemAttr

Identifies the custom icon attribute. You use this tag to set or get a value of type Boolean that indicates whether the item has an application-specific icon. To do this, you must also set the attribute value identified by the tag kTypeKCItemAttr to a file type for which there is a corresponding icon in the desktop database, and set the attribute value identified by the tag kCreatorKCItemAttr to an appropriate application creator type. If a custom icon corresponding to the item's type and creator can be found in the desktop database, it will be displayed by Keychain Access. Otherwise, default icons are used.

kAccountKCItemAttr

Identifies the account attribute. You use this tag to set or get a value of type Str63 that represents the user account. It also applies to generic and AppleShare passwords.

kServiceKCItemAttr

Identifies the service attribute. You use this tag to set or get a value of type Str63 that represents the service.

kGenericKCItemAttr

Identifies the generic attribute. You use this tag to set or get a value of untyped bytes that represents a user-defined attribute.

kSecurityDomainKCItemAttr

Identifies the security domain attribute. You use this tag to set or get a value of type Str63 that represents the Internet security domain.

kServerKCItemAttr

Identifies the server attribute. You use this tag to set or get a value of type string that represents the Internet server’s domain name or IP address.

kAuthTypeKCItemAttr

Identifies the authentication type attribute. You use this tag to set or get a value of type KCAuthType that represents the Internet authentication scheme.

kPortKCItemAttr

Identifies the port attribute. You use this tag to set or get a value of type UInt16 that represents the Internet port.

kPathKCItemAttr

Identifies the path attribute. You use this tag to set or get a value of type Str255 that represents the path.

kVolumeKCItemAttr

Identifies the volume attribute. You use this tag to set or get a value of type Str63 that represents the AppleShare volume.

kAddressKCItemAttr

Identifies the address attribute. You use this tag to set or get a value of type string that represents the zone name, or the IP or domain name that represents the server address.

kSignatureKCItemAttr

Identifies the server signature attribute. You use this tag to set or get a value of type AFPServerSignature that represents the server signature block.

kProtocolKCItemAttr

Identifies the protocol attribute. You use this tag to set or get a value of type KCProtocolType that represents the Internet protocol.

kSubjectKCItemAttr

Identifies the subject attribute. You use this tag to set or get DER-encoded data that represents the subject distinguished name.

kCommonNameKCItemAttr

Identifies the common name attribute. You use this tag to set or get a UTF8-encoded string that represents the common name.

kIssuerKCItemAttr

Identifies the issuer attribute. You use this tag to set or get a DER-encoded data that represents the issuer distinguished name.

kSerialNumberKCItemAttr

Identifies the serial number attribute. You use this tag to set or get a DER-encoded data that represents the serial number.

kEMailKCItemAttr

Identifies the email attribute. You use this tag to set or get an ASCII-encoded string that represents the issuer’s email address.

kPublicKeyHashKCItemAttr

Identifies the public key hash attribute. You use this tag to set or get a value of type KCPublicKeyHash that represents the hash of the public key.

kIssuerURLKCItemAttr

Identifies the issuer URL attribute. You use this tag to set or get an ASCII-encoded string that represents the URL of the certificate issuer.

kEncryptKCItemAttr

Identifies the encrypt attribute. You use this tag to set or get a value of type Boolean that indicates whether the item can encrypt.

kDecryptKCItemAttr

Identifies the decrypt attribute. You use this tag to set or get a value of type Boolean that indicates whether the item can decrypt.

kSignKCItemAttr

Identifies the sign attribute. You use this tag to set or get a value of type Boolean that indicates whether the item can sign.

kVerifyKCItemAttr

Identifies the verify attribute. You use this tag to set or get a value of type Boolean that indicates whether the item can verify.

kWrapKCItemAttr

Identifies the wrap attribute. You use this tag to set or get a value of type Boolean that indicates whether the item can wrap.

kUnwrapKCItemAttr

Identifies the unwrap attribute. You use this tag to set or get a value of type Boolean that indicates whether the item can unwrap.

kStartDateKCItemAttr

Identifies the start date attribute. You use this tag to set or get a value of type UInt32 that indicates the start date.

kEndDateKCItemAttr

Identifies the end date attribute. You use this tag to set or get a value of type UInt32 that indicates the end date.

The KCItemAttr enumeration defines the Apple-defined tag constants that identify keychain item attribute values. Your application can use one of these tags in the tag field of the structure KCAttribute to identify the keychain item attribute value you wish to set or retrieve. Your application can create application-defined tags of type KCAttrType.


© 2000 Apple Computer, Inc. (Last Updated 7/17/2000)