]> git.ipfire.org Git - thirdparty/tor.git/log
thirdparty/tor.git
2 years agoProp#329 Pool: Handle pre-building and using conflux sets.
David Goulet [Thu, 30 Mar 2023 19:42:27 +0000 (19:42 +0000)] 
Prop#329 Pool: Handle pre-building and using conflux sets.

Signed-off-by: David Goulet <dgoulet@torproject.org>
2 years agoProp#329 Pool: Avoid sharing Guards and Middles between circuits.
Mike Perry [Fri, 3 Feb 2023 02:11:10 +0000 (02:11 +0000)] 
Prop#329 Pool: Avoid sharing Guards and Middles between circuits.

Conflux must not use the same Guard for each leg; nor the same middle for each
leg.

2 years agoProp#329 Pool: Handle linking, unlinking, and relaunching conflux circuit legs.
David Goulet [Wed, 1 Feb 2023 22:41:03 +0000 (22:41 +0000)] 
Prop#329 Pool: Handle linking, unlinking, and relaunching conflux circuit legs.

Signed-off-by: David Goulet <dgoulet@torproject.org>
2 years agoProp#329 streams: Handle stream usage with conflux
Mike Perry [Sun, 2 Apr 2023 21:06:20 +0000 (21:06 +0000)] 
Prop#329 streams: Handle stream usage with conflux

This adds utility functions to help stream block decisions, as well as cpath
layer_hint checks for stream cell acceptance, and syncing stream lists
for conflux circuits.

These functions are then called throughout the codebase to properly manage
conflux streams.

2 years agoRefactor stream blocking due to channel cell queues
Mike Perry [Fri, 20 Jan 2023 19:14:33 +0000 (19:14 +0000)] 
Refactor stream blocking due to channel cell queues

Streams can get blocked on a circuit in two ways:
  1. When the circuit package window is full
  2. When the channel's cell queue is too high

Conflux needs to decouple stream blocking from both of these conditions,
because streams can continue on another circuit, even if the primary circuit
is blocked for either of these cases.

However, both conflux and congestion control need to know if the channel's
cell queue hit the highwatermark and is still draining, because this condition
is used by those components, independent of stream state.

Therefore, this commit renames the 'streams_blocked_on_chan' variable to
signify that it refers to the cell queue state, and also refactors the actual
stream blocking bits out, so they can be handled separately if conflux is
present.

2 years agoProp#329: Add purposes for conflux circuits
Mike Perry [Thu, 9 Feb 2023 01:43:14 +0000 (01:43 +0000)] 
Prop#329: Add purposes for conflux circuits

Because UNLINKED circuits must never be used for streams, but LINKED circuits
can be, we want these separate.

2 years agoProp#329 sendme: Adjust sendme sending and tracking for conflux
Mike Perry [Wed, 18 Jan 2023 22:48:43 +0000 (22:48 +0000)] 
Prop#329 sendme: Adjust sendme sending and tracking for conflux

Because circuit-level sendmes are sent before relay data cells are processed,
we can safely move this to before the conflux decision. In this way,
regardless of conflux being negotiated, we still send sendmes as soon as data
cells are recieved. This avoids introducing conflux queue delay into RTT
measurement, which is important for measuring actual circuit capacity.

The circuit-level tracking must happen inside the call to send a data cell,
since that call now chooses a circuit to send on. Turns out, we were already
doing this kind of here, but only for the digest. Now we do both things here.

2 years agoProp#329 OOM: Handle freeing conflux queues on OOM
David Goulet [Fri, 3 Mar 2023 19:28:18 +0000 (14:28 -0500)] 
Prop#329 OOM: Handle freeing conflux queues on OOM

We use the oldest-circ-first method here, since that seems good for conflux:
queues could briefly spike, but the bad case is if they are maliciously
bloated to stick around for a long time.

The tradeoff here is that it is possible to kill old circuits on a relay
quickly, but that has always been the case with this algorithm choice.

Signed-off-by: David Goulet <dgoulet@torproject.org>
2 years agoProp#329 Algs: Conflux multiplexed cell sending decision algs
Mike Perry [Tue, 24 Jan 2023 23:05:17 +0000 (23:05 +0000)] 
Prop#329 Algs: Conflux multiplexed cell sending decision algs

2 years agoProp#329 Algs: Conflux multiplexed cell receive handling
Mike Perry [Wed, 14 Dec 2022 21:03:52 +0000 (21:03 +0000)] 
Prop#329 Algs: Conflux multiplexed cell receive handling

2 years agoProp#329 Headers: Header files for conflux
Mike Perry [Wed, 14 Dec 2022 21:03:32 +0000 (21:03 +0000)] 
Prop#329 Headers: Header files for conflux

2 years agoProp#329 params: Consensus parameter and torrc handling
Mike Perry [Tue, 7 Mar 2023 19:11:38 +0000 (19:11 +0000)] 
Prop#329 params: Consensus parameter and torrc handling

Signed-off-by: David Goulet <dgoulet@torproject.org>
2 years agoProp#329 Tests: Add tests for conflux cells.
David Goulet [Wed, 1 Feb 2023 22:32:33 +0000 (22:32 +0000)] 
Prop#329 Tests: Add tests for conflux cells.

Signed-off-by: David Goulet <dgoulet@torproject.org>
2 years agoProp#329 Cells: Building and parsing parsing conflux commands
David Goulet [Wed, 1 Feb 2023 21:51:58 +0000 (21:51 +0000)] 
Prop#329 Cells: Building and parsing parsing conflux commands

Signed-off-by: David Goulet <dgoulet@torproject.org>
2 years agotrunnel: Add Conflux related cell definition
David Goulet [Mon, 12 Dec 2022 18:09:27 +0000 (13:09 -0500)] 
trunnel: Add Conflux related cell definition

Signed-off-by: David Goulet <dgoulet@torproject.org>
2 years agoprotover: Support Relay=5 for Conflux (prop329)
David Goulet [Wed, 30 Nov 2022 18:48:53 +0000 (13:48 -0500)] 
protover: Support Relay=5 for Conflux (prop329)

Closes #40721

Signed-off-by: David Goulet <dgoulet@torproject.org>
2 years agoMerge branch 'maint-0.4.7'
David Goulet [Wed, 15 Mar 2023 15:14:02 +0000 (11:14 -0400)] 
Merge branch 'maint-0.4.7'

2 years agogitignore: Add tags file from ctags
David Goulet [Wed, 15 Mar 2023 15:13:43 +0000 (11:13 -0400)] 
gitignore: Add tags file from ctags

Signed-off-by: David Goulet <dgoulet@torproject.org>
2 years agoMerge branch 'tor-gitlab/mr/700'
David Goulet [Mon, 13 Mar 2023 15:22:31 +0000 (11:22 -0400)] 
Merge branch 'tor-gitlab/mr/700'

2 years agometrics: Add HS service side circuit build time metrics.
Gabriela Moldovan [Wed, 8 Mar 2023 17:52:20 +0000 (17:52 +0000)] 
metrics: Add HS service side circuit build time metrics.

This adds 2 histogram metrics for hidden services:
* `tor_hs_rend_circ_build_time` - the rendezvous circuit build time in milliseconds
* `tor_hs_intro_circ_build_time` - the introduction circuit build time in milliseconds

The text representation representation of the new metrics looks like this:
```
# HELP tor_hs_rend_circ_build_time The rendezvous circuit build time in milliseconds
# TYPE tor_hs_rend_circ_build_time histogram
tor_hs_rend_circ_build_time_bucket{onion="<elided>",le="1000.00"} 2
tor_hs_rend_circ_build_time_bucket{onion="<elided>",le="5000.00"} 10
tor_hs_rend_circ_build_time_bucket{onion="<elided>",le="10000.00"} 10
tor_hs_rend_circ_build_time_bucket{onion="<elided>",le="30000.00"} 10
tor_hs_rend_circ_build_time_bucket{onion="<elided>",le="60000.00"} 10
tor_hs_rend_circ_build_time_bucket{onion="<elided>",le="+Inf"} 10
tor_hs_rend_circ_build_time_sum{onion="<elided>"} 10824
tor_hs_rend_circ_build_time_count{onion="<elided>"} 10
# HELP tor_hs_intro_circ_build_time The introduction circuit build time in milliseconds
# TYPE tor_hs_intro_circ_build_time histogram
tor_hs_intro_circ_build_time_bucket{onion="<elided>",le="1000.00"} 0
tor_hs_intro_circ_build_time_bucket{onion="<elided>",le="5000.00"} 6
tor_hs_intro_circ_build_time_bucket{onion="<elided>",le="10000.00"} 6
tor_hs_intro_circ_build_time_bucket{onion="<elided>",le="30000.00"} 6
tor_hs_intro_circ_build_time_bucket{onion="<elided>",le="60000.00"} 6
tor_hs_intro_circ_build_time_bucket{onion="<elided>",le="+Inf"} 6
tor_hs_intro_circ_build_time_sum{onion="<elided>"} 9843
tor_hs_intro_circ_build_time_count{onion="<elided>"} 6
```

Signed-off-by: Gabriela Moldovan <gabi@torproject.org>
2 years agometrics: Add support for histograms.
Gabriela Moldovan [Wed, 8 Mar 2023 17:51:58 +0000 (17:51 +0000)] 
metrics: Add support for histograms.

This will enable us to add e.g. circuit build metrics (#40717).

Signed-off-by: Gabriela Moldovan <gabi@torproject.org>
2 years agoUpdate 3 files
nonameformee [Sun, 12 Mar 2023 11:40:52 +0000 (11:40 +0000)] 
Update 3 files

- /src/feature/dirauth/process_descs.c
- /src/test/test_process_descs.c
- /changes/ticket40760

2 years agoMerge branch 'tor-gitlab/mr/697'
David Goulet [Tue, 7 Mar 2023 14:49:53 +0000 (09:49 -0500)] 
Merge branch 'tor-gitlab/mr/697'

2 years agometrics: Add a `reason` label to the HS error metrics.
Gabriela Moldovan [Wed, 15 Feb 2023 14:52:35 +0000 (14:52 +0000)] 
metrics: Add a `reason` label to the HS error metrics.

This adds a `reason` label to the `hs_intro_rejected_intro_req_count` and
`hs_rdv_error_count` metrics introduced in #40755.

Metric look up and intialization is now more a bit more involved. This may be
fine for now, but it will become unwieldy if/when we add more labels (and as
such will need to be refactored).

Also, in the future, we may want to introduce finer grained `reason` labels.
For example, the `invalid_introduce2` label actually covers multiple types of
errors that can happen during the processing of an INTRODUCE2 cell (such as
cell parse errors, replays, decryption errors).

Signed-off-by: Gabriela Moldovan <gabi@torproject.org>
2 years agoMerge branch 'tor-gitlab/mr/696'
David Goulet [Tue, 7 Mar 2023 13:52:34 +0000 (08:52 -0500)] 
Merge branch 'tor-gitlab/mr/696'

2 years agoMerge branch 'maint-0.4.7'
David Goulet [Tue, 7 Mar 2023 13:39:48 +0000 (08:39 -0500)] 
Merge branch 'maint-0.4.7'

2 years agoscripts: Bye bye 0.4.5, you have reached end of life
David Goulet [Thu, 16 Feb 2023 20:25:16 +0000 (15:25 -0500)] 
scripts: Bye bye 0.4.5, you have reached end of life

Signed-off-by: David Goulet <dgoulet@torproject.org>
2 years agometrics: Add metrics for rendezvous and introduction request failures.
Gabriela Moldovan [Fri, 10 Feb 2023 12:20:23 +0000 (12:20 +0000)] 
metrics: Add metrics for rendezvous and introduction request failures.

This introduces a couple of new service side metrics:
* `hs_intro_rejected_intro_req_count`, which counts the number of introduction
  requests rejected by the hidden service
* `hs_rdv_error_count`, which counts the number of rendezvous errors as seen by
  the hidden service (this number includes the number of circuit establishment
  failures, failed retries, end-to-end circuit setup failures)

Closes #40755. This partially addresses #40717.

Signed-off-by: Gabriela Moldovan <gabi@torproject.org>
2 years agoReworded OpenSSL bug 7712 detection warning to avoid OpenSSL 1.1.1b detection false...
Richard Pospesel [Thu, 16 Feb 2023 13:27:30 +0000 (13:27 +0000)] 
Reworded OpenSSL bug 7712 detection warning to avoid OpenSSL 1.1.1b detection false positive.

2 years agovote AuthDirMaxServersPerAddr in consensus params
Roger Dingledine [Sun, 12 Feb 2023 20:50:55 +0000 (15:50 -0500)] 
vote AuthDirMaxServersPerAddr in consensus params

Directory authorities now include their AuthDirMaxServersPerAddr
config option in the consensus parameter section of their vote. Now
external tools can better predict how they will behave.

In particular, the value should make its way to the
https://consensus-health.torproject.org/#consensusparams page.

Once enough dir auths vote this param, they should also compute a
consensus value for it in the consensus document. Nothing uses this
consensus value yet, but we could imagine having dir auths consult it
in the future.

Implements ticket 40753.

2 years agoMerge branch 'maint-0.4.7'
David Goulet [Mon, 13 Feb 2023 15:16:13 +0000 (10:16 -0500)] 
Merge branch 'maint-0.4.7'

2 years agometrics: Decrement hs_intro_established_count on intro circuit close.
Gabriela Moldovan [Fri, 10 Feb 2023 20:31:36 +0000 (20:31 +0000)] 
metrics: Decrement hs_intro_established_count on intro circuit close.

Closes #40751.

Signed-off-by: Gabriela Moldovan <gabi@torproject.org>
2 years agoUpdate `find_service` documentation.
Gabriela Moldovan [Fri, 10 Feb 2023 15:27:43 +0000 (15:27 +0000)] 
Update `find_service` documentation.

This updates the docs to stop suggesting `pk` can be NULL, as that doesn't seem
to be the case anymore (`tor_assert(pk)`).

Signed-off-by: Gabriela Moldovan <gabi@torproject.org>
2 years agoExtend blinding testvec with timeperiod test.
Nick Mathewson [Fri, 10 Feb 2023 13:11:39 +0000 (08:11 -0500)] 
Extend blinding testvec with timeperiod test.

When I copied this to arti, I messed up and thought that the default
time period was 1440 seconds for some weird testing reason. That led
to confusion.

This commit adds a test case that time period 1440 is May 20, 1973:
now arti and c tor match!

2 years agoFix small typo in mainloop.c docs.
Gabriela Moldovan [Tue, 7 Feb 2023 12:00:57 +0000 (12:00 +0000)] 
Fix small typo in mainloop.c docs.

The docs should reference `tor_event_new()` rather than `tor_libevent_new()`.

Signed-off-by: Gabriela Moldovan <gabi@torproject.org>
2 years agoFix typos
Dimitris Apostolou [Sat, 4 Feb 2023 22:36:37 +0000 (00:36 +0200)] 
Fix typos

2 years agofix trivial typos
Roger Dingledine [Mon, 30 Jan 2023 21:23:24 +0000 (16:23 -0500)] 
fix trivial typos

2 years agoMerge branch 'tor-gitlab/mr/686'
David Goulet [Fri, 27 Jan 2023 13:47:46 +0000 (08:47 -0500)] 
Merge branch 'tor-gitlab/mr/686'

2 years agoMerge branch 'maint-0.4.7'
David Goulet [Thu, 26 Jan 2023 18:11:22 +0000 (13:11 -0500)] 
Merge branch 'maint-0.4.7'

2 years agoMerge branch 'tor-gitlab/mr/687' into maint-0.4.7
David Goulet [Thu, 26 Jan 2023 18:11:18 +0000 (13:11 -0500)] 
Merge branch 'tor-gitlab/mr/687' into maint-0.4.7

2 years agoMerge branch 'maint-0.4.7'
David Goulet [Wed, 25 Jan 2023 19:13:35 +0000 (14:13 -0500)] 
Merge branch 'maint-0.4.7'

2 years agoMerge branch 'maint-0.4.5' into maint-0.4.7
David Goulet [Wed, 25 Jan 2023 19:13:35 +0000 (14:13 -0500)] 
Merge branch 'maint-0.4.5' into maint-0.4.7

2 years agocompress_lzma: New enum values from liblzma 5.3.x maint-0.4.5
Micah Elizabeth Scott [Wed, 18 Jan 2023 22:14:47 +0000 (14:14 -0800)] 
compress_lzma: New enum values from liblzma 5.3.x

Add new liblzma enums (LZMA_SEEK_NEEDED and LZMA_RET_INTERNAL*)
conditional to the API version they arrived in. The first stable
version of liblzma this affects is 5.4.0

Fixes #40741

Signed-off-by: Micah Elizabeth Scott <beth@torproject.org>
2 years agorelay: Use the right max queue size value in log
David Goulet [Wed, 25 Jan 2023 19:10:20 +0000 (14:10 -0500)] 
relay: Use the right max queue size value in log

Fixes #40745

Signed-off-by: David Goulet <dgoulet@torproject.org>
2 years agoAdd a test vector for disaster SRV calculation.
Nick Mathewson [Wed, 25 Jan 2023 14:04:07 +0000 (09:04 -0500)] 
Add a test vector for disaster SRV calculation.

2 years agocompress_lzma: New enum values from liblzma 5.3.x
Micah Elizabeth Scott [Wed, 18 Jan 2023 22:14:47 +0000 (14:14 -0800)] 
compress_lzma: New enum values from liblzma 5.3.x

Add new liblzma enums (LZMA_SEEK_NEEDED and LZMA_RET_INTERNAL*)
conditional to the API version they arrived in. The first stable
version of liblzma this affects is 5.4.0

Fixes #40741

Signed-off-by: Micah Elizabeth Scott <beth@torproject.org>
2 years agoAdd more test-vectors for key blinding.
Nick Mathewson [Thu, 19 Jan 2023 17:23:47 +0000 (12:23 -0500)] 
Add more test-vectors for key blinding.

These are verified-as-correct against the current C implementation;
adding them here gives us something to copy into Arti.

2 years agoFix compiler warnings about unused variables
David Goulet [Thu, 19 Jan 2023 14:38:21 +0000 (09:38 -0500)] 
Fix compiler warnings about unused variables

Fixes #40743

Signed-off-by: David Goulet <dgoulet@torproject.org>
2 years agoMerge branch 'tor-gitlab/mr/683'
David Goulet [Thu, 19 Jan 2023 15:10:14 +0000 (10:10 -0500)] 
Merge branch 'tor-gitlab/mr/683'

2 years agoAdd a test vector for crypto_mac_sha3
Nick Mathewson [Thu, 19 Jan 2023 14:06:47 +0000 (09:06 -0500)] 
Add a test vector for crypto_mac_sha3

2 years agodoc: Add tpo website update to ReleasingTor.md
David Goulet [Thu, 19 Jan 2023 13:43:59 +0000 (08:43 -0500)] 
doc: Add tpo website update to ReleasingTor.md

Signed-off-by: David Goulet <dgoulet@torproject.org>
2 years agochangelog: Update with latest releases
David Goulet [Thu, 12 Jan 2023 17:11:16 +0000 (12:11 -0500)] 
changelog: Update with latest releases

Signed-off-by: David Goulet <dgoulet@torproject.org>
2 years agoMerge branch 'maint-0.4.7'
David Goulet [Thu, 12 Jan 2023 17:09:42 +0000 (12:09 -0500)] 
Merge branch 'maint-0.4.7'

2 years agoversion: Bump version to 0.4.7.13-dev
Tor CI Release [Thu, 12 Jan 2023 16:26:32 +0000 (16:26 +0000)] 
version: Bump version to 0.4.7.13-dev

2 years agoMerge branch 'maint-0.4.5' into maint-0.4.7
David Goulet [Thu, 12 Jan 2023 17:09:26 +0000 (12:09 -0500)] 
Merge branch 'maint-0.4.5' into maint-0.4.7

2 years agoversion: Bump version to 0.4.5.16-dev
Tor CI Release [Thu, 12 Jan 2023 16:26:31 +0000 (16:26 +0000)] 
version: Bump version to 0.4.5.16-dev

2 years agoMerge branch 'maint-0.4.7'
David Goulet [Thu, 12 Jan 2023 16:15:59 +0000 (11:15 -0500)] 
Merge branch 'maint-0.4.7'

2 years agoversion: Bump version to 0.4.7.13
Tor CI Release [Thu, 12 Jan 2023 16:01:09 +0000 (16:01 +0000)] 
version: Bump version to 0.4.7.13

2 years agoMerge branch 'maint-0.4.5' into maint-0.4.7
David Goulet [Thu, 12 Jan 2023 16:15:43 +0000 (11:15 -0500)] 
Merge branch 'maint-0.4.5' into maint-0.4.7

2 years agoversion: Bump version to 0.4.5.16
Tor CI Release [Thu, 12 Jan 2023 16:01:04 +0000 (16:01 +0000)] 
version: Bump version to 0.4.5.16

2 years agoMerge branch 'maint-0.4.7'
David Goulet [Thu, 12 Jan 2023 16:07:40 +0000 (11:07 -0500)] 
Merge branch 'maint-0.4.7'

2 years agoMerge branch 'maint-0.4.5' into maint-0.4.7
David Goulet [Thu, 12 Jan 2023 16:07:39 +0000 (11:07 -0500)] 
Merge branch 'maint-0.4.5' into maint-0.4.7

2 years agofallbackdir: Update list generated on January 12, 2023
Tor CI Release [Thu, 12 Jan 2023 16:00:16 +0000 (16:00 +0000)] 
fallbackdir: Update list generated on January 12, 2023

2 years agoUpdate geoip files to match ipfire location db, 2023/01/12.
Tor CI Release [Thu, 12 Jan 2023 16:00:06 +0000 (16:00 +0000)] 
Update geoip files to match ipfire location db, 2023/01/12.

2 years agoMerge branch 'maint-0.4.7'
David Goulet [Thu, 12 Jan 2023 15:52:35 +0000 (10:52 -0500)] 
Merge branch 'maint-0.4.7'

2 years agoMerge branch 'maint-0.4.5' into maint-0.4.7
David Goulet [Thu, 12 Jan 2023 15:52:35 +0000 (10:52 -0500)] 
Merge branch 'maint-0.4.5' into maint-0.4.7

2 years agoMerge branch 'ticket40730_045_01' into maint-0.4.5
David Goulet [Thu, 12 Jan 2023 15:52:31 +0000 (10:52 -0500)] 
Merge branch 'ticket40730_045_01' into maint-0.4.5

2 years agoMerge branch 'maint-0.4.7'
David Goulet [Thu, 12 Jan 2023 15:49:57 +0000 (10:49 -0500)] 
Merge branch 'maint-0.4.7'

2 years agodirauth: Reject 0.4.6.x series at the authority level 62357
David Goulet [Thu, 12 Jan 2023 14:06:32 +0000 (09:06 -0500)] 
dirauth: Reject 0.4.6.x series at the authority level

Closes #40664

Signed-off-by: David Goulet <dgoulet@torproject.org>
2 years agoMerge branch 'maint-0.4.7'
David Goulet [Wed, 11 Jan 2023 18:14:45 +0000 (13:14 -0500)] 
Merge branch 'maint-0.4.7'

2 years agoCoverity CID 1518991: Tighter bounds on consensus param value.
Mike Perry [Wed, 11 Jan 2023 17:32:20 +0000 (17:32 +0000)] 
Coverity CID 1518991: Tighter bounds on consensus param value.

This prevents sign extension overflow in cwnd_became_full().

2 years agoMerge branch 'maint-0.4.7'
David Goulet [Wed, 11 Jan 2023 14:03:29 +0000 (09:03 -0500)] 
Merge branch 'maint-0.4.7'

2 years agoMerge branch 'maint-0.4.5' into maint-0.4.7
David Goulet [Wed, 11 Jan 2023 14:03:29 +0000 (09:03 -0500)] 
Merge branch 'maint-0.4.5' into maint-0.4.7

2 years agoMerge branch 'tor-gitlab/mr/538' into maint-0.4.5
David Goulet [Wed, 11 Jan 2023 14:03:26 +0000 (09:03 -0500)] 
Merge branch 'tor-gitlab/mr/538' into maint-0.4.5

2 years agoMerge branch 'maint-0.4.7'
David Goulet [Tue, 10 Jan 2023 20:58:28 +0000 (15:58 -0500)] 
Merge branch 'maint-0.4.7'

2 years agoDo not reset our RTT in slow start.
Mike Perry [Tue, 10 Jan 2023 20:47:11 +0000 (20:47 +0000)] 
Do not reset our RTT in slow start.

If a circuit only sends a tiny amount of data such that its cwnd is not
full, it won't increase its cwnd above the minimum. Since slow start circuits
should never hit the minimum otherwise, we can just ignore them for RTT reset
to handle this.

2 years agoMerge branch 'maint-0.4.7'
David Goulet [Tue, 10 Jan 2023 16:57:11 +0000 (11:57 -0500)] 
Merge branch 'maint-0.4.7'

2 years agoMerge branch 'tor-gitlab/mr/678'
David Goulet [Tue, 10 Jan 2023 16:57:07 +0000 (11:57 -0500)] 
Merge branch 'tor-gitlab/mr/678'

2 years agocc: Rename function to avoid confusion
David Goulet [Tue, 10 Jan 2023 15:13:33 +0000 (10:13 -0500)] 
cc: Rename function to avoid confusion

Signed-off-by: David Goulet <dgoulet@torproject.org>
2 years agoChanges file for bug 40732
Mike Perry [Wed, 14 Dec 2022 17:19:01 +0000 (17:19 +0000)] 
Changes file for bug 40732

2 years agoSafety fixes to RFC3742
Mike Perry [Thu, 15 Dec 2022 22:03:26 +0000 (22:03 +0000)] 
Safety fixes to RFC3742

2 years agoReduce size of congestion control next_*_event fields.
Mike Perry [Wed, 21 Dec 2022 17:35:09 +0000 (17:35 +0000)] 
Reduce size of congestion control next_*_event fields.

Since these are derived from the number of SENDMEs in a cwnd/cc update,
and a cwnd should not exceed ~10k, there's plenty of room in uint16_t
for them, even if the network gets significantly faster.

2 years agoClean up next_cc_event handling.
Mike Perry [Wed, 21 Dec 2022 01:18:28 +0000 (01:18 +0000)] 
Clean up next_cc_event handling.

2 years agoAvoid increasing the congestion window if it is not full.
Mike Perry [Fri, 16 Dec 2022 21:12:50 +0000 (21:12 +0000)] 
Avoid increasing the congestion window if it is not full.

Also provides some stickiness, so that once full, the congestion window is
considered still full for the rest of an update cycle, or the entire
congestion window.

In this way, we avoid increasing the congestion window if it is not fully
utilized, but we can still back off in this case. This substantially reduces
queue use in Shadow.

2 years agoMerge branch 'tor-gitlab/mr/676'
David Goulet [Tue, 10 Jan 2023 16:53:10 +0000 (11:53 -0500)] 
Merge branch 'tor-gitlab/mr/676'

2 years agoMerge branch 'mr-674-fixup' into main+mr-674-fixup
Mike Perry [Tue, 10 Jan 2023 16:18:41 +0000 (16:18 +0000)] 
Merge branch 'mr-674-fixup' into main+mr-674-fixup

2 years agoMerge branch 'maint-0.4.7'
David Goulet [Tue, 10 Jan 2023 16:15:36 +0000 (11:15 -0500)] 
Merge branch 'maint-0.4.7'

2 years agoMerge branch 'tor-gitlab/mr/675' into maint-0.4.7
David Goulet [Tue, 10 Jan 2023 16:15:32 +0000 (11:15 -0500)] 
Merge branch 'tor-gitlab/mr/675' into maint-0.4.7

2 years agocc: Rename function to avoid confusion
David Goulet [Tue, 10 Jan 2023 15:13:33 +0000 (10:13 -0500)] 
cc: Rename function to avoid confusion

Signed-off-by: David Goulet <dgoulet@torproject.org>
2 years agoChanges file for bug 40732
Mike Perry [Wed, 14 Dec 2022 17:19:01 +0000 (17:19 +0000)] 
Changes file for bug 40732

2 years agoSafety fixes to RFC3742
Mike Perry [Thu, 15 Dec 2022 22:03:26 +0000 (22:03 +0000)] 
Safety fixes to RFC3742

2 years agoReduce size of congestion control next_*_event fields.
Mike Perry [Wed, 21 Dec 2022 17:35:09 +0000 (17:35 +0000)] 
Reduce size of congestion control next_*_event fields.

Since these are derived from the number of SENDMEs in a cwnd/cc update,
and a cwnd should not exceed ~10k, there's plenty of room in uint16_t
for them, even if the network gets significantly faster.

2 years agoClean up next_cc_event handling.
Mike Perry [Wed, 21 Dec 2022 01:18:28 +0000 (01:18 +0000)] 
Clean up next_cc_event handling.

2 years agoAvoid increasing the congestion window if it is not full.
Mike Perry [Fri, 16 Dec 2022 21:12:50 +0000 (21:12 +0000)] 
Avoid increasing the congestion window if it is not full.

Also provides some stickiness, so that once full, the congestion window is
considered still full for the rest of an update cycle, or the entire
congestion window.

In this way, we avoid increasing the congestion window if it is not fully
utilized, but we can still back off in this case. This substantially reduces
queue use in Shadow.

2 years agostate: Fix segfault on malformed file
David Goulet [Tue, 10 Jan 2023 14:24:09 +0000 (09:24 -0500)] 
state: Fix segfault on malformed file

Having no TotalBuildTimes along a positive CircuitBuildAbandonedCount
count lead to a segfault. We check for that condition and then BUG + log
warn if that is the case.

It should never happened in theory but if someone modified their state
file, it can lead to this problem so instead of segfaulting, warn.

Fixes #40437

Signed-off-by: David Goulet <dgoulet@torproject.org>
2 years agoMerge branch 'maint-0.4.7'
David Goulet [Tue, 10 Jan 2023 14:12:20 +0000 (09:12 -0500)] 
Merge branch 'maint-0.4.7'

2 years agoshellcheck: Fix new warnings
David Goulet [Tue, 10 Jan 2023 14:11:52 +0000 (09:11 -0500)] 
shellcheck: Fix new warnings

Nothing important, mostly false positive except one case.

Signed-off-by: David Goulet <dgoulet@torproject.org>
2 years agosandbox: Allow my-consensus-* files for an authority
David Goulet [Tue, 10 Jan 2023 14:02:13 +0000 (09:02 -0500)] 
sandbox: Allow my-consensus-* files for an authority

Fixes #40729

Signed-off-by: David Goulet <dgoulet@torproject.org>
2 years agoMerge branch 'tor-gitlab/mr/668'
David Goulet [Thu, 22 Dec 2022 19:03:40 +0000 (14:03 -0500)] 
Merge branch 'tor-gitlab/mr/668'

2 years agoAdd back comments about Stable/familiar decay
Georg Koppen [Wed, 21 Dec 2022 10:43:26 +0000 (10:43 +0000)] 
Add back comments about Stable/familiar decay

Closes: #40734.