diff options
author | Dmitry Eremin-Solenikov <dbaryshkov@gmail.com> | 2014-06-06 22:48:32 +0400 |
---|---|---|
committer | Werner Koch <wk@gnupg.org> | 2014-06-28 10:44:37 +0200 |
commit | 25d6af77e2336b5979ddbe8b90978fe5b61dfaf9 (patch) | |
tree | a7872fa22efbd8f41b27e0bd8fc52d0c26098fe1 /src/gcrypt.h.in | |
parent | 5ee35a04362c94e680ef3633fa83b72e0aee8626 (diff) | |
download | libgcrypt-25d6af77e2336b5979ddbe8b90978fe5b61dfaf9.tar.gz |
Add GOST R 34.11-94 variant using id-GostR3411-94-CryptoProParamSet
* src/gcrypt.h.in (GCRY_MD_GOSTR3411_CP): New.
* src/cipher.h (_gcry_digest_spec_gost3411_cp): New.
* cipher/gost28147.c (_gcry_gost_enc_one): Differentiate between
CryptoPro and Test S-Boxes.
* cipher/gostr3411-94.c (_gcry_digest_spec_gost3411_cp,
gost3411_cp_init): New.
* cipher/md.c (md_open): GCRY_MD_GOSTR3411_CP also uses B=32.
--
RFC4357 defines only two S-Boxes that should be used together with
GOST R 34.11-94 - a testing one (from standard itself, for testing only)
and CryptoPro one. Instead of adding a separate gcry_md_ctrl() function
just to switch s-boxes, add a separate MD algorithm using CryptoPro
S-box.
Signed-off-by: Dmitry Eremin-Solenikov <dbaryshkov@gmail.com>
Diffstat (limited to 'src/gcrypt.h.in')
-rw-r--r-- | src/gcrypt.h.in | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/gcrypt.h.in b/src/gcrypt.h.in index 95d324b5..a5f8350a 100644 --- a/src/gcrypt.h.in +++ b/src/gcrypt.h.in @@ -1152,7 +1152,8 @@ enum gcry_md_algos GCRY_MD_TIGER2 = 307, /* TIGER2 variant. */ GCRY_MD_GOSTR3411_94 = 308, /* GOST R 34.11-94. */ GCRY_MD_STRIBOG256 = 309, /* GOST R 34.11-2012, 256 bit. */ - GCRY_MD_STRIBOG512 = 310 /* GOST R 34.11-2012, 512 bit. */ + GCRY_MD_STRIBOG512 = 310, /* GOST R 34.11-2012, 512 bit. */ + GCRY_MD_GOSTR3411_CP = 311 /* GOST R 34.11-94 with CryptoPro-A S-Box. */ }; /* Flags used with the open function. */ |