Your message dated Sun, 18 Feb 2018 11:17:32 +0100
with message-id <20180218101732.GA6153@bogus>
and subject line Re: Bug#785414: tor-arm: arm fails to start on IPv6-enabled 
relay with "ExitPolicy reject6" torrc configuration
has caused the Debian Bug report #785414,
regarding tor-arm: arm fails to start on IPv6-enabled relay with "ExitPolicy 
reject6" torrc configuration
to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact [email protected]
immediately.)


-- 
785414: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=785414
Debian Bug Tracking System
Contact [email protected] with problems
--- Begin Message ---
Package: tor-arm
Version: 1.4.5.0-1
Severity: normal
Tags: patch

Suppose /etc/tor/torrc has the following line:

  ExitPolicy reject6 [2601::/20]:*

Then tor-arm will fail to start:

  $ sudo -u debian-tor arm
  Traceback (most recent call last):
    File "/usr/share/arm/starter.py", line 534, in <module>
      controller.init(conn)
    File "/usr/share/arm/util/torTools.py", line 670, in init
      self._exitPolicyChecker = self.getExitPolicy()
    File "/usr/share/arm/util/torTools.py", line 1345, in getExitPolicy
      result = ExitPolicy(entry, result)
    File "/usr/share/arm/util/torTools.py", line 2611, in __init__
      self.ipAddressBin += "".join([str((int(octet) >> y) & 1) for y in 
range(7, -1, -1)])
    ValueError: invalid literal for int() with base 10: '[2601'

Attached is a dumb patch which simply ignores reject6 so that tor-arm
can continue to start.

tor-arm seems to work fine with other bits of configuration in torrc
containing IPv6 addresses, particularly ORPort, so it's just ExitPolicy
parsing that is the problem.

-- System Information:
Debian Release: 8.0
  APT prefers stable
  APT policy: (500, 'stable')
Architecture: amd64 (x86_64)

Kernel: Linux 3.16.0-4-amd64 (SMP w/4 CPU cores)
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)

Versions of packages tor-arm depends on:
ii  python         2.7.9-1
ii  python-torctl  20130920git-2

tor-arm recommends no packages.

Versions of packages tor-arm suggests:
ii  tor  0.2.5.12-1

-- no debconf information

-- 
Gerald Turner <[email protected]>        Encrypted mail preferred!
OpenPGP: 4096R / CA89 B27A 30FA 66C5 1B80  3858 EC94 2276 FDB8 716D
Description: Work-around startup failure for IPv6-enabled relays having "ExitPolicy reject6" torrc configuration
Author: Gerald Turner <[email protected]>

--- tor-arm-1.4.5.0.orig/src/util/torTools.py
+++ tor-arm-1.4.5.0/src/util/torTools.py
@@ -1342,6 +1342,8 @@ class Controller(TorCtl.PostEventListene
         policyEntries.reverse()
         
         for entry in policyEntries:
+          if entry.startswith("reject6"):
+            continue
           result = ExitPolicy(entry, result)
         
         # Checks if we are rejecting private connections. If set, this appends

Attachment: signature.asc
Description: PGP signature


--- End Message ---
--- Begin Message ---
This was fixed in stem:

  https://gitweb.torproject.org/stem.git/commit/?id=e4800b0

On Wed, May 27, 2015 at 02:20:02PM -0300, Dererk wrote:
> tags 785414 +confirmed +upstream
> thanks
> 
> On 15/05/15 20:27, Gerald Turner wrote:
> > Package: tor-arm
> > Version: 1.4.5.0-1
> > Severity: normal
> > Tags: patch
> >
> > Suppose /etc/tor/torrc has the following line:
> >
> >   ExitPolicy reject6 [2601::/20]:*
> >
> > Then tor-arm will fail to start:
> >
> >   $ sudo -u debian-tor arm
> >   Traceback (most recent call last):
> >     File "/usr/share/arm/starter.py", line 534, in <module>
> >       controller.init(conn)
> >     File "/usr/share/arm/util/torTools.py", line 670, in init
> >       self._exitPolicyChecker = self.getExitPolicy()
> >     File "/usr/share/arm/util/torTools.py", line 1345, in getExitPolicy
> >       result = ExitPolicy(entry, result)
> >     File "/usr/share/arm/util/torTools.py", line 2611, in __init__
> >       self.ipAddressBin += "".join([str((int(octet) >> y) & 1) for y in 
> > range(7, -1, -1)])
> >     ValueError: invalid literal for int() with base 10: '[2601'
> >
> > Attached is a dumb patch which simply ignores reject6 so that tor-arm
> > can continue to start.
> >
> > tor-arm seems to work fine with other bits of configuration in torrc
> > containing IPv6 addresses, particularly ORPort, so it's just ExitPolicy
> > parsing that is the problem.
> >
> > -- System Information:
> > Debian Release: 8.0
> >   APT prefers stable
> >   APT policy: (500, 'stable')
> > Architecture: amd64 (x86_64)
> >
> > Kernel: Linux 3.16.0-4-amd64 (SMP w/4 CPU cores)
> > Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8)
> > Shell: /bin/sh linked to /bin/dash
> > Init: systemd (via /run/systemd/system)
> >
> > Versions of packages tor-arm depends on:
> > ii  python         2.7.9-1
> > ii  python-torctl  20130920git-2
> >
> > tor-arm recommends no packages.
> >
> > Versions of packages tor-arm suggests:
> > ii  tor  0.2.5.12-1
> >
> > -- no debconf information
> 
> Hi Gerald!
> 
> This is upstream report on the issue here
> https://trac.torproject.org/projects/tor/ticket/16053
> 
> 
> Cheers,
> 
> Dererk
> 
> -- 
> BOFH excuse #231:
> We had to turn off that service to comply with the CDA Bill.
> 
> 


Attachment: signature.asc
Description: PGP signature


--- End Message ---

Reply via email to