diff options
author | Nick Mathewson <nickm@torproject.org> | 2017-05-31 18:33:38 -0400 |
---|---|---|
committer | Nick Mathewson <nickm@torproject.org> | 2017-05-31 18:45:35 -0400 |
commit | a9be768959c189846178723d5fe44d3b59b0d983 (patch) | |
tree | 34a4e674f22dd522d339b6c064b075f7db75cd29 /src/test/test_shared_random.c | |
parent | 5b33d95a3dfe943625d78983bb53be2901a51150 (diff) | |
download | tor-a9be768959c189846178723d5fe44d3b59b0d983.tar.gz tor-a9be768959c189846178723d5fe44d3b59b0d983.zip |
Bugfix: Regenerate more certificates when appropriate
Previously we could sometimes change our signing key, but not
regenerate the certificates (signing->link and signing->auth) that
were signed with it. Also, we would regularly replace our TLS x.509
link certificate (by rotating our TLS context) but not replace our
signing->link ed25519 certificate. In both cases, the resulting
inconsistency would make other relays reject our link handshakes.
Fixes two cases of bug 22460; bugfix on 0.3.0.1-alpha.
Diffstat (limited to 'src/test/test_shared_random.c')
-rw-r--r-- | src/test/test_shared_random.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/test/test_shared_random.c b/src/test/test_shared_random.c index d511f163e3..026a0f3825 100644 --- a/src/test/test_shared_random.c +++ b/src/test/test_shared_random.c @@ -48,7 +48,7 @@ init_authority_state(void) mock_cert = authority_cert_parse_from_string(AUTHORITY_CERT_1, NULL); tt_assert(mock_cert); options->AuthoritativeDir = 1; - tt_int_op(0, ==, load_ed_keys(options, time(NULL))); + tt_int_op(load_ed_keys(options, time(NULL)), OP_GE, 0); sr_state_init(0, 0); /* It's possible a commit has been generated in our state depending on * the phase we are currently in which uses "now" as the starting @@ -286,7 +286,7 @@ test_sr_commit(void *arg) tt_assert(auth_cert); options->AuthoritativeDir = 1; - tt_int_op(0, ==, load_ed_keys(options, now)); + tt_int_op(load_ed_keys(options, time(NULL)), OP_GE, 0); } /* Generate our commit object and validate it has the appropriate field |