IBM Computer Hardware 2 User Manual Page 444

  • Download
  • Add to my manuals
  • Print
  • Page
    / 508
  • Table of contents
  • BOOKMARKS
  • Rated. / 5. Based on customer reviews
Page view 443
CCA Release 2.54
When the keywords PADMDC-2 and PADMDC-4 are used, the supplied text is
always padded as follows:
If the supplied text is less than 16 bytes in length, pad bytes are appended to
make the text length equal to 16 bytes.
If the supplied text is at least 16 bytes in length, pad bytes are appended to
make the text length equal to the next-higher multiple of eight bytes, pad bytes
are always added.
All appended pad bytes, other than the last pad byte, are set to X'FF'.
The last pad byte is set to a binary value equal to the count of all appended
pad bytes (X'01' to X'10').
Use the resulting pad text in the following procedures. The MDC_Generate verb
uses these MDC calculation methods. See page 4-10 for more information about
the MDC_Generate verb.
Notation Used in Calculations
The MDC calculations use the following notations:
eK(X) Denotes DES encryption of plaintext X using key K
|| Denotes the concatenation operation
XOR Denotes the exclusive-OR operation
:= Denotes the assignment operation
T8<1> Denotes the first eight-byte block of text
T8<2> Denotes the second eight-byte block of text, and so on
KD1, KD2, IN1, IN2, OUT1, OUT2
Denote 64-bit quantities
MDC-1 Calculation
The MDC-1 calculation, which is used in the MDC-2 and MDC-4 calculations,
consists of the following procedure:
MDC-1 (KD1, KD2, IN1, IN2, OUT1, OUT2);
Set KD1mod := set bit 1 and bit 2 of KD1 to "1" and "" respectively.
Set KD2mod := set bit 1 and bit 2 of KD2 to "" and "1" respectively.
Set F1 := IN1 XOR eKD1mod(IN1)
Set F2 := IN2 XOR eKD2mod(IN2)
Set OUT1 := (bits ..31 of F1) || (bits 32..63 of F2)
Set OUT2 := (bits ..31 of F2) || (bits 32..63 of F1)
End procedure
D-4 IBM 4758 CCA Basic Services, Release 2.54, February 2005
Page view 443
1 2 ... 439 440 441 442 443 444 445 446 447 448 449 ... 507 508

Comments to this Manuals

No comments