Key Token Parse2 (CSNBKTP2)

Use the Key Token Parse2 verb to disassemble a variable-length symmetric key-token into separate pieces of information.

The verb can disassemble an external or internal variable-length symmetric key-token in application storage into separate pieces of information. To parse a fixed-length symmetric key-token, see Key Token Parse (CSNBKTP).

The key_token input parameter specifies the external or internal key token to disassemble. The verb returns some of the key-token information in a set of variables identified by individual parameters, and returns the remaining information as keywords in the rule array.

The key-usage field and key-management field information is returned in keywords found in the rule array when the verb can fully parse the fields. If the token cannot be parsed successfully, the verb returns a warning using reason code 2039 (X'7F7'). If a warning or error occurs during processing, the verb updates all of the count and length variables with a value of zero.

The Key Token Parse2 verb performs no cryptographic services.

To use this verb, specify the following:

  • An external or internal variable-length symmetric key-token (version X'05') to be parsed.

    This parameter does not accept a key label. The key token must be provided from application storage. If a key token located in key storage needs to be parsed, use the AES Key Record Read verb to retrieve it into application storage before calling this verb.

    See HMAC key token for the format of this key token. A review of this format information will greatly assist in understanding the output variables of this verb.

  • A rule-array-count value large enough for the verb to return keywords about the input key-token in the rule-array buffer .

    To determine the exact count required, and also the required lengths of the other string variables, specify a value of zero. This causes the verb to return all count and length values without updating any string variables.

  • Adequate buffer sizes for all of the output variables using the length parameters.

This verb does not need to document any Required commands.