({{, (RefLink[DerivedKey, paclet:ref/DerivedKey])[assoc] 
represents a derived key generated by (RefLink[GenerateDerivedKey, paclet:ref/GenerateDerivedKey]).}})

OpenersNotesSection(Spacer1)Details

(RefLink[DerivedKey, paclet:ref/DerivedKey]) is an object containing a secure key, which can be used in place of a plain-text password.

(RefLink[DerivedKey, paclet:ref/DerivedKey]) contains all the information necessary to verify the password used to generate the key.

In (RefLink[DerivedKey, paclet:ref/DerivedKey])[assoc], the association assoc contains the following:

The value of "Parameters" is an (RefLink[Association, paclet:ref/Association]) that contains "KeySize" and parameters specific to the key derivation function used.

(RefLink[DerivedKey, paclet:ref/DerivedKey])[assoc]["prop"] gives the specified element of assoc; it is equivalent to assoc["prop"].

(RefLink[DerivedKey, paclet:ref/DerivedKey])[assoc]["PHCString"] gives a string representation of the derived key.

OpenersPrimaryExamplesSection(Spacer1)Examples  (7)

OpenersExampleSection0(Spacer1)Basic Examples  (7)

Generate a derived key:

GenerateDerivedKey["password"]

Extract the derived sequence of bytes:

GenerateDerivedKey["password"]["DerivedKey"]

Extract the name of the key derivation function used:

GenerateDerivedKey["password"]["Function"]

Extract key derivation function parameters:

GenerateDerivedKey["password"]["Parameters"]

Obtain derived key as a hex string:

key=GenerateDerivedKey["password"]
key["PHCString"]

Verify password using (RefLink[DerivedKey, paclet:ref/DerivedKey]):

key=GenerateDerivedKey["Apple"]

VerifyDerivedKey[key,"Apple"]

VerifyDerivedKey[key,"Orange"]

Verify password using hex string representation of (RefLink[DerivedKey, paclet:ref/DerivedKey]):

key=GenerateDerivedKey["Apple"]["PHCString"]

VerifyDerivedKey[key,"Apple"]

({{DocumentationFooterIconsRelatedFunction.png, ({{See Also}, {(RefLink[GenerateDerivedKey, paclet:ref/GenerateDerivedKey])  ▪  (RefLink[VerifyDerivedKey, paclet:ref/VerifyDerivedKey])  ▪  (RefLink[GenerateSymmetricKey, paclet:ref/GenerateSymmetricKey])  ▪  (RefLink[Hash, paclet:ref/Hash])}})}})

({{DocumentationFooterIconsRelatedGuide.png, ({{Related Guides}, {▪(RefLinkPlain[Cryptography, paclet:guide/Cryptography])}})}})