Opened 6 years ago

Closed 3 years ago

#9694 closed defect (worksforme)

tor hangs if network interrupted while "Bootstrapped 85%: Finishing handshake with first hop."

Reported by: cypherpunks Owned by:
Priority: Medium Milestone: Tor: unspecified
Component: Core Tor/Tor Version: Tor: unspecified
Severity: Normal Keywords: tor-client, tor-03-unspecified-201612
Cc: Actual Points:
Parent ID: Points:
Reviewer: Sponsor:

Description

Version: 0.2.4.17-rc-1~d70.wheezy+1

Tor gets stuck in a state where it is logging nothing and the init script cannot kill it. Had to kill -9.

arm also hangs when trying to connect it in this state.

The cause is the network (wifi in my case) becoming disconnected while "finishing handshake with first hop".

My first attempt at reproducing this failed, but the second one succeeded.

Sep 07 18:55:49.000 [notice] Tor 0.2.4.17-rc (git-36eb3e0da4c3a821) opening log file.
Sep 07 18:55:49.000 [notice] Parsing GEOIP IPv4 file /usr/share/tor/geoip.
Sep 07 18:55:52.000 [notice] We now have enough directory information to build circuits.
Sep 07 18:55:52.000 [notice] Bootstrapped 80%: Connecting to the Tor network.
Sep 07 18:55:53.000 [notice] Bootstrapped 85%: Finishing handshake with first hop.
Sep 07 18:55:53.000 [warn] Socks version 22 not recognized. (Tor is not an http proxy.)
Sep 07 18:55:53.000 [warn] Fetching socks handshake failed. Closing.
Sep 07 18:55:53.000 [warn] Socks version 22 not recognized. (Tor is not an http proxy.)
Sep 07 18:55:53.000 [warn] Fetching socks handshake failed. Closing.
Sep 07 18:55:54.000 [warn] Socks version 22 not recognized. (Tor is not an http proxy.)
Sep 07 18:55:54.000 [warn] Fetching socks handshake failed. Closing.
Sep 07 18:55:55.000 [warn] Socks version 22 not recognized. (Tor is not an http proxy.)
Sep 07 18:55:55.000 [warn] Fetching socks handshake failed. Closing.
Sep 07 18:55:56.000 [warn] Socks version 22 not recognized. (Tor is not an http proxy.)
Sep 07 18:55:56.000 [warn] Fetching socks handshake failed. Closing.
Sep 07 18:55:57.000 [warn] Socks version 22 not recognized. (Tor is not an http proxy.)
Sep 07 18:55:57.000 [warn] Fetching socks handshake failed. Closing.
Sep 07 18:55:58.000 [warn] Socks version 22 not recognized. (Tor is not an http proxy.)
Sep 07 18:55:58.000 [warn] Fetching socks handshake failed. Closing.
Sep 07 18:55:58.000 [warn] Socks version 22 not recognized. (Tor is not an http proxy.)
Sep 07 18:55:58.000 [warn] Fetching socks handshake failed. Closing.
Sep 07 18:55:58.000 [warn] Socks version 22 not recognized. (Tor is not an http proxy.)
Sep 07 18:55:58.000 [warn] Fetching socks handshake failed. Closing.
Sep 07 18:55:59.000 [warn] Socks version 22 not recognized. (Tor is not an http proxy.)
Sep 07 18:55:59.000 [warn] Fetching socks handshake failed. Closing.
Sep 07 18:55:59.000 [warn] Problem bootstrapping. Stuck at 85%: Finishing handshake with first hop. (DONE; DONE; count 10; recommendation warn)
Sep 07 18:55:59.000 [warn] 10 connections have failed:
Sep 07 18:55:59.000 [warn]  10 connections died in state handshaking (TLS) with SSL state unknown state in HANDSHAKE
Sep 07 18:56:00.000 [warn] Socks version 22 not recognized. (Tor is not an http proxy.)
Sep 07 18:56:00.000 [warn] Fetching socks handshake failed. Closing.
Sep 07 18:56:00.000 [warn] Problem bootstrapping. Stuck at 85%: Finishing handshake with first hop. (DONE; DONE; count 11; recommendation warn)
Sep 07 18:56:00.000 [warn] 11 connections have failed:
Sep 07 18:56:00.000 [warn]  11 connections died in state handshaking (TLS) with SSL state unknown state in HANDSHAKE
Sep 07 18:56:00.000 [warn] Socks version 22 not recognized. (Tor is not an http proxy.)
Sep 07 18:56:00.000 [warn] Fetching socks handshake failed. Closing.
Sep 07 18:56:00.000 [warn] Problem bootstrapping. Stuck at 85%: Finishing handshake with first hop. (DONE; DONE; count 12; recommendation warn)
Sep 07 18:56:00.000 [warn] 12 connections have failed:

(I have no idea what is causing the "SOCKS Version 22" lines, I don't usually get those.)

Child Tickets

Change History (6)

comment:1 Changed 6 years ago by cypherpunks

sorry, didn't include the whole log. it continued with more of the same and finally ended with this (and hung for several minutes until I killed it):

Sep 07 18:56:20.000 [warn]  36 connections died in state handshaking (TLS) with SSL state unknown state in HANDSHAKE
Sep 07 18:56:21.000 [warn] Socks version 22 not recognized. (Tor is not an http proxy.)
Sep 07 18:56:21.000 [warn] Fetching socks handshake failed. Closing.
Sep 07 18:56:21.000 [warn] Problem bootstrapping. Stuck at 85%: Finishing handshake with first hop. (DONE; DONE; count 37; recommendation warn)
Sep 07 18:56:21.000 [warn] 37 connections have failed:
Sep 07 18:56:21.000 [warn]  37 connections died in state handshaking (TLS) with SSL state unknown state in HANDSHAKE
Sep 07 18:56:21.000 [notice] New control connection opened.
Sep 07 18:56:22.000 [warn] Socks version 22 not recognized. (Tor is not an http proxy.)
Sep 07 18:56:22.000 [warn] Fetching socks handshake failed. Closing.
Sep 07 18:56:22.000 [warn] Problem bootstrapping. Stuck at 85%: Finishing handshake with first hop. (DONE; DONE; count 38; recommendation warn)
Sep 07 18:56:22.000 [warn] 38 connections have failed:
Sep 07 18:56:22.000 [warn]  38 connections died in state handshaking (TLS) with SSL state unknown state in HANDSHAKE

comment:2 Changed 6 years ago by nickm

Component: - Select a componentTor
Keywords: tor-client added
Milestone: Tor: 0.2.5.x-final
Status: newneeds_information

Somebody should reproduce this while running Tor in a debugger and see where it hangs.

Incidentally, "Socks version 22 not recognized" suggests tha some program is trying to talk to your SockPort, but isn't actually speaking SOCKS.

comment:3 Changed 6 years ago by nickm

Milestone: Tor: 0.2.5.x-finalTor: 0.2.???

comment:4 Changed 3 years ago by teor

Milestone: Tor: 0.2.???Tor: 0.3.???

Milestone renamed

comment:5 Changed 3 years ago by nickm

Keywords: tor-03-unspecified-201612 added
Milestone: Tor: 0.3.???Tor: unspecified

Finally admitting that 0.3.??? was a euphemism for Tor: unspecified all along.

comment:6 Changed 3 years ago by nickm

Resolution: worksforme
Severity: Normal
Status: needs_informationclosed
Note: See TracTickets for help on using tickets.