Age | Commit message (Collapse) | Author |
|
These were meant to demonstrate old behavior, or old rust behavior.
One of them _should_ work in Rust, but won't because of
implementation details. We'll fix that up later.
|
|
The C code and the rust code had different separate integer overflow
bugs here. That suggests that we're better off just forbidding this
pathological case.
Also, add tests for expected behavior on receiving a bad protocol
list in a consensus.
Fixes another part of 25249.
|
|
Fixes part of 24249; bugfix on 0.2.9.4-alpha.
|
|
These are as Teor wrote them; I've disabled the ones that don't pass
yet, with XXXX comments.
|
|
I've refactored these to be a separate function, to avoid tricky
merge conflicts.
Some of these are disabled with "XXXX" comments; they should get
fixed moving forward.
|
|
Part of #25193
Signed-off-by: David Goulet <dgoulet@torproject.org>
|
|
|
|
This also adds one that tests the integration with the nodelist.
Signed-off-by: David Goulet <dgoulet@torproject.org>
|
|
|
|
|
|
|
|
If the cache is using 20% of our maximum allowed memory, clean 10% of it. Same
behavior as the HS descriptor cache.
Closes #25122
Signed-off-by: David Goulet <dgoulet@torproject.org>
|
|
Closes #25094.
Signed-off-by: David Goulet <dgoulet@torproject.org>
|
|
Debug log the elapsed time in cc_stats_refill_bucket
Part of #25094.
Signed-off-by: David Goulet <dgoulet@torproject.org>
|
|
This round is left over from the tenths of a second code.
Part of #25094.
|
|
Signed-off-by: David Goulet <dgoulet@torproject.org>
|
|
|
|
|
|
|
|
We've been seeing problems with destroy cells queues taking up a
huge amount of RAM. We can mitigate this, since while a full packed
destroy cell takes 514 bytes, we only need 5 bytes to remember a
circuit ID and a reason.
Fixes bug 24666. Bugfix on 0.2.5.1-alpha, when destroy cell queues
were introduced.
|
|
|
|
|
|
|
|
|
|
OpenBSD doesn't like tricks where you use a too-wide sscanf argument
for a too-narrow array, even when you know the input string
statically. The fix here is just to use bigger buffers.
Fixes 15582; bugfix on a3dafd3f58bb312 in 0.2.6.2-alpha.
|
|
|
|
|
|
|
|
Clang didn't like that we were passing uint64_t values to an API
that wanted uint32_t. GCC has either not cared, or has figured out
that the values in question were safe to cast to uint32_t.
Fixes bug22916; bugfix on 0.2.7.2-alpha.
|
|
|
|
This is a backport of 19615bce64cd381a925bc3910120ac39ca918e7c to
fix bug 22838.
|
|
|
|
|
|
|
|
|
|
|
|
Fixes bug 22789; bugfix on 0.2.3.8-alpha.
|
|
|
|
The tests previously assumed that the link handshake code would be
calling get_my_certs() -- when I changed it to call get_own_cert()
instead for the (case 2) 22460 fix, the tests failed, since the tls
connection wasn't really there.
This change makes us start mocking out the tor_tls_get_own_cert()
function too.
It also corrects the behavior of the mock_get_peer_cert() function
-- it should have been returning a newly allocated copy.
|
|
I think this one probably can't underflow, since the input ranges
are small. But let's not tempt fate.
This patch also replaces the "cmp" functions here with just "eq"
functions, since nothing actually checked for anything besides 0 and
nonzero.
Related to 21278.
|
|
|
|
Determining if OpenSSL structures are opaque now uses an autoconf check
instead of comparing the version number. Some definitions have been
moved to their own check as assumptions which were true for OpenSSL
with opaque structures did not hold for LibreSSL. Closes ticket 21359.
|
|
This disregards anything smaller than an IPv6 /64, and rejects ports that
are rejected on an IPv6 /16 or larger.
Adjust existing unit tests, and add more to cover exceptional cases.
No IPv4 behaviour changes.
Fixes bug 21357
|
|
These tests currently fail due to bug 21357
|
|
Related to 19769.
|
|
The server-side clipping now clamps to one of two values, both
for what to report, and how long to cache.
Additionally, we move some defines to dns.h, and give them better
names.
|
|
Closes #20938
Signed-off-by: David Goulet <dgoulet@torproject.org>
|
|
Also combine all of the checks into one if-tree as only one of them
should actually succeed.
|
|
Attempted fix for 19960.
Also, fixes a typo.
|
|
This is an attempt to figure out what's up with #19960
|