Re: [PATCH 3/3] GOST curves generate larger overflows in mod arithmetics

2019-05-12 Thread Dmitry Eremin-Solenikov
Hi, > > For now I'm running ecc-mul-a-test and ecc-mul-g-test in a loop without any > > errors. > > To make running in a loop useful, you need to add random seeding, see > ecc-mod-test.c for an example to how to do it, enabled by the > NETTLE_TEST_SEED environment variable. Used like > > while

Re: [PATCH 3/3] GOST curves generate larger overflows in mod arithmetics

2019-05-12 Thread Niels Möller
Dmitry Eremin-Solenikov writes: > This patch makes things work for me. Is it only ecc_mod_submul_1 that you need to change? It's used via the ecc_modp_submul_1 macro. > Does it stand a chance to be applied? To accept the patch, I'd like to understand the mathematics and document what's

Re: Release?

2019-05-12 Thread Nikos Mavrogiannopoulos
On Sun, May 12, 2019 at 9:45 AM Niels Möller wrote: > > Nikos Mavrogiannopoulos writes: > > > I know of one or two applications that moved to nettle once the des > > functionality was removed from libcrypt. Not sure if that's a good > > reason to keep it, they are deprecated, but removing it may

[PATCH 1/2] Implement GOST R 34.11-2012 (Streebog) hash function

2019-05-12 Thread Dmitry Eremin-Solenikov
Signed-off-by: Dmitry Eremin-Solenikov --- Makefile.in |5 +- examples/nettle-benchmark.c |1 + hmac-streebog.c | 73 ++ hmac.h | 33 + nettle-meta-hashes.c|2 + nettle-meta.h |2 + nettle.texinfo

[PATCH 2/2] Implement PBKDF2 shortcut function for Streebog256/512

2019-05-12 Thread Dmitry Eremin-Solenikov
Signed-off-by: Dmitry Eremin-Solenikov --- Makefile.in | 1 + pbkdf2-hmac-streebog.c | 67 + pbkdf2.h| 14 + testsuite/pbkdf2-test.c | 6 4 files changed, 88 insertions(+) create mode 100644

Re: [PATCH 3/3] GOST curves generate larger overflows in mod arithmetics

2019-05-12 Thread Dmitry Eremin-Solenikov
сб, 11 мая 2019 г. в 21:55, Niels Möller : > > Dmitry Eremin-Solenikov writes: > > >> If p is close to B^size / 2, then I think a reduction like > > > > Yes, it is. > > > > As an overflow happens in low level code, do you suggest > > duplicating ecc-dup-jj/ecc-add-jja/ecc-add-jjj for GOST curves?

Re: [PATCH 1/3] Move MAC testing code to generic place from cmac-test

2019-05-12 Thread Dmitry Eremin-Solenikov
ср, 8 мая 2019 г. в 15:33, Dmitry Eremin-Solenikov : > Any chances to get these 3 patches in? Just as a word of justification: one of GOST-defined modes is CFB, which is used with 64-bit cipher (Magma, GOST 28147-89). Having this code in allows us to use it directly from Nettle instead of having

Re: Release?

2019-05-12 Thread Niels Möller
Nikos Mavrogiannopoulos writes: > I know of one or two applications that moved to nettle once the des > functionality was removed from libcrypt. Not sure if that's a good > reason to keep it, they are deprecated, but removing it may make it > slower to move to that version. But I'm not