Re: [tor-bugs] #26183 [Applications/Tor Launcher]: Close control connection (socket and io.streams) on failure

2018-05-24 Thread Tor Bug Tracker & Wiki
#26183: Close control connection (socket and io.streams) on failure
---+-
 Reporter:  cypherpunks|  Owner:  brade
 Type:  defect | Status:  closed
 Priority:  Medium |  Milestone:
Component:  Applications/Tor Launcher  |Version:
 Severity:  Normal | Resolution:  invalid
 Keywords: |  Actual Points:
Parent ID: | Points:
 Reviewer: |Sponsor:
---+-
Changes (by cypherpunks):

 * status:  new => closed
 * resolution:   => invalid


Comment:

 Socket and streams will be garbage collected later which will close
 everything if there is no reference.

--
Ticket URL: 
Tor Bug Tracker & Wiki 
The Tor Project: anonymity online
___
tor-bugs mailing list
tor-bugs@lists.torproject.org
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-bugs

Re: [tor-bugs] #26183 [Applications/Tor Launcher]: Close control connection (socket and io.streams) on failure

2018-05-24 Thread Tor Bug Tracker & Wiki
#26183: Close control connection (socket and io.streams) on failure
---+---
 Reporter:  cypherpunks|  Owner:  brade
 Type:  defect | Status:  new
 Priority:  Medium |  Milestone:
Component:  Applications/Tor Launcher  |Version:
 Severity:  Normal | Resolution:
 Keywords: |  Actual Points:
Parent ID: | Points:
 Reviewer: |Sponsor:
---+---

Comment (by cypherpunks):

 {{{
 catch(e)
 {
   TorLauncherLogger.safelog(4,
  "failed to open authenticated connection: ",
 e);
 + if (conn)
 +   this._closeConnection(conn);
   return null;
 }
 }}}
 {{{
   if (!this.TorCommandSucceeded(reply))
   {
 TorLauncherLogger.log(4, "authenticate failed");
 +   this._closeConnection(conn);
 return null;
   }
 }}}

--
Ticket URL: 
Tor Bug Tracker & Wiki 
The Tor Project: anonymity online
___
tor-bugs mailing list
tor-bugs@lists.torproject.org
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-bugs

[tor-bugs] #26183 [Applications/Tor Launcher]: Close control connection (socket and io.streams) on failure

2018-05-24 Thread Tor Bug Tracker & Wiki
#26183: Close control connection (socket and io.streams) on failure
---+---
 Reporter:  cypherpunks|  Owner:  brade
 Type:  defect | Status:  new
 Priority:  Medium |  Milestone:
Component:  Applications/Tor Launcher  |Version:
 Severity:  Normal |   Keywords:
Actual Points: |  Parent ID:
   Points: |   Reviewer:
  Sponsor: |
---+---
 `_openAuthenticatedConnection` returns `null` connection on failure while
 keeping socket and io.streams open.
 It fails if can't to connect to control port or `authenticate failed`.

 Example log for refused connection:
 {{{
 TorLauncher DBUG: Opening control connection to 127.0.0.1:9151
 TorLauncher DBUG: Sending Tor command: AUTHENTICATE
 5d3a59467366772f65463d6874786b4f
 TorLauncher NOTE: failed to open authenticated connection: [Exception...
 "Component returned failure code: 0x804b000d (NS_ERROR_CONNECTION_REFUSED)
 [nsIBinaryOutputStream.writeBytes]"  nsresult: "0x804b000d
 (NS_ERROR_CONNECTION_REFUSED)"  location: "JS frame :: jar:file:///path
 /tor-browser/Browser/TorBrowser/Data/Browser/profile.default/extensions
 /tor-launc...@torproject.org.xpi!/components/tl-protocol.js ::
 TorProtocolService.prototype._sendCommand :: line 889"  data: no]
 }}}

 About dozen connections in case of very slow starting Tor.

--
Ticket URL: 
Tor Bug Tracker & Wiki 
The Tor Project: anonymity online
___
tor-bugs mailing list
tor-bugs@lists.torproject.org
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-bugs