diff options
author | Nick Mathewson <nickm@torproject.org> | 2015-06-01 11:24:55 -0400 |
---|---|---|
committer | Nick Mathewson <nickm@torproject.org> | 2015-06-01 11:24:55 -0400 |
commit | 3d653dff5e891c1e547ef7eacbc991410a98c1cb (patch) | |
tree | b8169c115b1092c92ae871b1d6d08d9060a13454 /src/test | |
parent | 3028507e96a51f2058e7ce6678ac8f2d8ab1b502 (diff) | |
download | tor-3d653dff5e891c1e547ef7eacbc991410a98c1cb.tar.gz tor-3d653dff5e891c1e547ef7eacbc991410a98c1cb.zip |
Add a master-key-ed25519 line for convenience
Diffstat (limited to 'src/test')
-rw-r--r-- | src/test/test_dir.c | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/src/test/test_dir.c b/src/test/test_dir.c index 32ac8d439e..35bd8ea166 100644 --- a/src/test/test_dir.c +++ b/src/test/test_dir.c @@ -227,8 +227,16 @@ test_dir_formats(void *arg) "identity-ed25519\n" "-----BEGIN ED25519 CERT-----\n", sizeof(buf2)); strlcat(buf2, cert_buf, sizeof(buf2)); - strlcat(buf2, "-----END ED25519 CERT-----\n" - "platform Tor "VERSION" on ", sizeof(buf2)); + strlcat(buf2, "-----END ED25519 CERT-----\n", sizeof(buf2)); + strlcat(buf2, "master-key-ed25519 ", sizeof(buf2)); + { + char k[ED25519_BASE64_LEN+1]; + tt_assert(ed25519_public_to_base64(k, &r2->signing_key_cert->signing_key) + >= 0); + strlcat(buf2, k, sizeof(buf2)); + strlcat(buf2, "\n", sizeof(buf2)); + } + strlcat(buf2, "platform Tor "VERSION" on ", sizeof(buf2)); strlcat(buf2, get_uname(), sizeof(buf2)); strlcat(buf2, "\n" "protocols Link 1 2 Circuit 1\n" |