[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
Re: [tor-bugs] #16943 [Tor]: Implement prop250 (Random Number Generation During Tor Voting)
#16943: Implement prop250 (Random Number Generation During Tor Voting)
-------------------------+------------------------------------
Reporter: asn | Owner: dgoulet
Type: enhancement | Status: needs_review
Priority: High | Milestone: Tor: 0.2.8.x-final
Component: Tor | Version:
Severity: Normal | Resolution:
Keywords: tor-hs | Actual Points:
Parent ID: #8244 | Points: large
Sponsor: SponsorR |
-------------------------+------------------------------------
Comment (by teor):
(This is my second comment. Please read both.)
Compiling with clang (with some extra warnings) yields the following
integer size complaints:
Fixed in 185189a in my branch prop250_final_v5 in
https://github.com/teor2345/tor.git
(You might want to split this into a series of fixups.)
next_valid_after_time should be time_t in:
{{{
time_t
get_next_valid_after_time(time_t now)
{
int next_valid_after_time;
}}}
sr_parse_srv has the only remaining implicit integer conversion warning -
it would be nice to silence it by casting the result of tor_parse_long()
to int:
{{{
sr_srv_t *
sr_parse_srv(const smartlist_t *args)
{
char *value;
int num_reveals, ok, ret;
sr_srv_t *srv = NULL;
tor_assert(args);
if (smartlist_len(args) < 2) {
goto end;
}
/* First argument is the number of reveal values */
num_reveals = tor_parse_long(smartlist_get(args, 0),
10, 0, INT32_MAX, &ok, NULL);
}}}
ts should be time_t:
{{{
static void
test_encoding(void *arg)
{
(void) arg;
int ret, duper_rand = 42;
/* Random number is 32 bytes. */
char raw_rand[32];
uint64_t ts = 1454333590;
}}}
These should be tt_u64_op:
* `tt_int_op(state->n_protocol_runs, ==, 1);`
* `tt_int_op(state->n_protocol_runs, ==, 45);`
* `tt_int_op(state->n_protocol_runs, ==, 46);`
--
Ticket URL: <https://trac.torproject.org/projects/tor/ticket/16943#comment:37>
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