Prefix matrix crashes when viewing IPv6 scope

Bug #562242 reported by Morten Brekkevold
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Network Administration Visualized
Fix Released
Medium
Morten Brekkevold

Bug Description

When attempting to view our IPv6 scope (2001:700:1:/48) in the Prefix Matrix under NAV 3.5.5, the page crashes with the following traceback:

MOD_PYTHON ERROR

ProcessId: 541
Interpreter: 'nav.uninett.no'

ServerName: 'nav.uninett.no'
DocumentRoot: '/usr/share/nav/htdocs'

URI: '/report/matrix'
Location: None
Directory: '/usr/share/nav/htdocs/report/'
Filename: '/usr/share/nav/htdocs/report/matrix'
PathInfo: ''

Phase: 'PythonHandler'
Handler: 'nav.web.report.handler'

Traceback (most recent call last):

  File "/usr/lib/python2.5/site-packages/mod_python/importer.py", line 1537, in HandlerDispatch
    default=default_handler, arg=req, silent=hlist.silent)

  File "/usr/lib/python2.5/site-packages/mod_python/importer.py", line 1229, in _process_target
    result = _execute_target(config, req, object, arg)

  File "/usr/lib/python2.5/site-packages/mod_python/importer.py", line 1128, in _execute_target
    result = object(arg)

  File "/var/lib/python-support/python2.5/nav/web/report/handler.py", line 167, in handler
    matrix = MatrixIPv6(scope,end_net=end_net)

  File "/var/lib/python-support/python2.5/nav/report/matrixIPv6.py", line 45, in __init__
    Matrix.__init__(self,start_net,end_net=end_net,bits_in_matrix=4)

  File "/var/lib/python-support/python2.5/nav/report/matrix.py", line 50, in __init__
    self.tree = buildTree(start_net, end_net, bits_in_matrix=bits_in_matrix, add_missing_nets=True)

  File "/var/lib/python-support/python2.5/nav/report/IPtree.py", line 71, in buildTree
    supernet = andIpMask(ip,mask)

  File "/var/lib/python-support/python2.5/nav/report/IPtools.py", line 197, in andIpMask
    return _ipv6_andIpMask(ip,mask)

  File "/var/lib/python-support/python2.5/nav/report/IPtools.py", line 206, in _ipv6_andIpMask
    assert len(ip_split) == len(mask_split) == 8

AssertionError

Changed in nav:
assignee: nobody → Jørgen Abrahamsen (jorabra)
Changed in nav:
assignee: Jørgen Abrahamsen (jorabra) → nobody
Changed in nav:
milestone: 3.5.7 → 3.7.2
Changed in nav:
milestone: 3.7.2 → 3.7.3
Changed in nav:
assignee: nobody → Morten Brekkevold (mbrekkevold)
status: Confirmed → In Progress
Revision history for this message
Morten Brekkevold (mbrekkevold) wrote :

fix committed here: http://metanav.uninett.no/hg/series/3.7.x/rev/d62d602ba5e3

The failing assertion could only ever have worked when all IPv6 addresses could not be shortened to less than 8 hex groups - really surprised that issue wasn't discovered immediately after the IPv6 functionality was introduced.

Changed in nav:
status: In Progress → Fix Committed
Changed in nav:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers