diff options
author | Nick Mathewson <nickm@torproject.org> | 2013-02-22 12:53:45 -0500 |
---|---|---|
committer | Nick Mathewson <nickm@torproject.org> | 2013-04-18 11:04:57 -0400 |
commit | cb75519bbf6d89ddaf6a6bb40a01a2dba09ad530 (patch) | |
tree | 1ae075833875a1e5be8e5fded4c2bdbe02f5db99 /src/or/routerparse.h | |
parent | fd93622cc897ede9c52205390bfb71e2e8588259 (diff) | |
download | tor-cb75519bbf6d89ddaf6a6bb40a01a2dba09ad530.tar.gz tor-cb75519bbf6d89ddaf6a6bb40a01a2dba09ad530.zip |
Refactor dirobj signature generation
Now we can compute the hash and signature of a dirobj before
concatenating the smartlist, and we don't need to play silly games
with sigbuf and realloc any more.
Diffstat (limited to 'src/or/routerparse.h')
-rw-r--r-- | src/or/routerparse.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/or/routerparse.h b/src/or/routerparse.h index 859a691e2a..8eac3a2aa9 100644 --- a/src/or/routerparse.h +++ b/src/or/routerparse.h @@ -21,6 +21,9 @@ int router_get_networkstatus_v3_hash(const char *s, char *digest, int router_get_networkstatus_v3_hashes(const char *s, digests_t *digests); int router_get_extrainfo_hash(const char *s, size_t s_len, char *digest); #define DIROBJ_MAX_SIG_LEN 256 +char *router_get_dirobj_signature(const char *digest, + size_t digest_len, + crypto_pk_t *private_key); int router_append_dirobj_signature(char *buf, size_t buf_len, const char *digest, size_t digest_len, |