Opened 9 years ago

Closed 9 years ago

#1799 closed defect (fixed)

arm chokes on tabs when used in ExitPolicy lines

Reported by: atagar Owned by: atagar
Priority: Medium Milestone:
Component: Core Tor/Nyx Version:
Severity: Keywords:
Cc: Actual Points:
Parent ID: Points:
Reviewer: Sponsor:

Description (last modified by atagar)

voidzero reports that tabs in the ExitPolicy lines causes a variety of gremlins when determining the exit policy. This includes display issues when parsing the torrc and a crashing issue in the connection panel:

  1. Traceback (most recent call last):
  2. File "init/starter.py", line 178, in <module>
  3. interface.controller.startTorMonitor(expandedEvents, paramstartup.blindModeEnabled?)
  4. File "/home/void/user/arm/interface/controller.py", line 1287, in startTorMonitor
  5. curses.wrapper(drawTorMonitor, loggedEvents, isBlindMode)
  6. File "/usr/lib/python2.6/curses/wrapper.py", line 44, in wrapper
  7. return func(stdscr, *args, kwds)
  8. File "/home/void/user/arm/interface/controller.py", line 377, in drawTorMonitor
  9. panelsconn? = connPanel.ConnPanel(stdscr, conn, isBlindMode)
  1. File "/home/void/user/arm/interface/connPanel.py", line 170, in init
  2. self.reset()
  3. File "/home/void/user/arm/interface/connPanel.py", line 336, in reset
  4. if SCRUB_PRIVATE_DATA and fIp not in self.fingerprintMappings.keys(): isPrivate = isExitAllowed(fIp, fPort, self.exitPolicy, self.exitRejectPrivate)
  5. File "/home/void/user/arm/interface/connPanel.py", line 893, in isExitAllowed
  6. maxPort = int(entryPort[entryPort.find("-") + 1:])
  7. ValueError: invalid literal for int() with base 10: '22"'

Child Tickets

Change History (2)

comment:1 Changed 9 years ago by atagar

Description: modified (diff)

comment:2 Changed 9 years ago by atagar

Resolution: fixed
Status: newclosed

Checked in a patch that addresses the display issue in the config, the validation matching error, the crashing issue in the connection panel, and another (more severe) issue with exit policy parsing it uncovered. Never knew tabs could cause so much destruction...

Note: See TracTickets for help on using tickets.