diff options
author | David Goulet <dgoulet@torproject.org> | 2018-10-30 11:36:36 -0400 |
---|---|---|
committer | David Goulet <dgoulet@torproject.org> | 2018-10-30 11:36:36 -0400 |
commit | 95559279e15393347c606eaaa323e0b6490782c2 (patch) | |
tree | fa1a3f974bf5890cb56af3141f1cf243a4bbde3d /src/feature/hs | |
parent | 6c9d678ff66d012b4c8009c6ad44409c7368ed69 (diff) | |
parent | 56f713b8a477b4203f3bfd8f3ad0952706dc9599 (diff) | |
download | tor-95559279e15393347c606eaaa323e0b6490782c2.tar.gz tor-95559279e15393347c606eaaa323e0b6490782c2.zip |
Merge branch 'tor-github/pr/415' into maint-0.3.5
Diffstat (limited to 'src/feature/hs')
-rw-r--r-- | src/feature/hs/hs_service.c | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/src/feature/hs/hs_service.c b/src/feature/hs/hs_service.c index 78654bfb23..aec2aa4381 100644 --- a/src/feature/hs/hs_service.c +++ b/src/feature/hs/hs_service.c @@ -1924,12 +1924,10 @@ build_service_desc_keys(const hs_service_t *service, goto end; } - /* Random a descriptor cookie to be used as a part of a key to encrypt the - * descriptor, if the client auth is enabled. */ - if (service->config.is_client_auth_enabled) { - crypto_strongest_rand(desc->descriptor_cookie, - sizeof(desc->descriptor_cookie)); - } + /* Random descriptor cookie to be used as a part of a key to encrypt the + * descriptor, only if the client auth is enabled will it be used. */ + crypto_strongest_rand(desc->descriptor_cookie, + sizeof(desc->descriptor_cookie)); /* Success. */ ret = 0; |