[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
Re: [tor-bugs] #28398 [Core Tor/Stem]: Please provide a method on descriptors for calculating digests
#28398: Please provide a method on descriptors for calculating digests
---------------------------+------------------------
Reporter: irl | Owner: atagar
Type: enhancement | Status: new
Priority: Medium | Milestone:
Component: Core Tor/Stem | Version:
Severity: Normal | Resolution:
Keywords: | Actual Points:
Parent ID: | Points:
Reviewer: | Sponsor:
---------------------------+------------------------
Comment (by irl):
For ServerDescriptor and ExtraInfoDescriptor, the digest() method is
exactly what I want for SHA-1, but there is no equivalent for SHA-256.
https://gitweb.torproject.org/torspec.git/tree/dir-spec.txt#n712
{{{
"sha256-digest" is a base64-encoded SHA256 digest of the extra-info
document, computed over the same data.
}}}
For votes only SHA-1 seems to be specified but SHA-256 could be
implemented in the same way as above:
https://gitweb.torproject.org/torspec.git/tree/dir-spec.txt#n2223
{{{
A digest of the vote from the authority that contributed to this
consensus, as signed (that is, not including the signature).
(Hex, upper-case.)
}}}
For flavoured consensuses:
https://gitweb.torproject.org/torspec.git/tree/dir-spec.txt#n3321
{{{
"additional-digest" SP flavor SP algname SP digest NL
[Any number.]
For each supported consensus flavor, every directory authority
adds one or more "additional-digest" lines. "flavor" is the name
of the consensus flavor, "algname" is the name of the hash
algorithm that is used to generate the digest, and "digest" is the
hex-encoded digest.
The hash algorithm for the microdescriptor consensus flavor is
defined as SHA256 with algname "sha256".
}}}
--
Ticket URL: <https://trac.torproject.org/projects/tor/ticket/28398#comment:2>
Tor Bug Tracker & Wiki <https://trac.torproject.org/>
The Tor Project: anonymity online
_______________________________________________
tor-bugs mailing list
tor-bugs@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-bugs