Opened 6 years ago

Closed 5 years ago

#10431 closed defect (fixed)

bad bridge fingerprint causes "DONE" error to be displayed

Reported by: mcs Owned by: nickm
Priority: Medium Milestone: Tor: 0.2.5.x-final
Component: Core Tor/Tor Version:
Severity: Keywords: 025-triaged tor-client
Cc: brade, nickm Actual Points:
Parent ID: Points:
Reviewer: Sponsor:

Description

If a bridge with a bad fingerprint is configured, Tor Launcher displays an error alert that looks like:

+---------------------------------------------------+
| Tor Launcher                                      |
|                                                   |
| Tor failed to establish a Tor network connection. |
|                                                   |
| DONE                                              |
+---------------------------------------------------+

"DONE" is supposed to be a detailed error, as reported by tor.

Enter this in Tor Launcher's bridge relay text field to reproduce the problem:
141.201.27.48:443 4352e58420e68f5e40bf7c74faddccd9d1349413

The tor log shows:

12/18/13 15:42:23.240 [NOTICE] Bootstrapped 5%: Connecting to directory server.
12/18/13 15:42:23.171 [NOTICE] Bootstrapped 10%: Finishing handshake with directory server.
12/18/13 15:42:23.612 [WARN] Tried connecting to router at 141.201.27.48:443, but identity key was not as expected: wanted 4352E58420E68F5E40BF7C74FADDCCD9D1349413 but got 07D95FB8B80BE277DFA31559F96A85C3BDEAE1E7.
12/18/13 15:42:23.613 [WARN] Problem bootstrapping. Stuck at 10%: Finishing handshake with directory server. (DONE; DONE; count 2; recommendation warn)

Maybe tor is actually reporting "DONE" as the error message?

Child Tickets

Change History (9)

comment:1 Changed 6 years ago by arma

Cc: nickm added

I also think this is a Tor bug

comment:2 in reply to:  1 Changed 6 years ago by mcs

Replying to arma:

I also think this is a Tor bug

OK. Here are the bootstrap status event messages:

650 STATUS_CLIENT WARN BOOTSTRAP PROGRESS=10 TAG=handshake_dir SUMMARY="Finishin
g handshake with directory server" WARNING="Unexpected identity in router certif
icate" REASON=IDENTITY COUNT=4 RECOMMENDATION=ignore

650 STATUS_CLIENT WARN BOOTSTRAP PROGRESS=10 TAG=handshake_dir SUMMARY="Finishing handshake with directory server" WARNING="DONE" REASON=DONE COUNT=5 RECOMMENDATION=warn

comment:3 Changed 6 years ago by mcs

Component: Tor LauncherTor

comment:4 Changed 6 years ago by nickm

Milestone: Tor: 0.2.4.x-final

Hm. That's interesting. IMO, the problem is in the places where we're doing

    control_event_bootstrap_problem(
                orconn_end_reason_to_control_string(reason), reason);

The output of orconn_end_reason is just plain not human readable. If WARNING is meant to be human readable, it shouldn't be getting fed in there. Thoughts?

Also, the UI should probably report the summary line as well.

comment:5 in reply to:  4 Changed 6 years ago by brade

Owner: changed from brade to nickm
Status: newassigned

Replying to nickm:

Also, the UI should probably report the summary line as well.

We will take care of that (for Tor Launcher) in #10604. Reassigning this bug to you Nick.

comment:6 Changed 6 years ago by nickm

Milestone: Tor: 0.2.4.x-finalTor: 0.2.5.x-final

Looking more deeply, this is going to take some changes in how we handle tls_error_to_orconn_end_reason(). We can have a connection die for things other than TLS errors, and we should treat DONE as not being a TLS error too.

comment:7 Changed 5 years ago by nickm

Keywords: 025-triaged tor-client added
Status: assignedneeds_review

Possible fix in branch "bug10431". Less hard than I expected: the real fix is to not report a bootstrap problem on a connection if we have earlier reported another bootstrap problem on that connection.

comment:8 Changed 5 years ago by andrea

I think this is an obvious win and should be merged.

comment:9 Changed 5 years ago by nickm

Resolution: fixed
Status: needs_reviewclosed

Merged to master.

Note: See TracTickets for help on using tickets.