Skip to content

Group 40 Test 40: Max Priority Overflow #103

@michaelatremblay

Description

@michaelatremblay

The priority of the OFPT_FLOW_MODs generated in this test increments every time a new Flow Mod is sent. This is a problem, however, because the maximum priority value is 65535, and there does not appear to be a limit on the max_entries field. Since this test is trying to max out the table, it is possible for more than 65535 Flow Mods to be sent. The way this test is set up, it crashes when it tries to send the 65536th Flow Mod.

The error that occurs in this scenario is below.


runTest (testgroup40.Grp40No40) ... ERROR

ERROR: runTest (testgroup40.Grp40No40)

Traceback (most recent call last):
File "/root/oftest-1.0.0/tests/testgroup40.py", line 226, in runTest
rv = self.controller.message_send(flowmod)
File "/root/oftest-1.0.0/src/python/oftest/controller.py", line 601, in message_send
outpkt = msg.pack()
File "/root/oftest-1.0.0/src/python/oftest/message.py", line 879, in pack
packed += ofp_flow_mod.pack(self)
File "/root/oftest-1.0.0/src/python/oftest/cstruct.py", line 3408, in pack
packed += struct.pack("!QHHHHLHH", self.cookie, self.command, self.idle_timeout, self.hard_timeout, self.priority, self.buffer_id, self.out_port, self.flags)
error: 'H' format requires 0 <= number <= 65535

Ran 1 test in 4193.282s

FAILED (errors=1)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions