Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

hs-v3: Don't assert if we don't have the intro point descriptor #358

Closed

Conversation

Labels
None yet
Projects
None yet
3 participants
@dgoulet-tor
Copy link
Contributor

@dgoulet-tor dgoulet-tor commented Sep 19, 2018

When sending the INTRODUCE1 cell, we lookup the intro point onion key but
there is a possibility that between opening the circuit and sending the cell
the relay descriptor of the node could have been removed leading to not
finding the onion key and a non fatal assert client side which also closes the
SOCKS connection without trying anything else.

We now look for that missing onion key and recover gracefully by closing the
intro point circuit, noting down the error in the failure cache and tor then
tries a new intro point.

Note that the send introduce1 function now makes sure to close the intro
circuit in case of an error because the caller is expecting it by validating
it with a non fatal assert. It is especially important so we can recover and
select a new intro point.

Fixes #27774

Signed-off-by: David Goulet dgoulet@torproject.org

When sending the INTRODUCE1 cell, we lookup the intro point onion key but
there is a possibility that between opening the circuit and sending the cell
the relay descriptor of the node could have been removed leading to not
finding the onion key and a non fatal assert client side which also closes the
SOCKS connection without trying anything else.

We now look for that missing onion key and recover gracefully by closing the
intro point circuit, noting down the error in the failure cache and tor then
tries a new intro point.

Note that the send introduce1 function now makes sure to close the intro
circuit in case of an error because the caller is expecting it by validating
it with a non fatal assert. It is especially important so we can recover and
select a new intro point.

Fixes #27774

Signed-off-by: David Goulet <dgoulet@torproject.org>
@coveralls
Copy link

@coveralls coveralls commented Sep 19, 2018

Coverage Status

Coverage decreased (-0.006%) to 61.888% when pulling bf52a41 on dgoulet-tor:ticket27774_035_01 into 1191596 on torproject:master.

@nmathewson
Copy link
Contributor

@nmathewson nmathewson commented Sep 30, 2018

This has been squashed and merged to master.

@nmathewson nmathewson closed this Sep 30, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment