|
security
newsgroups
|
|||||||||||||||||||||||
|
|||||||||||||||||||||||
ISO/IEC 9797-1 MAC Algorithm 3 how to?I need to calculate the Cryptographic checksum using ISO/IEC 9797-1 MAC algorithm 3 with block cipher DES, zero IV (8bytes), and ISO 9797-1 padding method 2. The MAC length must be 8 bytes. Any ideas on how to do it? As a sample, the data I am working on now is: Data = '72C29C2371CC9BDB65B779B8E8D37B29ECC154AA56A8799FAE2F498F76ED92F2' Kmac = '7962D9ECE03D1ACD4C76089DCE131543' Resultant MAC[Kmac](Data)='5F1448EEA8AD90A7' (I want to know how to get to this value). Frank,
I don't have 9797 handy, so I'm working from memory here: Padding method is to append single a 1 bit to the end of your message and as many 0 bit as it necessary to get padded message length to be multiple of 64 bit. Kmac shows that you are have two keys; the first key (first 64 bits of Kmac) is used to DES CBC encrypt padded message using IV = {0}; the last cipher block should be encrypted with second key (last 64 bits of Kmac) using DES ECB; and you need to encrypt result of previous encryption with the fist key using DES ECB; (its analogy of using 3DES EEE with two keys on the last block). that should be give you required results. -Valery. http://www.harper.no/valery Show quoteHide quote "Frank Fritze" <frank.fri***@bdr.de> wrote in message news:dfcb9d01.0504130641.6b27b0db@posting.google.com... > Hi, > > > I need to calculate the Cryptographic checksum using ISO/IEC 9797-1 MAC > algorithm 3 with block cipher DES, zero IV (8bytes), and ISO 9797-1 > padding method 2. The MAC length must be 8 bytes. > > > Any ideas on how to do it? > > > As a sample, the data I am working on now is: > Data = > '72C29C2371CC9BDB65B779B8E8D37B29ECC154AA56A8799FAE2F498F76ED92F2' > Kmac = '7962D9ECE03D1ACD4C76089DCE131543' > > > Resultant MAC[Kmac](Data)='5F1448EEA8AD90A7' (I want to know how to get > to this value). And just as a side note:
this question is better fit for microsoft.public.security.crypto group. -Valery. http://www.harper.no/valery Show quoteHide quote "Frank Fritze" <frank.fri***@bdr.de> wrote in message news:dfcb9d01.0504130641.6b27b0db@posting.google.com... > Hi, > > > I need to calculate the Cryptographic checksum using ISO/IEC 9797-1 MAC > algorithm 3 with block cipher DES, zero IV (8bytes), and ISO 9797-1 > padding method 2. The MAC length must be 8 bytes. > > > Any ideas on how to do it? > > > As a sample, the data I am working on now is: > Data = > '72C29C2371CC9BDB65B779B8E8D37B29ECC154AA56A8799FAE2F498F76ED92F2' > Kmac = '7962D9ECE03D1ACD4C76089DCE131543' > > > Resultant MAC[Kmac](Data)='5F1448EEA8AD90A7' (I want to know how to get > to this value).
Show quote
Hide quote
frank.fri***@bdr.de (Frank Fritze) wrote in message news:<dfcb9d01.0504130641.6b27b0db@posting.google.com>... In addition to my question:> Hi, > > > I need to calculate the Cryptographic checksum using ISO/IEC 9797-1 MAC > algorithm 3 with block cipher DES, zero IV (8bytes), and ISO 9797-1 > padding method 2. The MAC length must be 8 bytes. > > > Any ideas on how to do it? > > > As a sample, the data I am working on now is: > Data = > '72C29C2371CC9BDB65B779B8E8D37B29ECC154AA56A8799FAE2F498F76ED92F2' > Kmac = '7962D9ECE03D1ACD4C76089DCE131543' > > > Resultant MAC[Kmac](Data)='5F1448EEA8AD90A7' (I want to know how to get > to this value). I've already tried to calculate it over MACTripledes ... but with no success.. And I'm sure, it can be done with .NET, isn't it ? Regards Frank Did you see my post where I answered you how to do it? It could be done with
..Net if you simply follow my perscription. and right - MACTripleDES is a different thing. -Valery. http://www.harper.no/valery Show quoteHide quote "Frank Fritze" <frank.fri***@bdr.de> wrote in message news:dfcb9d01.0504131241.1cf7e340@posting.google.com... > frank.fri***@bdr.de (Frank Fritze) wrote in message > news:<dfcb9d01.0504130641.6b27b0db@posting.google.com>... >> Hi, >> >> >> I need to calculate the Cryptographic checksum using ISO/IEC 9797-1 MAC >> algorithm 3 with block cipher DES, zero IV (8bytes), and ISO 9797-1 >> padding method 2. The MAC length must be 8 bytes. >> >> >> Any ideas on how to do it? >> >> >> As a sample, the data I am working on now is: >> Data = >> '72C29C2371CC9BDB65B779B8E8D37B29ECC154AA56A8799FAE2F498F76ED92F2' >> Kmac = '7962D9ECE03D1ACD4C76089DCE131543' >> >> >> Resultant MAC[Kmac](Data)='5F1448EEA8AD90A7' (I want to know how to get >> to this value). > > > In addition to my question: > > I've already tried to calculate it over MACTripledes ... but with no > success.. > And I'm sure, it can be done with .NET, isn't it ? > > Regards > > Frank
Running a program with elevated priveleges
Cannot open log for source {0}. You may not have write access. (Access right wanish after a while) local admin security question AzMan threading problems Rijndael decryption succeeds SOMETIMES Getting user ID from Web Service credentials Access to the path is denied: Assembly Permission Problem Parsing X.509 Digital Certificate newbie question RSACryptoServiceProvider usage question Help How to add publisher condition ?? |
|||||||||||||||||||||||