...
 
Commits (7)
2019-09-15 Niels Möller <nisse@lysator.liu.se>
From Dmitry Eremin-Solenikov:
* gost28147.c (_gost28147_encrypt_block): New file, encrypt
function and sbox tables moved here.
* gosthash94.c: Update functions to take sbox array as argument.
(gost_block_compress): Use _gost28147_encrypt_block.
(gosthash94cp_update,gosthash94cp_digest): New functions.
* gost28147-internal.h: New file.
* gost28147.h: New file.
* gosthash94-meta.c (nettle_gosthash94cp): New hash algorithm.
* nettle-meta-hashes.c (_nettle_hashes): Add nettle_gosthash94 and
nettle_gosthash94cp.
* hmac-gosthash94.c (hmac_gosthash94_set_key)
(hmac_gosthash94_update, hmac_gosthash94_digest)
(hmac_gosthash94cp_set_key, hmac_gosthash94cp_update)
(hmac_gosthash94cp_digest): New file and functions.
* pbkdf2-hmac-gosthash94.c (pbkdf2_hmac_gosthash94cp): New file
and function.
* testsuite/pbkdf2-test.c (test_main): Add
pbkdf2-hmac-gosthash94cp tests.
* testsuite/hmac-test.c (test_main): Add hmac-gosthash94 tests.
* testsuite/gosthash94-test.c (test_main): Add gosthash94cp tests.
* nettle.texinfo (Legacy hash functions): Document gosthash94cp.
* testsuite/dlopen-test.c (main): Use libnettle.dylib on MacOS.
2019-07-08 Niels Möller <nisse@lysator.liu.se>
......
......@@ -103,9 +103,10 @@ nettle_SOURCES = aes-decrypt-internal.c aes-decrypt.c \
gcm-camellia128.c gcm-camellia128-meta.c \
gcm-camellia256.c gcm-camellia256-meta.c \
cmac.c cmac64.c cmac-aes128.c cmac-aes256.c cmac-des3.c \
gosthash94.c gosthash94-meta.c \
hmac.c hmac-md5.c hmac-ripemd160.c hmac-sha1.c \
hmac-sha224.c hmac-sha256.c hmac-sha384.c hmac-sha512.c \
gost28147.c gosthash94.c gosthash94-meta.c \
hmac.c hmac-gosthash94.c hmac-md5.c hmac-ripemd160.c \
hmac-sha1.c hmac-sha224.c hmac-sha256.c hmac-sha384.c \
hmac-sha512.c \
knuth-lfib.c hkdf.c \
md2.c md2-meta.c md4.c md4-meta.c \
md5.c md5-compress.c md5-compat.c md5-meta.c \
......@@ -113,7 +114,8 @@ nettle_SOURCES = aes-decrypt-internal.c aes-decrypt.c \
nettle-lookup-hash.c \
nettle-meta-aeads.c nettle-meta-armors.c \
nettle-meta-ciphers.c nettle-meta-hashes.c \
pbkdf2.c pbkdf2-hmac-sha1.c pbkdf2-hmac-sha256.c \
pbkdf2.c pbkdf2-hmac-gosthash94.c pbkdf2-hmac-sha1.c \
pbkdf2-hmac-sha256.c \
poly1305-aes.c poly1305-internal.c \
realloc.c \
ripemd160.c ripemd160-compress.c ripemd160-meta.c \
......@@ -196,7 +198,7 @@ HEADERS = aes.h arcfour.h arctwo.h asn1.h blowfish.h \
cbc.h ccm.h cfb.h chacha.h chacha-poly1305.h ctr.h \
curve25519.h des.h dsa.h dsa-compat.h eax.h \
ecc-curve.h ecc.h ecdsa.h eddsa.h \
gcm.h gosthash94.h hmac.h \
gcm.h gost28147.h gosthash94.h hmac.h \
knuth-lfib.h hkdf.h \
macros.h \
cmac.h siv-cmac.h \
......@@ -230,8 +232,8 @@ DISTFILES = $(SOURCES) $(HEADERS) getopt.h getopt_int.h \
INSTALL NEWS ChangeLog \
nettle.pc.in hogweed.pc.in \
$(des_headers) descore.README desdata.stamp \
aes-internal.h block-internal.h \
camellia-internal.h serpent-internal.h \
aes-internal.h block-internal.h camellia-internal.h \
gost28147-internal.h serpent-internal.h \
cast128_sboxes.h desinfo.h desCode.h \
ripemd160-internal.h sha2-internal.h \
memxor-internal.h nettle-internal.h nettle-write.h \
......
......@@ -918,6 +918,7 @@ main(int argc, char **argv)
&nettle_sha3_224, &nettle_sha3_256,
&nettle_sha3_384, &nettle_sha3_512,
&nettle_ripemd160, &nettle_gosthash94,
&nettle_gosthash94cp,
NULL
};
......
/* gost28147-internal.h
The GOST 28147-89 cipher function, described in RFC 5831.
Copyright (C) 2019 Dmitry Eremin-Solenikov
This file is part of GNU Nettle.
GNU Nettle is free software: you can redistribute it and/or
modify it under the terms of either:
* the GNU Lesser General Public License as published by the Free
Software Foundation; either version 3 of the License, or (at your
option) any later version.
or
* the GNU General Public License as published by the Free
Software Foundation; either version 2 of the License, or (at your
option) any later version.
or both in parallel, as here.
GNU Nettle is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
General Public License for more details.
You should have received copies of the GNU General Public License and
the GNU Lesser General Public License along with this program. If
not, see http://www.gnu.org/licenses/.
*/
#ifndef NETTLE_GOST28147_INTERNAL_H_INCLUDED
#define NETTLE_GOST28147_INTERNAL_H_INCLUDED
#define _gost28147_encrypt_block _nettle_gost28147_encrypt_block
void _gost28147_encrypt_block (const uint32_t *key, const uint32_t sbox[4][256],
const uint32_t *in, uint32_t *out);
#endif /* NETTLE_GOST28147_INTERNAL_H_INCLUDED */
This diff is collapsed.
/* gost28147.h
The GOST 28147-89 cipher function, described in RFC 5831.
Copyright (C) 2019 Dmitry Eremin-Solenikov
This file is part of GNU Nettle.
GNU Nettle is free software: you can redistribute it and/or
modify it under the terms of either:
* the GNU Lesser General Public License as published by the Free
Software Foundation; either version 3 of the License, or (at your
option) any later version.
or
* the GNU General Public License as published by the Free
Software Foundation; either version 2 of the License, or (at your
option) any later version.
or both in parallel, as here.
GNU Nettle is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
General Public License for more details.
You should have received copies of the GNU General Public License and
the GNU Lesser General Public License along with this program. If
not, see http://www.gnu.org/licenses/.
*/
#ifndef NETTLE_GOST28147_H_INCLUDED
#define NETTLE_GOST28147_H_INCLUDED
#include "nettle-types.h"
#ifdef __cplusplus
extern "C" {
#endif
#define gost28147_param_test_3411 nettle_gost28147_param_test_3411
#define gost28147_param_CryptoPro_3411 nettle_gost28147_param_CryptoPro_3411
struct gost28147_param
{
uint32_t sbox[4][256];
};
extern const struct gost28147_param gost28147_param_test_3411;
extern const struct gost28147_param gost28147_param_CryptoPro_3411;
#ifdef __cplusplus
}
#endif
#endif /* NETTLE_GOST28147_H_INCLUDED */
......@@ -39,3 +39,6 @@
const struct nettle_hash nettle_gosthash94
= _NETTLE_HASH(gosthash94, GOSTHASH94);
const struct nettle_hash nettle_gosthash94cp
= _NETTLE_HASH(gosthash94cp, GOSTHASH94CP);
This diff is collapsed.
......@@ -72,11 +72,19 @@ extern "C" {
#define gosthash94_update nettle_gosthash94_update
#define gosthash94_digest nettle_gosthash94_digest
#define gosthash94cp_update nettle_gosthash94cp_update
#define gosthash94cp_digest nettle_gosthash94cp_digest
#define GOSTHASH94_BLOCK_SIZE 32
#define GOSTHASH94_DIGEST_SIZE 32
/* For backwards compatibility */
#define GOSTHASH94_DATA_SIZE GOSTHASH94_BLOCK_SIZE
#define GOSTHASH94CP_BLOCK_SIZE GOSTHASH94_BLOCK_SIZE
#define GOSTHASH94CP_DIGEST_SIZE GOSTHASH94_DIGEST_SIZE
/* FIXME: Rearrange context struct to enable use of the MD_UPDATE
macro. Has to wait for an ABI update. */
struct gosthash94_ctx
{
uint32_t hash[8]; /* algorithm 256-bit state */
......@@ -84,6 +92,7 @@ struct gosthash94_ctx
uint64_t length; /* number of processed bytes */
uint8_t message[GOSTHASH94_BLOCK_SIZE]; /* 256-bit buffer for leftovers */
};
#define gosthash94cp_ctx gosthash94_ctx
void gosthash94_init(struct gosthash94_ctx *ctx);
void gosthash94_update(struct gosthash94_ctx *ctx,
......@@ -91,6 +100,12 @@ void gosthash94_update(struct gosthash94_ctx *ctx,
void gosthash94_digest(struct gosthash94_ctx *ctx,
size_t length, uint8_t *result);
#define gosthash94cp_init gosthash94_init
void gosthash94cp_update(struct gosthash94_ctx *ctx,
size_t length, const uint8_t *msg);
void gosthash94cp_digest(struct gosthash94_ctx *ctx,
size_t length, uint8_t *result);
#ifdef __cplusplus
}
#endif
......
/* hmac-gosthash94.c
HMAC-GOSTHASH94 message authentication code.
Copyright (C) 2016 Dmitry Eremin-Solenikov
This file is part of GNU Nettle.
GNU Nettle is free software: you can redistribute it and/or
modify it under the terms of either:
* the GNU Lesser General Public License as published by the Free
Software Foundation; either version 3 of the License, or (at your
option) any later version.
or
* the GNU General Public License as published by the Free
Software Foundation; either version 2 of the License, or (at your
option) any later version.
or both in parallel, as here.
GNU Nettle is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
General Public License for more details.
You should have received copies of the GNU General Public License and
the GNU Lesser General Public License along with this program. If
not, see http://www.gnu.org/licenses/.
*/
#if HAVE_CONFIG_H
# include "config.h"
#endif
#include "hmac.h"
void
hmac_gosthash94_set_key(struct hmac_gosthash94_ctx *ctx,
size_t key_length, const uint8_t *key)
{
HMAC_SET_KEY(ctx, &nettle_gosthash94, key_length, key);
}
void
hmac_gosthash94_update(struct hmac_gosthash94_ctx *ctx,
size_t length, const uint8_t *data)
{
gosthash94_update(&ctx->state, length, data);
}
void
hmac_gosthash94_digest(struct hmac_gosthash94_ctx *ctx,
size_t length, uint8_t *digest)
{
HMAC_DIGEST(ctx, &nettle_gosthash94, length, digest);
}
void
hmac_gosthash94cp_set_key(struct hmac_gosthash94cp_ctx *ctx,
size_t key_length, const uint8_t *key)
{
HMAC_SET_KEY(ctx, &nettle_gosthash94cp, key_length, key);
}
void
hmac_gosthash94cp_update(struct hmac_gosthash94cp_ctx *ctx,
size_t length, const uint8_t *data)
{
gosthash94cp_update(&ctx->state, length, data);
}
void
hmac_gosthash94cp_digest(struct hmac_gosthash94cp_ctx *ctx,
size_t length, uint8_t *digest)
{
HMAC_DIGEST(ctx, &nettle_gosthash94cp, length, digest);
}
......@@ -36,6 +36,7 @@
#include "nettle-meta.h"
#include "gosthash94.h"
#include "md5.h"
#include "ripemd160.h"
#include "sha1.h"
......@@ -68,6 +69,12 @@ extern "C" {
#define hmac_sha512_set_key nettle_hmac_sha512_set_key
#define hmac_sha512_update nettle_hmac_sha512_update
#define hmac_sha512_digest nettle_hmac_sha512_digest
#define hmac_gosthash94_set_key nettle_hmac_gosthash94_set_key
#define hmac_gosthash94_update nettle_hmac_gosthash94_update
#define hmac_gosthash94_digest nettle_hmac_gosthash94_digest
#define hmac_gosthash94cp_set_key nettle_hmac_gosthash94cp_set_key
#define hmac_gosthash94cp_update nettle_hmac_gosthash94cp_update
#define hmac_gosthash94cp_digest nettle_hmac_gosthash94cp_digest
void
hmac_set_key(void *outer, void *inner, void *state,
......@@ -203,6 +210,36 @@ void
hmac_sha384_digest(struct hmac_sha512_ctx *ctx,
size_t length, uint8_t *digest);
/* hmac-gosthash94 */
struct hmac_gosthash94_ctx HMAC_CTX(struct gosthash94_ctx);
void
hmac_gosthash94_set_key(struct hmac_gosthash94_ctx *ctx,
size_t key_length, const uint8_t *key);
void
hmac_gosthash94_update(struct hmac_gosthash94_ctx *ctx,
size_t length, const uint8_t *data);
void
hmac_gosthash94_digest(struct hmac_gosthash94_ctx *ctx,
size_t length, uint8_t *digest);
struct hmac_gosthash94cp_ctx HMAC_CTX(struct gosthash94cp_ctx);
void
hmac_gosthash94cp_set_key(struct hmac_gosthash94cp_ctx *ctx,
size_t key_length, const uint8_t *key);
void
hmac_gosthash94cp_update(struct hmac_gosthash94cp_ctx *ctx,
size_t length, const uint8_t *data);
void
hmac_gosthash94cp_digest(struct hmac_gosthash94cp_ctx *ctx,
size_t length, uint8_t *digest);
#ifdef __cplusplus
}
#endif
......
......@@ -38,6 +38,8 @@
#include "nettle-meta.h"
const struct nettle_hash * const _nettle_hashes[] = {
&nettle_gosthash94,
&nettle_gosthash94cp,
&nettle_md2,
&nettle_md4,
&nettle_md5,
......
......@@ -130,6 +130,7 @@ extern const struct nettle_hash nettle_md2;
extern const struct nettle_hash nettle_md4;
extern const struct nettle_hash nettle_md5;
extern const struct nettle_hash nettle_gosthash94;
extern const struct nettle_hash nettle_gosthash94cp;
extern const struct nettle_hash nettle_ripemd160;
extern const struct nettle_hash nettle_sha1;
extern const struct nettle_hash nettle_sha224;
......
......@@ -1039,12 +1039,17 @@ This function also resets the context in the same way as
@end deftypefun
@subsubsection @acronym{GOSTHASH94}
@subsubsection @acronym{GOSTHASH94 and GOSTHASH94CP}
The GOST94 or GOST R 34.11-94 hash algorithm is a Soviet-era algorithm
used in Russian government standards (see @cite{RFC 4357}).
It outputs message digests of 256 bits, or 32 octets.
Nettle defines GOSTHASH94 in @file{<nettle/gosthash94.h>}.
It outputs message digests of 256 bits, or 32 octets. The standard itself
does not fix the S-box used by the hash algorith, so there are two popular
variants (the testing S-box from the standard itself and the S-box defined
by CryptoPro company, see RFC 4357). Nettle provides support for the former
S-box in the form of GOSTHASH94 hash algorithm and for the latter in the
form of GOSTHASH94CP hash algorithm.
Nettle defines GOSTHASH94 and GOSTHASH94CP in @file{<nettle/gosthash94.h>}.
@deftp {Context struct} {struct gosthash94_ctx}
@end deftp
......@@ -1075,6 +1080,35 @@ This function also resets the context in the same way as
@code{gosthash94_init}.
@end deftypefun
@deftp {Context struct} {struct gosthash94cp_ctx}
@end deftp
@defvr Constant GOSTHASH94CP_DIGEST_SIZE
The size of a GOSTHASH94CP digest, i.e. 32.
@end defvr
@defvr Constant GOSTHASH94CP_BLOCK_SIZE
The internal block size of GOSTHASH94CP, i.e., 32.
@end defvr
@deftypefun void gosthash94cp_init (struct gosthash94cp_ctx *@var{ctx})
Initialize the GOSTHASH94CP state.
@end deftypefun
@deftypefun void gosthash94cp_update (struct gosthash94cp_ctx *@var{ctx}, size_t @var{length}, const uint8_t *@var{data})
Hash some more data.
@end deftypefun
@deftypefun void gosthash94cp_digest (struct gosthash94cp_ctx *@var{ctx}, size_t @var{length}, uint8_t *@var{digest})
Performs final processing and extracts the message digest, writing it
to @var{digest}. @var{length} may be smaller than
@code{GOSTHASH94CP_DIGEST_SIZE}, in which case only the first @var{length}
octets of the digest are written.
This function also resets the context in the same way as
@code{gosthash94cp_init}.
@end deftypefun
@node nettle_hash abstraction,, Legacy hash functions, Hash functions
@comment node-name, next, previous, up
@subsection The @code{struct nettle_hash} abstraction
......@@ -1104,6 +1138,7 @@ The last three attributes are function pointers, of types
@deftypevrx {Constant Struct} {struct nettle_hash} nettle_sha512
@deftypevrx {Constant Struct} {struct nettle_hash} nettle_sha3_256
@deftypevrx {Constant Struct} {struct nettle_hash} nettle_gosthash94
@deftypevrx {Constant Struct} {struct nettle_hash} nettle_gosthash94cp
These are all the hash functions that Nettle implements.
@end deftypevr
......
/* pbkdf2-hmac-gosthash94.c
PKCS #5 PBKDF2 used with HMAC-GOSTHASH94CP.
Copyright (C) 2016 Dmitry Eremin-Solenikov
This file is part of GNU Nettle.
GNU Nettle is free software: you can redistribute it and/or
modify it under the terms of either:
* the GNU Lesser General Public License as published by the Free
Software Foundation; either version 3 of the License, or (at your
option) any later version.
or
* the GNU General Public License as published by the Free
Software Foundation; either version 2 of the License, or (at your
option) any later version.
or both in parallel, as here.
GNU Nettle is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
General Public License for more details.
You should have received copies of the GNU General Public License and
the GNU Lesser General Public License along with this program. If
not, see http://www.gnu.org/licenses/.
*/
#if HAVE_CONFIG_H
# include "config.h"
#endif
#include "pbkdf2.h"
#include "hmac.h"
void
pbkdf2_hmac_gosthash94cp (size_t key_length, const uint8_t *key,
unsigned iterations,
size_t salt_length, const uint8_t *salt,
size_t length, uint8_t *dst)
{
struct hmac_gosthash94cp_ctx gosthash94cpctx;
hmac_gosthash94cp_set_key (&gosthash94cpctx, key_length, key);
PBKDF2 (&gosthash94cpctx, hmac_gosthash94cp_update, hmac_gosthash94cp_digest,
GOSTHASH94CP_DIGEST_SIZE, iterations, salt_length, salt, length, dst);
}
......@@ -45,6 +45,7 @@ extern "C"
#define pbkdf2 nettle_pbkdf2
#define pbkdf2_hmac_sha1 nettle_pbkdf2_hmac_sha1
#define pbkdf2_hmac_sha256 nettle_pbkdf2_hmac_sha256
#define pbkdf2_hmac_gosthash94cp nettle_pbkdf2_hmac_gosthash94cp
void
pbkdf2 (void *mac_ctx,
......@@ -78,6 +79,12 @@ pbkdf2_hmac_sha256 (size_t key_length, const uint8_t *key,
size_t salt_length, const uint8_t *salt,
size_t length, uint8_t *dst);
void
pbkdf2_hmac_gosthash94cp (size_t key_length, const uint8_t *key,
unsigned iterations,
size_t salt_length, const uint8_t *salt,
size_t length, uint8_t *dst);
#ifdef __cplusplus
}
#endif
......
......@@ -17,4 +17,16 @@ test_main(void)
test_hash(&nettle_gosthash94, SDATA(""),
SHEX("ce85b99cc46752fffee35cab9a7b0278abb4c2d2055cff685af4912c49490f8d"));
test_hash(&nettle_gosthash94cp, SDATA("The quick brown fox jumps over the lazy dog"),
SHEX("9004294a361a508c586fe53d1f1b02746765e71b765472786e4770d565830a76"));
test_hash(&nettle_gosthash94cp, SDATA("message digest"),
SHEX("bc6041dd2aa401ebfa6e9886734174febdb4729aa972d60f549ac39b29721ba0"));
test_hash(&nettle_gosthash94cp, SDATA("a"),
SHEX("e74c52dd282183bf37af0079c9f78055715a103f17e3133ceff1aacf2f403011"));
test_hash(&nettle_gosthash94cp, SDATA(""),
SHEX("981e5f3ca30c841487830f84fb433e13ac1101569b9c13584ac483234cd656c0"));
}
......@@ -894,4 +894,18 @@ test_main(void)
"b1ff68a1de45509fbe4da9a433922655"));
/* Test case AUTH512-3 from same document seems broken. */
HMAC_TEST(gosthash94,
SHEX("000102030405060708090a0b0c0d0e0f"
"101112131415161718191a1b1c1d1e1f"),
SHEX("0126bdb87800af214341456563780100"),
SHEX("bfebe25f051bfef6ac858babb0abc409"
"bfd2e334ab847bc0b0d056517c7d94c5"));
HMAC_TEST(gosthash94cp,
SHEX("000102030405060708090a0b0c0d0e0f"
"101112131415161718191a1b1c1d1e1f"),
SHEX("0126bdb87800af214341456563780100"),
SHEX("bad70b61c41095bc47e1141cfaed4272"
"6a5ceebd62ce75dbbb9ad76cda9f72f7"));
}
......@@ -5,6 +5,8 @@
#include "sha3.h"
const char* hashes[] = {
"gosthash94",
"gosthash94cp",
"md2",
"md4",
"md5",
......
......@@ -28,6 +28,7 @@ test_main (void)
struct hmac_sha1_ctx sha1ctx;
struct hmac_sha256_ctx sha256ctx;
struct hmac_sha512_ctx sha512ctx;
struct hmac_gosthash94cp_ctx gosthash94cpctx;
/* Test vectors for PBKDF2 from RFC 6070. */
......@@ -110,4 +111,27 @@ test_main (void)
PBKDF2_HMAC_TEST(pbkdf2_hmac_sha256, LDATA("passwd"), 1, LDATA("salt"),
SHEX("55ac046e56e3089fec1691c22544b605"));
/* From TC26 document, MR 26.2.001-2012 */
hmac_gosthash94cp_set_key (&gosthash94cpctx, LDATA("password"));
PBKDF2_TEST (&gosthash94cpctx, hmac_gosthash94cp_update, hmac_gosthash94cp_digest,
GOSTHASH94CP_DIGEST_SIZE, 1, LDATA("salt"),
SHEX("7314e7c04fb2e662c543674253f68bd0b73445d07f241bed872882da21662d58"));
PBKDF2_TEST (&gosthash94cpctx, hmac_gosthash94cp_update, hmac_gosthash94cp_digest,
GOSTHASH94CP_DIGEST_SIZE, 4096, LDATA("salt"),
SHEX("1f1829a94bdff5be10d0aeb36af498e7a97467f3b31116a5a7c1afff9deadafe"));
hmac_gosthash94cp_set_key (&gosthash94cpctx, LDATA("passwordPASSWORDpassword"));
PBKDF2_TEST (&gosthash94cpctx, hmac_gosthash94cp_update, hmac_gosthash94cp_digest,
GOSTHASH94CP_DIGEST_SIZE, 4096, LDATA("saltSALTsaltSALTsaltSALTsaltSALTsalt"),
SHEX("788358c69cb2dbe251a7bb17d5f4241f265a792a35becde8d56f326b49c85047b7638acb4764b1fd"));
hmac_gosthash94cp_set_key (&gosthash94cpctx, LDATA("pass\0word"));
PBKDF2_TEST (&gosthash94cpctx, hmac_gosthash94cp_update, hmac_gosthash94cp_digest,
GOSTHASH94CP_DIGEST_SIZE, 4096, LDATA("sa\0lt"),
SHEX("43e06c5590b08c0225242373127edf9c8e9c3291"));
PBKDF2_HMAC_TEST (pbkdf2_hmac_gosthash94cp, LDATA("password"), 1, LDATA("salt"),
SHEX("7314e7c04fb2e662c543674253f68bd0b73445d07f241bed872882da21662d58"));
}