diff options
author | lloyd <[email protected]> | 2010-10-13 02:56:03 +0000 |
---|---|---|
committer | lloyd <[email protected]> | 2010-10-13 02:56:03 +0000 |
commit | 3697dcff8b5e9765b41114281ce10e7ed3d3abb4 (patch) | |
tree | 670853a74b0fe173e7e9fce9cd3e6eda7a03d2c7 /src/mac | |
parent | 63121e1e169616f724bf79b8aac1a2b4423c8904 (diff) |
s/BLOCK_SIZE/block_size()/
Diffstat (limited to 'src/mac')
-rw-r--r-- | src/mac/cbc_mac/cbc_mac.cpp | 4 | ||||
-rw-r--r-- | src/mac/cmac/cmac.cpp | 6 | ||||
-rw-r--r-- | src/mac/x919_mac/x919_mac.cpp | 4 |
3 files changed, 7 insertions, 7 deletions
diff --git a/src/mac/cbc_mac/cbc_mac.cpp b/src/mac/cbc_mac/cbc_mac.cpp index 3eaa115b8..48cc8ab3e 100644 --- a/src/mac/cbc_mac/cbc_mac.cpp +++ b/src/mac/cbc_mac/cbc_mac.cpp @@ -89,11 +89,11 @@ MessageAuthenticationCode* CBC_MAC::clone() const * CBC-MAC Constructor */ CBC_MAC::CBC_MAC(BlockCipher* e_in) : - MessageAuthenticationCode(e_in->BLOCK_SIZE, + MessageAuthenticationCode(e_in->block_size(), e_in->MINIMUM_KEYLENGTH, e_in->MAXIMUM_KEYLENGTH, e_in->KEYLENGTH_MULTIPLE), - e(e_in), state(e->BLOCK_SIZE) + e(e_in), state(e->block_size()) { position = 0; } diff --git a/src/mac/cmac/cmac.cpp b/src/mac/cmac/cmac.cpp index a4a9394ae..2147f9a45 100644 --- a/src/mac/cmac/cmac.cpp +++ b/src/mac/cmac/cmac.cpp @@ -131,15 +131,15 @@ MessageAuthenticationCode* CMAC::clone() const * CMAC Constructor */ CMAC::CMAC(BlockCipher* e_in) : - MessageAuthenticationCode(e_in->BLOCK_SIZE, + MessageAuthenticationCode(e_in->block_size(), e_in->MINIMUM_KEYLENGTH, e_in->MAXIMUM_KEYLENGTH, e_in->KEYLENGTH_MULTIPLE), e(e_in) { - if(e->BLOCK_SIZE == 16) + if(e->block_size() == 16) polynomial = 0x87; - else if(e->BLOCK_SIZE == 8) + else if(e->block_size() == 8) polynomial = 0x1B; else throw Invalid_Argument("CMAC cannot use the cipher " + e->name()); diff --git a/src/mac/x919_mac/x919_mac.cpp b/src/mac/x919_mac/x919_mac.cpp index 330ca0043..c46ab82cb 100644 --- a/src/mac/x919_mac/x919_mac.cpp +++ b/src/mac/x919_mac/x919_mac.cpp @@ -85,11 +85,11 @@ MessageAuthenticationCode* ANSI_X919_MAC::clone() const * ANSI X9.19 MAC Constructor */ ANSI_X919_MAC::ANSI_X919_MAC(BlockCipher* e_in) : - MessageAuthenticationCode(e_in->BLOCK_SIZE, + MessageAuthenticationCode(e_in->block_size(), e_in->MINIMUM_KEYLENGTH, 2*e_in->MAXIMUM_KEYLENGTH, 2*e_in->KEYLENGTH_MULTIPLE), - e(e_in), d(e->clone()), state(e->BLOCK_SIZE), position(0) + e(e_in), d(e->clone()), state(e->block_size()), position(0) { if(e->name() != "DES") throw Invalid_Argument("ANSI X9.19 MAC only supports DES"); |