IBM 2 Computer Hardware User Manual


 
One_Way_Hash CCA Release 2.54
Parameters
For the definitions of the return_code, reason_code, exit_data_length, and exit_data
parameters, see “Parameters Common to All Verbs” on page 1-11.
rule_array_count
The rule_array_count parameter is a pointer to an integer variable containing
the number of elements in the rule_array variable. The value must be one or
two for this verb.
rule_array
The rule_array parameter is a pointer to a string variable containing an array of
keywords. The keywords are eight bytes in length, and must be left-justified
and padded on the right with space characters. The rule_array keywords are
shown below:
text_length
The text_length parameter is a pointer to an integer variable containing the
number of bytes of data in the text variable. The maximum length on OS/400
systems is 64MB - 64 bytes and on the other systems is 32MB - 64 bytes.
Note: If FIRST or MIDDLE calls are made, the text size must be a multiple of
the algorithm block-size.
text
The text parameter is a pointer to a string variable containing the data on which
the hash value is computed.
chaining_vector_length
The chaining_vector_length parameter is a pointer to an integer variable
containing the number of bytes of data in the chaining_vector variable. The
value must be 128 for this verb.
chaining_vector
The chaining_vector parameter is a pointer to a string variable containing a
work area used by this verb. Application programs must not alter the contents
of this field between related FIRST, MIDDLE, and LAST calls.
Keyword Meaning
Hash method (one required)
MD5 Specifies the use of the MD5 method.
SHA-1 Specifies the use of the SHA-1 method.
RPMD-160 Specifies the use of the RIPEMD-160 method.
Chaining control (one, optional)
FIRST Specifies the first in a series of calls to compute the hash;
intermediate results are stored in the hash variable.
MIDDLE Specifies this is not the first nor the last in a series of calls to
compute the hash; intermediate results are stored in the hash
variable.
LAST Specifies the last in a series of calls to compute the hash;
intermediate results are retrieved from the hash variable.
ONLY Specifies the only call made to compute the hash. This is the
default.
4-14 IBM 4758 CCA Basic Services, Release 2.54, February 2005