How to get the last 32 bits in ANSI X9.19 MAC generation ( very urgent )
843811Jun 22 2007 — edited Jun 25 2007I am trying to generate the MAC of 256bits of data according to ANSI X9.19 standard.
I am trying to do this in the following way
1) Encrypt the whole 256 bits using DES in CBC mode ( blocksize=64bits and hence 4 blocks)
2) Taking the last 8 bytes (i.e., last 64bits) I am decrypting it with DES in ECB mode using another key
3)Taking the ciphertext from above step, i am encrypting the ciphertext using DES ECB mode with key used in step1
Is the above steps are correct according to ANSI X9.19 MAC standard.
If so how to generate the final 32 bits from the 64 bits of the final block according to the X9.19 standard.