Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Replace xxHash with blake2b #1919

Merged
merged 13 commits into from May 9, 2019

Conversation

@SergiySW
Copy link
Collaborator

commented Apr 24, 2019

No description provided.

@SergiySW SergiySW added this to the V19.0 milestone Apr 24, 2019

@SergiySW SergiySW requested review from clemahieu, wezrule and cryptocode Apr 24, 2019

@SergiySW SergiySW self-assigned this Apr 24, 2019

Show resolved Hide resolved nano/node/common.hpp Outdated
Show resolved Hide resolved nano/node/common.hpp Outdated
Show resolved Hide resolved nano/node/common.hpp Outdated
auto result (XXH64_digest (state));
XXH64_freeState (state);
blake2b_state state;
blake2b_init (&state, sizeof (result));

This comment has been minimized.

Copy link
@clemahieu

clemahieu Apr 25, 2019

Collaborator

Let's use the blake2b_init_key initializer which does the key-initialization for us.

This comment has been minimized.

Copy link
@SergiySW

SergiySW Apr 25, 2019

Author Collaborator

It's much slower than extra blake2b_update, like 1.5-2 times

@SergiySW

This comment has been minimized.

Copy link
Collaborator Author

commented Apr 25, 2019

Can be modified with random_constants from #1928

@SergiySW SergiySW added this to During RC in V19 Apr 25, 2019

@wezrule

This comment has been minimized.

Copy link
Collaborator

commented Apr 27, 2019

I did an ASAN run on core_test/live and it didn't hit any of CryptoPP uninitialized global warnings, so LGTM.

@zhyatt zhyatt requested a review from cryptocode Apr 30, 2019

@SergiySW SergiySW merged commit 8ce0b7c into nanocurrency:master May 9, 2019

2 checks passed

continuous-integration/appveyor/pr AppVeyor build succeeded
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details

@zhyatt zhyatt moved this from During RC to RC 3 (TBD) in V19 May 12, 2019

argakiig added a commit to argakiig/raiblocks that referenced this pull request May 22, 2019

Replace xxHash with blake2b (nanocurrency#1919)
* Replace xxHash with blake2b

* Delete xxhash submodule & folder

* Update random_64 initialization

* Using ledger constants to generate random 128 bit union

* Protect random_128 () with mutex

* Don't call random_128 () twice

* Use static mutex for random_128

* Update endpoint_hash_raw functions

* Naming

* Functions order & static random_constants
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.