diff options
author | Nick Mathewson <nickm@torproject.org> | 2018-09-18 12:40:18 -0400 |
---|---|---|
committer | Nick Mathewson <nickm@torproject.org> | 2018-09-18 12:40:18 -0400 |
commit | ea5792f333b1b92306d20e60b5e12bb0633aa740 (patch) | |
tree | 48f82aafe09b28d36c8034e800ef966d006b0960 /src/test/test_hs_descriptor.c | |
parent | 50367d06f2ae1a06e6553a8925b5aded7f610082 (diff) | |
download | tor-ea5792f333b1b92306d20e60b5e12bb0633aa740.tar.gz tor-ea5792f333b1b92306d20e60b5e12bb0633aa740.zip |
Make crypto_strongest_rand() non-mockable
Instead, have it call a mockable function. We don't want
crypto_strongest_rand() to be mockable, since doing so creates a
type error when we call it from ed25519-donna, which we do not build
in a test mode.
Fixes bug 27728; bugfix on 0.3.5.1-alpha
Diffstat (limited to 'src/test/test_hs_descriptor.c')
-rw-r--r-- | src/test/test_hs_descriptor.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/test/test_hs_descriptor.c b/src/test/test_hs_descriptor.c index 90f2be2906..428ca1024b 100644 --- a/src/test/test_hs_descriptor.c +++ b/src/test/test_hs_descriptor.c @@ -909,7 +909,7 @@ test_build_authorized_client(void *arg) client_pubkey_b16, strlen(client_pubkey_b16)); - MOCK(crypto_strongest_rand, mock_crypto_strongest_rand); + MOCK(crypto_strongest_rand_, mock_crypto_strongest_rand); hs_desc_build_authorized_client(subcredential, &client_auth_pk, &auth_ephemeral_sk, @@ -925,7 +925,7 @@ test_build_authorized_client(void *arg) done: tor_free(desc_client); tor_free(mem_op_hex_tmp); - UNMOCK(crypto_strongest_rand); + UNMOCK(crypto_strongest_rand_); } struct testcase_t hs_descriptor[] = { |