Feature #12802
open
Is BLAKE2b unavailable if 64-bit integer is unavailable?
BLAKE2b will work on 32-bit CPUs but is optimized for 64-bit CPUs
I meant that BLAKE2b seems to need uint64_t
.
If a compiler does not support such large integer type, isn't BLAKE2b usable on that platform?
Is there still a supported environment without 64-bit integer support? ext/digest/sha2/sha2.c is already using 64-bit integers. It is compiled only when OpenSSL (or CommonCrypto) is not available, but the current versions of OpenSSL also require uint64_t.
But, I'm wondering, why not add the SHA-3 winner but only BLAKE2?
Nice @ SHA-3 branch. I think it makes sense to add both.
The reason to add BLAKE2 in addition to SHA-3 is that BLAKE2 is, in some cases, over 3X faster than SHA-3 at an equivalent security level:
https://blake2.net/sandy.png
BLAKE2b on a modern Intel CPU is even faster than MD5, but provides substantially better security.
Something of a grassroots movement is pushing for the use of BLAKE2 anywhere speed is important, such as checksumming large files.
Nobuyoshi Nakada wrote:
I meant that BLAKE2b seems to need uint64_t
.
If a compiler does not support such large integer type, isn't BLAKE2b usable on that platform?
Kazuki Yamaguchi wrote:
Is there still a supported environment without 64-bit integer support? ext/digest/sha2/sha2.c is already using 64-bit integers. It is compiled only when OpenSSL (or CommonCrypto) is not available, but the current versions of OpenSSL also require uint64_t.
But, I'm wondering, why not add the SHA-3 winner but only BLAKE2?
Many part of CRuby requires int64_t/uint64_t.
The point seems acceptable.
We looked at this issue at today's developer meeting. We could not be sure if we need our own implementation of BLAKE2 (or SHA3). Maybe a matter of time? We might need to use SHA3 someday, but OpenSSL should also have one at that time (BLAKE2 is there already).
Isn't it better for us to encourage people switching from Digest to OpenSSL?
Wondering if we can review this again?
Also available in: Atom
PDF
Like0
Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0