test tool: add default test files (action with set-field only)

What this patch implements:

    This patch implements the test files for the test tool.
    These test files aim to examine 'set-field action' of FlowMod message.

Signed-off-by: WATANABE Fumitaka <watanabe.fumitaka@nttcom.co.jp>
Signed-off-by: Yuichi Ito <ito.yuichi0@gmail.com>
Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
This commit is contained in:
Yuichi Ito 2013-12-11 17:15:57 +09:00 committed by FUJITA Tomonori
parent 4b7da3a369
commit 40e88be11e
45 changed files with 13853 additions and 0 deletions

View File

@ -0,0 +1,187 @@
[
"action: set_field: 03_ETH_DST",
{
"description": "ethernet(dst='22:22:22:22:22:22')/ipv4/tcp-->'eth_dst=22:22:22:22:22:22,actions=set_field:bb:bb:bb:bb:bb:bb->eth_dst,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_dst",
"value":"22:22:22:22:22:22"
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"eth_dst",
"value":"bb:bb:bb:bb:bb:bb"
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2048)",
"ipv4(tos=32, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='bb:bb:bb:bb:bb:bb', src='11:11:11:11:11:11', ethertype=2048)",
"ipv4(tos=32, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet(dst='22:22:22:22:22:22')/ipv6/tcp-->'eth_dst=22:22:22:22:22:22,actions=set_field:bb:bb:bb:bb:bb:bb->eth_dst,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_dst",
"value":"22:22:22:22:22:22"
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"eth_dst",
"value":"bb:bb:bb:bb:bb:bb"
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='bb:bb:bb:bb:bb:bb', src='11:11:11:11:11:11', ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet(dst='22:22:22:22:22:22')/arp-->'eth_dst=22:22:22:22:22:22,actions=set_field:bb:bb:bb:bb:bb:bb->eth_dst,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_dst",
"value":"22:22:22:22:22:22"
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"eth_dst",
"value":"bb:bb:bb:bb:bb:bb"
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2054)",
"arp(dst_ip='192.168.20.20',dst_mac='22:22:22:22:22:22', opcode=1, src_ip='192.168.10.10',src_mac='11:11:11:11:11:11')",
"'\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00'"
],
"egress":[
"ethernet(dst='bb:bb:bb:bb:bb:bb', src='11:11:11:11:11:11', ethertype=2054)",
"arp(dst_ip='192.168.20.20',dst_mac='22:22:22:22:22:22', opcode=1, src_ip='192.168.10.10',src_mac='11:11:11:11:11:11')",
"'\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00'"
]
}
]
}
]

View File

@ -0,0 +1,187 @@
[
"action: set_field: 04_ETH_SRC",
{
"description": "ethernet(src='22:22:22:22:22:22')/ipv4/tcp-->'eth_src=22:22:22:22:22:22,actions=set_field:bb:bb:bb:bb:bb:bb->eth_src,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_src",
"value":"11:11:11:11:11:11"
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"eth_src",
"value":"aa:aa:aa:aa:aa:aa"
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2048)",
"ipv4(tos=32, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='aa:aa:aa:aa:aa:aa', ethertype=2048)",
"ipv4(tos=32, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet(src='22:22:22:22:22:22')/ipv6/tcp-->'eth_src=22:22:22:22:22:22,actions=set_field:bb:bb:bb:bb:bb:bb->eth_src,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_src",
"value":"11:11:11:11:11:11"
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"eth_src",
"value":"aa:aa:aa:aa:aa:aa"
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='aa:aa:aa:aa:aa:aa', ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet(src='22:22:22:22:22:22')/arp-->'eth_src=22:22:22:22:22:22,actions=set_field:bb:bb:bb:bb:bb:bb->eth_src,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_src",
"value":"11:11:11:11:11:11"
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"eth_src",
"value":"aa:aa:aa:aa:aa:aa"
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2054)",
"arp(dst_ip='192.168.20.20',dst_mac='22:22:22:22:22:22', opcode=1, src_ip='192.168.10.10',src_mac='11:11:11:11:11:11')",
"'\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='aa:aa:aa:aa:aa:aa', ethertype=2054)",
"arp(dst_ip='192.168.20.20',dst_mac='22:22:22:22:22:22', opcode=1, src_ip='192.168.10.10',src_mac='11:11:11:11:11:11')",
"'\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00'"
]
}
]
}
]

View File

@ -0,0 +1,187 @@
[
"action: set_field: 05_ETH_TYPE",
{
"description": "ethernet(ethertype=0x0800)/ipv4/tcp-->'eth_type=0x0800,actions=set_field:0x8848->eth_type,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2048
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"eth_type",
"value":34888
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2048)",
"ipv4(tos=32, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34888)",
"ipv4(tos=32, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet(ethertype=0x86dd)/ipv6/tcp-->'eth_type=0x86dd,actions=set_field:0x8848->eth_type,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"eth_type",
"value":34888
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34888)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet(ethertype=0x0806)/arp-->'eth_type=0x0806,actions=set_field:0x8848->eth_type,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2054
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"eth_type",
"value":34888
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2054)",
"arp(dst_ip='192.168.20.20',dst_mac='22:22:22:22:22:22', opcode=1, src_ip='192.168.10.10',src_mac='11:11:11:11:11:11')",
"'\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34888)",
"arp(dst_ip='192.168.20.20',dst_mac='22:22:22:22:22:22', opcode=1, src_ip='192.168.10.10',src_mac='11:11:11:11:11:11')",
"'\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00'"
]
}
]
}
]

View File

@ -0,0 +1,193 @@
[
"action: set_field: 06_VLAN_VID",
{
"description": "ethernet/vlan(vid=100)/ipv4/tcp-->'vlan_vid=100,actions=set_field:203->vlan_vid,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"vlan_vid",
"value":4196
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"vlan_vid",
"value":4299
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2048)",
"ipv4(tos=32, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=203, ethertype=2048)",
"ipv4(tos=32, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/vlan(vid=100)/ipv6/tcp-->'vlan_vid=100,actions=set_field:203->vlan_vid,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"vlan_vid",
"value":4196
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"vlan_vid",
"value":4299
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=203, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/vlan(vid=100)/arp-->'vlan_vid=100,actions=set_field:203->vlan_vid,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"vlan_vid",
"value":4196
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"vlan_vid",
"value":4299
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2054)",
"arp(dst_ip='192.168.20.20',dst_mac='22:22:22:22:22:22', opcode=1, src_ip='192.168.10.10',src_mac='11:11:11:11:11:11')",
"'\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=203, ethertype=2054)",
"arp(dst_ip='192.168.20.20',dst_mac='22:22:22:22:22:22', opcode=1, src_ip='192.168.10.10',src_mac='11:11:11:11:11:11')",
"'\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00'"
]
}
]
}
]

View File

@ -0,0 +1,211 @@
[
"action: set_field: 07_VLAN_PCP",
{
"description": "ethernet/vlan(pcp=3)/ipv4/tcp-->'vlan_pcp=3,actions=set_field:5->vlan_pcp,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"vlan_vid",
"value":4196
}
},
{
"OXMTlv":{
"field":"vlan_pcp",
"value":3
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"vlan_pcp",
"value":5
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2048)",
"ipv4(tos=32, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=5, cfi=0, vid=100, ethertype=2048)",
"ipv4(tos=32, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/vlan(pcp=3)/ipv6/tcp-->'vlan_pcp=3,actions=set_field:5->vlan_pcp,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"vlan_vid",
"value":4196
}
},
{
"OXMTlv":{
"field":"vlan_pcp",
"value":3
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"vlan_pcp",
"value":5
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=5, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/vlan(pcp=3)/arp-->'vlan_pcp=3,actions=set_field:5->vlan_pcp,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"vlan_vid",
"value":4196
}
},
{
"OXMTlv":{
"field":"vlan_pcp",
"value":3
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"vlan_pcp",
"value":5
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2054)",
"arp(dst_ip='192.168.20.20',dst_mac='22:22:22:22:22:22', opcode=1, src_ip='192.168.10.10',src_mac='11:11:11:11:11:11')",
"'\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=5, cfi=0, vid=100, ethertype=2054)",
"arp(dst_ip='192.168.20.20',dst_mac='22:22:22:22:22:22', opcode=1, src_ip='192.168.10.10',src_mac='11:11:11:11:11:11')",
"'\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00'"
]
}
]
}
]

View File

@ -0,0 +1,324 @@
[
"action: set_field: 08_IP_DSCP (IPv4)",
{
"description": "ethernet/ipv4(tos=32)/tcp-->'ip_dscp=8,actions=set_field:16->ip_dscp,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2048
}
},
{
"OXMTlv":{
"field":"ip_dscp",
"value":8
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"ip_dscp",
"value":16
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2048)",
"ipv4(tos=32, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2048)",
"ipv4(tos=64, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/vlan/ipv4(tos=32)/tcp-->'ip_dscp=8,actions=set_field:16->ip_dscp,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2048
}
},
{
"OXMTlv":{
"field":"ip_dscp",
"value":8
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"ip_dscp",
"value":16
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2048)",
"ipv4(tos=32, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2048)",
"ipv4(tos=64, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/mpls/ipv4(tos=32)/tcp-->'actions=pop_mpls:0x0800,goto_table:1','table_id:1,ip_dscp=8,actions=set_field:16->ip_dscp,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34887
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionPopMpls":{
"ethertype":2048
}
}
],
"type":4
}
},
{
"OFPInstructionGotoTable":{
"table_id":1
}
}
]
}
},
{
"OFPFlowMod":{
"table_id":1,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2048
}
},
{
"OXMTlv":{
"field":"ip_dscp",
"value":8
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"ip_dscp",
"value":16
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34887)",
"mpls(bsb=1, label=100, exp=3, ttl=64)",
"ipv4(tos=32, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2048)",
"ipv4(tos=64, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/svlan/itag/ethernet/svlan/vlan/ipv4(tos=32)/tcp-->'ip_dscp=8,actions=set_field:16->ip_dscp,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2048
}
},
{
"OXMTlv":{
"field":"ip_dscp",
"value":8
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"ip_dscp",
"value":16
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2048)",
"ipv4(tos=32, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2048)",
"ipv4(tos=64, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
}
]

View File

@ -0,0 +1,324 @@
[
"action: set_field: 08_IP_DSCP (IPv6)",
{
"description": "ethernet/ipv6(traffic_class=32)/tcp-->'ip_dscp=8,actions=set_field:16->ip_dscp,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ip_dscp",
"value":8
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"ip_dscp",
"value":16
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/vlan/ipv6(traffic_class=32)/tcp-->'ip_dscp=8,actions=set_field:16->ip_dscp,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ip_dscp",
"value":8
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"ip_dscp",
"value":16
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/mpls/ipv6(traffic_class=32)/tcp-->'actions=pop_mpls:0x86dd,goto_table:1','table_id:1,ip_dscp=8,actions=set_field:16->ip_dscp,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34887
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionPopMpls":{
"ethertype":34525
}
}
],
"type":4
}
},
{
"OFPInstructionGotoTable":{
"table_id":1
}
}
]
}
},
{
"OFPFlowMod":{
"table_id":1,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ip_dscp",
"value":8
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"ip_dscp",
"value":16
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34887)",
"mpls(bsb=1, label=100, exp=3, ttl=64)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/svlan/itag/ethernet/svlan/vlan/ipv6(traffic_class=32)/tcp-->'ip_dscp=8,actions=set_field:16->ip_dscp,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ip_dscp",
"value":8
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"ip_dscp",
"value":16
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
}
]

View File

@ -0,0 +1,324 @@
[
"action: set_field: 09_IP_ECN (IPv4)",
{
"description": "ethernet/ipv4(tos=32)/tcp-->'ip_ecn=0,actions=set_field:1->ip_ecn,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2048
}
},
{
"OXMTlv":{
"field":"ip_ecn",
"value":0
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"ip_ecn",
"value":1
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2048)",
"ipv4(tos=32, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2048)",
"ipv4(tos=33, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/vlan/ipv4(tos=32)/tcp-->'ip_ecn=0,actions=set_field:1->ip_ecn,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2048
}
},
{
"OXMTlv":{
"field":"ip_ecn",
"value":0
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"ip_ecn",
"value":1
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2048)",
"ipv4(tos=32, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2048)",
"ipv4(tos=33, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/mpls/ipv4(tos=32)/tcp-->'actions=pop_mpls:0x0800,goto_table:1','table_id:1,ip_ecn=0,actions=set_field:1->ip_ecn,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34887
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionPopMpls":{
"ethertype":2048
}
}
],
"type":4
}
},
{
"OFPInstructionGotoTable":{
"table_id":1
}
}
]
}
},
{
"OFPFlowMod":{
"table_id":1,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2048
}
},
{
"OXMTlv":{
"field":"ip_ecn",
"value":0
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"ip_ecn",
"value":1
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34887)",
"mpls(bsb=1, label=100, exp=3, ttl=64)",
"ipv4(tos=32, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2048)",
"ipv4(tos=33, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/svlan/itag/ethernet/svlan/vlan/ipv4(tos=32)/tcp-->'ip_ecn=0,actions=set_field:1->ip_ecn,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2048
}
},
{
"OXMTlv":{
"field":"ip_ecn",
"value":0
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"ip_ecn",
"value":1
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2048)",
"ipv4(tos=32, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2048)",
"ipv4(tos=33, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
}
]

View File

@ -0,0 +1,324 @@
[
"action: set_field: 09_IP_ECN (IPv6)",
{
"description": "ethernet/ipv6(traffic_class=32)/tcp-->'ip_ecn=0,actions=set_field:1->ip_ecn,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ip_ecn",
"value":0
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"ip_ecn",
"value":1
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=33)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/vlan/ipv6(traffic_class=32)/tcp-->'ip_ecn=0,actions=set_field:1->ip_ecn,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ip_ecn",
"value":0
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"ip_ecn",
"value":1
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=33)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/mpls/ipv6(traffic_class=32)/tcp-->'actions=pop_mpls:0x86dd,goto_table:1','table_id:1,ip_ecn=0,actions=set_field:1->ip_ecn,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34887
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionPopMpls":{
"ethertype":34525
}
}
],
"type":4
}
},
{
"OFPInstructionGotoTable":{
"table_id":1
}
}
]
}
},
{
"OFPFlowMod":{
"table_id":1,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ip_ecn",
"value":0
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"ip_ecn",
"value":1
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34887)",
"mpls(bsb=1, label=100, exp=3, ttl=64)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=33)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/svlan/itag/ethernet/svlan/vlan/ipv6(traffic_class=32)/tcp-->'ip_ecn=0,actions=set_field:1->ip_ecn,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ip_ecn",
"value":0
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"ip_ecn",
"value":1
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=33)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
}
]

View File

@ -0,0 +1,324 @@
[
"action: set_field: 10_IP_PROTO (IPv4)",
{
"description": "ethernet/ipv4(proto=6)/tcp-->'ip_proto=6,actions=set_field:17->ip_proto,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2048
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":6
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"ip_proto",
"value":17
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2048)",
"ipv4(tos=32, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2048)",
"ipv4(tos=32, proto=17, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/vlan/ipv4(proto=6)/tcp-->'ip_proto=6,actions=set_field:17->ip_proto,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2048
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":6
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"ip_proto",
"value":17
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2048)",
"ipv4(tos=32, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2048)",
"ipv4(tos=32, proto=17, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/mpls/ipv4(proto=6)/tcp-->'actions=pop_mpls:0x0800,goto_table:1','table_id:1,ip_proto=6,actions=set_field:17->ip_proto,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34887
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionPopMpls":{
"ethertype":2048
}
}
],
"type":4
}
},
{
"OFPInstructionGotoTable":{
"table_id":1
}
}
]
}
},
{
"OFPFlowMod":{
"table_id":1,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2048
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":6
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"ip_proto",
"value":17
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34887)",
"mpls(bsb=1, label=100, exp=3, ttl=64)",
"ipv4(tos=32, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2048)",
"ipv4(tos=32, proto=17, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/svlan/itag/ethernet/svlan/vlan/ipv4(proto=6)/tcp-->'ip_proto=6,actions=set_field:17->ip_proto,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2048
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":6
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"ip_proto",
"value":17
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2048)",
"ipv4(tos=32, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2048)",
"ipv4(tos=32, proto=17, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
}
]

View File

@ -0,0 +1,324 @@
[
"action: set_field: 10_IP_PROTO (IPv6)",
{
"description": "ethernet/ipv6(nxt=6)/tcp-->'ip_proto=6,actions=set_field:17->ip_proto,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":6
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"ip_proto",
"value":17
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=17, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/vlan/ipv6(nxt=6)/tcp-->'ip_proto=6,actions=set_field:17->ip_proto,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":6
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"ip_proto",
"value":17
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=17, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/mpls/ipv6(nxt=6)/tcp-->'actions=pop_mpls:0x86dd,goto_table:1','table_id:1,ip_proto=6,actions=set_field:17->ip_proto,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34887
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionPopMpls":{
"ethertype":34525
}
}
],
"type":4
}
},
{
"OFPInstructionGotoTable":{
"table_id":1
}
}
]
}
},
{
"OFPFlowMod":{
"table_id":1,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":6
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"ip_proto",
"value":17
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34887)",
"mpls(bsb=1, label=100, exp=3, ttl=64)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=17, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/svlan/itag/ethernet/svlan/vlan/ipv6(nxt=6)/tcp-->'ip_proto=6,actions=set_field:17->ip_proto,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":6
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"ip_proto",
"value":17
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=17, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
}
]

View File

@ -0,0 +1,324 @@
[
"action: set_field: 11_IPV4_SRC",
{
"description": "ethernet/ipv4(src='192.168.10.10')/tcp-->'ipv4_src=192.168.10.10,actions=set_field:10.10.10.10->ipv4_src,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2048
}
},
{
"OXMTlv":{
"field":"ipv4_src",
"value":"192.168.10.10"
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"ipv4_src",
"value":"10.10.10.10"
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2048)",
"ipv4(tos=32, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2048)",
"ipv4(tos=32, proto=6, src='10.10.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/vlan/ipv4(src='192.168.10.10')/tcp-->'ipv4_src=192.168.10.10,actions=set_field:10.10.10.10->ipv4_src,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2048
}
},
{
"OXMTlv":{
"field":"ipv4_src",
"value":"192.168.10.10"
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"ipv4_src",
"value":"10.10.10.10"
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2048)",
"ipv4(tos=32, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2048)",
"ipv4(tos=32, proto=6, src='10.10.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/mpls/ipv4(src='192.168.10.10')/tcp-->'actions=pop_mpls:0x0800,goto_table:1','table_id:1,ipv4_src=192.168.10.10,actions=set_field:10.10.10.10->ipv4_src,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34887
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionPopMpls":{
"ethertype":2048
}
}
],
"type":4
}
},
{
"OFPInstructionGotoTable":{
"table_id":1
}
}
]
}
},
{
"OFPFlowMod":{
"table_id":1,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2048
}
},
{
"OXMTlv":{
"field":"ipv4_src",
"value":"192.168.10.10"
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"ipv4_src",
"value":"10.10.10.10"
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34887)",
"mpls(bsb=1, label=100, exp=3, ttl=64)",
"ipv4(tos=32, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2048)",
"ipv4(tos=32, proto=6, src='10.10.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/svlan/itag/ethernet/svlan/vlan/ipv4(src='192.168.10.10')/tcp-->'ipv4_src=192.168.10.10,actions=set_field:10.10.10.10->ipv4_src,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2048
}
},
{
"OXMTlv":{
"field":"ipv4_src",
"value":"192.168.10.10"
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"ipv4_src",
"value":"10.10.10.10"
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2048)",
"ipv4(tos=32, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2048)",
"ipv4(tos=32, proto=6, src='10.10.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
}
]

View File

@ -0,0 +1,324 @@
[
"action: set_field: 12_IPV4_DST",
{
"description": "ethernet/ipv4(dst='192.168.20.20')/tcp-->'ipv4_dst=192.168.20.20,actions=set_field:10.10.20.20->ipv4_dst,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2048
}
},
{
"OXMTlv":{
"field":"ipv4_dst",
"value":"192.168.20.20"
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"ipv4_dst",
"value":"10.10.20.20"
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2048)",
"ipv4(tos=32, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2048)",
"ipv4(tos=32, proto=6, src='192.168.10.10', dst='10.10.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/vlan/ipv4(dst='192.168.20.20')/tcp-->'ipv4_dst=192.168.20.20,actions=set_field:10.10.20.20->ipv4_dst,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2048
}
},
{
"OXMTlv":{
"field":"ipv4_dst",
"value":"192.168.20.20"
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"ipv4_dst",
"value":"10.10.20.20"
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2048)",
"ipv4(tos=32, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2048)",
"ipv4(tos=32, proto=6, src='192.168.10.10', dst='10.10.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/mpls/ipv4(dst='192.168.20.20')/tcp-->'actions=pop_mpls:0x0800,goto_table:1','table_id:1,ipv4_dst=192.168.20.20,actions=set_field:10.10.20.20->ipv4_dst,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34887
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionPopMpls":{
"ethertype":2048
}
}
],
"type":4
}
},
{
"OFPInstructionGotoTable":{
"table_id":1
}
}
]
}
},
{
"OFPFlowMod":{
"table_id":1,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2048
}
},
{
"OXMTlv":{
"field":"ipv4_dst",
"value":"192.168.20.20"
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"ipv4_dst",
"value":"10.10.20.20"
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34887)",
"mpls(bsb=1, label=100, exp=3, ttl=64)",
"ipv4(tos=32, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2048)",
"ipv4(tos=32, proto=6, src='192.168.10.10', dst='10.10.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/svlan/itag/ethernet/svlan/vlan/ipv4(dst='192.168.20.20')/tcp-->'ipv4_dst=192.168.20.20,actions=set_field:10.10.20.20->ipv4_dst,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2048
}
},
{
"OXMTlv":{
"field":"ipv4_dst",
"value":"192.168.20.20"
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"ipv4_dst",
"value":"10.10.20.20"
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2048)",
"ipv4(tos=32, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2048)",
"ipv4(tos=32, proto=6, src='192.168.10.10', dst='10.10.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
}
]

View File

@ -0,0 +1,348 @@
[
"action: set_field: 13_TCP_SRC (IPv4)",
{
"description": "ethernet/ipv4/tcp(src_port=11111)-->'tcp_src=11111,actions=set_field:12345->tcp_src,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2048
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":6
}
},
{
"OXMTlv":{
"field":"tcp_src",
"value":11111
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"tcp_src",
"value":12345
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2048)",
"ipv4(tos=32, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2048)",
"ipv4(tos=32, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=12345)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/vlan/ipv4/tcp(src_port=11111)-->'tcp_src=11111,actions=set_field:12345->tcp_src,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2048
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":6
}
},
{
"OXMTlv":{
"field":"tcp_src",
"value":11111
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"tcp_src",
"value":12345
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2048)",
"ipv4(tos=32, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2048)",
"ipv4(tos=32, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=12345)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/mpls/ipv4/tcp(src_port=11111)-->'actions=pop_mpls:0x0800,goto_table:1','table_id:1,tcp_src=11111,actions=set_field:12345->tcp_src,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34887
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionPopMpls":{
"ethertype":2048
}
}
],
"type":4
}
},
{
"OFPInstructionGotoTable":{
"table_id":1
}
}
]
}
},
{
"OFPFlowMod":{
"table_id":1,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2048
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":6
}
},
{
"OXMTlv":{
"field":"tcp_src",
"value":11111
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"tcp_src",
"value":12345
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34887)",
"mpls(bsb=1, label=100, exp=3, ttl=64)",
"ipv4(tos=32, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2048)",
"ipv4(tos=32, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=12345)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/svlan/itag/ethernet/svlan/vlan/ipv4/tcp(src_port=11111)-->'tcp_src=11111,actions=set_field:12345->tcp_src,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2048
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":6
}
},
{
"OXMTlv":{
"field":"tcp_src",
"value":11111
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"tcp_src",
"value":12345
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2048)",
"ipv4(tos=32, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2048)",
"ipv4(tos=32, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=12345)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
}
]

View File

@ -0,0 +1,348 @@
[
"action: set_field: 13_TCP_SRC (IPv6)",
{
"description": "ethernet/ipv6/tcp(src_port=11111)-->'tcp_src=11111,actions=set_field:12345->tcp_src,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":6
}
},
{
"OXMTlv":{
"field":"tcp_src",
"value":11111
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"tcp_src",
"value":12345
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=12345)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/vlan/ipv6/tcp(src_port=11111)-->'tcp_src=11111,actions=set_field:12345->tcp_src,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":6
}
},
{
"OXMTlv":{
"field":"tcp_src",
"value":11111
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"tcp_src",
"value":12345
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=12345)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/mpls/ipv6/tcp(src_port=11111)-->'actions=pop_mpls:0x86dd,goto_table:1','table_id:1,tcp_src=11111,actions=set_field:12345->tcp_src,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34887
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionPopMpls":{
"ethertype":34525
}
}
],
"type":4
}
},
{
"OFPInstructionGotoTable":{
"table_id":1
}
}
]
}
},
{
"OFPFlowMod":{
"table_id":1,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":6
}
},
{
"OXMTlv":{
"field":"tcp_src",
"value":11111
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"tcp_src",
"value":12345
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34887)",
"mpls(bsb=1, label=100, exp=3, ttl=64)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=12345)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/svlan/itag/ethernet/svlan/vlan/ipv6/tcp(src_port=11111)-->'tcp_src=11111,actions=set_field:12345->tcp_src,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":6
}
},
{
"OXMTlv":{
"field":"tcp_src",
"value":11111
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"tcp_src",
"value":12345
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=12345)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
}
]

View File

@ -0,0 +1,348 @@
[
"action: set_field: 14_TCP_DST (IPv4)",
{
"description": "ethernet/ipv4/tcp(dst_port=2222)-->'tcp_dst=2222,actions=set_field:6789->tcp_dst,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2048
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":6
}
},
{
"OXMTlv":{
"field":"tcp_dst",
"value":2222
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"tcp_dst",
"value":6789
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2048)",
"ipv4(tos=32, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2048)",
"ipv4(tos=32, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=6789, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/vlan/ipv4/tcp(dst_port=2222)-->'tcp_dst=2222,actions=set_field:6789->tcp_dst,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2048
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":6
}
},
{
"OXMTlv":{
"field":"tcp_dst",
"value":2222
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"tcp_dst",
"value":6789
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2048)",
"ipv4(tos=32, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2048)",
"ipv4(tos=32, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=6789, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/mpls/ipv4/tcp(dst_port=2222)-->'actions=pop_mpls:0x0800,goto_table:1','table_id:1,tcp_dst=2222,actions=set_field:6789->tcp_dst,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34887
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionPopMpls":{
"ethertype":2048
}
}
],
"type":4
}
},
{
"OFPInstructionGotoTable":{
"table_id":1
}
}
]
}
},
{
"OFPFlowMod":{
"table_id":1,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2048
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":6
}
},
{
"OXMTlv":{
"field":"tcp_dst",
"value":2222
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"tcp_dst",
"value":6789
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34887)",
"mpls(bsb=1, label=100, exp=3, ttl=64)",
"ipv4(tos=32, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2048)",
"ipv4(tos=32, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=6789, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/svlan/itag/ethernet/svlan/vlan/ipv4/tcp(dst_port=2222)-->'tcp_dst=2222,actions=set_field:6789->tcp_dst,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2048
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":6
}
},
{
"OXMTlv":{
"field":"tcp_dst",
"value":2222
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"tcp_dst",
"value":6789
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2048)",
"ipv4(tos=32, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2048)",
"ipv4(tos=32, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=6789, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
}
]

View File

@ -0,0 +1,348 @@
[
"action: set_field: 14_TCP_DST (IPv6)",
{
"description": "ethernet/ipv6/tcp(dst_port=2222)-->'tcp_dst=2222,actions=set_field:6789->tcp_dst,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":6
}
},
{
"OXMTlv":{
"field":"tcp_dst",
"value":2222
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"tcp_dst",
"value":6789
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=6789, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/vlan/ipv6/tcp(dst_port=2222)-->'tcp_dst=2222,actions=set_field:6789->tcp_dst,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":6
}
},
{
"OXMTlv":{
"field":"tcp_dst",
"value":2222
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"tcp_dst",
"value":6789
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=6789, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/mpls/ipv6/tcp(dst_port=2222)-->'actions=pop_mpls:0x86dd,goto_table:1','table_id:1,tcp_dst=2222,actions=set_field:6789->tcp_dst,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34887
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionPopMpls":{
"ethertype":34525
}
}
],
"type":4
}
},
{
"OFPInstructionGotoTable":{
"table_id":1
}
}
]
}
},
{
"OFPFlowMod":{
"table_id":1,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":6
}
},
{
"OXMTlv":{
"field":"tcp_dst",
"value":2222
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"tcp_dst",
"value":6789
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34887)",
"mpls(bsb=1, label=100, exp=3, ttl=64)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=6789, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/svlan/itag/ethernet/svlan/vlan/ipv6/tcp(dst_port=2222)-->'tcp_dst=2222,actions=set_field:6789->tcp_dst,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":6
}
},
{
"OXMTlv":{
"field":"tcp_dst",
"value":2222
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"tcp_dst",
"value":6789
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=6789, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
}
]

View File

@ -0,0 +1,348 @@
[
"action: set_field: 15_UDP_SRC (IPv4)",
{
"description": "ethernet/ipv4/udp(src_port=11111)-->'udp_src=11111,actions=set_field:12345->udp_src,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2048
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":17
}
},
{
"OXMTlv":{
"field":"udp_src",
"value":11111
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"udp_src",
"value":12345
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2048)",
"ipv4(tos=32, proto=17, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"udp(dst_port=2222, src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2048)",
"ipv4(tos=32, proto=17, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"udp(dst_port=2222, src_port=12345)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/vlan/ipv4/udp(src_port=11111)-->'udp_src=11111,actions=set_field:12345->udp_src,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2048
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":17
}
},
{
"OXMTlv":{
"field":"udp_src",
"value":11111
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"udp_src",
"value":12345
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2048)",
"ipv4(tos=32, proto=17, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"udp(dst_port=2222, src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2048)",
"ipv4(tos=32, proto=17, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"udp(dst_port=2222, src_port=12345)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/mpls/ipv4/udp(src_port=11111)-->'actions=pop_mpls:0x0800,goto_table:1','table_id:1,udp_src=11111,actions=set_field:12345->udp_src,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34887
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionPopMpls":{
"ethertype":2048
}
}
],
"type":4
}
},
{
"OFPInstructionGotoTable":{
"table_id":1
}
}
]
}
},
{
"OFPFlowMod":{
"table_id":1,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2048
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":17
}
},
{
"OXMTlv":{
"field":"udp_src",
"value":11111
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"udp_src",
"value":12345
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34887)",
"mpls(bsb=1, label=100, exp=3, ttl=64)",
"ipv4(tos=32, proto=17, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"udp(dst_port=2222, src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2048)",
"ipv4(tos=32, proto=17, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"udp(dst_port=2222, src_port=12345)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/svlan/itag/ethernet/svlan/vlan/ipv4/udp(src_port=11111)-->'udp_src=11111,actions=set_field:12345->udp_src,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2048
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":17
}
},
{
"OXMTlv":{
"field":"udp_src",
"value":11111
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"udp_src",
"value":12345
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2048)",
"ipv4(tos=32, proto=17, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"udp(dst_port=2222, src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2048)",
"ipv4(tos=32, proto=17, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"udp(dst_port=2222, src_port=12345)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
}
]

View File

@ -0,0 +1,348 @@
[
"action: set_field: 15_UDP_SRC (IPv6)",
{
"description": "ethernet/ipv6/udp(src_port=11111)-->'udp_src=11111,actions=set_field:12345->udp_src,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":17
}
},
{
"OXMTlv":{
"field":"udp_src",
"value":11111
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"udp_src",
"value":12345
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=17, hop_limit=64, traffic_class=32)",
"udp(dst_port=2222, src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=17, hop_limit=64, traffic_class=32)",
"udp(dst_port=2222, src_port=12345)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/vlan/ipv6/udp(src_port=11111)-->'udp_src=11111,actions=set_field:12345->udp_src,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":17
}
},
{
"OXMTlv":{
"field":"udp_src",
"value":11111
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"udp_src",
"value":12345
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=17, hop_limit=64, traffic_class=32)",
"udp(dst_port=2222, src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=17, hop_limit=64, traffic_class=32)",
"udp(dst_port=2222, src_port=12345)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/mpls/ipv6/udp(src_port=11111)-->'actions=pop_mpls:0x86dd,goto_table:1','table_id:1,udp_src=11111,actions=set_field:12345->udp_src,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34887
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionPopMpls":{
"ethertype":34525
}
}
],
"type":4
}
},
{
"OFPInstructionGotoTable":{
"table_id":1
}
}
]
}
},
{
"OFPFlowMod":{
"table_id":1,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":17
}
},
{
"OXMTlv":{
"field":"udp_src",
"value":11111
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"udp_src",
"value":12345
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34887)",
"mpls(bsb=1, label=100, exp=3, ttl=64)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=17, hop_limit=64, traffic_class=32)",
"udp(dst_port=2222, src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=17, hop_limit=64, traffic_class=32)",
"udp(dst_port=2222, src_port=12345)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/svlan/itag/ethernet/svlan/vlan/ipv6/udp(src_port=11111)-->'udp_src=11111,actions=set_field:12345->udp_src,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":17
}
},
{
"OXMTlv":{
"field":"udp_src",
"value":11111
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"udp_src",
"value":12345
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=17, hop_limit=64, traffic_class=32)",
"udp(dst_port=2222, src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=17, hop_limit=64, traffic_class=32)",
"udp(dst_port=2222, src_port=12345)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
}
]

View File

@ -0,0 +1,348 @@
[
"action: set_field: 16_UDP_DST (IPv4)",
{
"description": "ethernet/ipv4/udp(dst_port=2222)-->'udp_dst=2222,actions=set_field:6789->udp_dst,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2048
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":17
}
},
{
"OXMTlv":{
"field":"udp_dst",
"value":2222
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"udp_dst",
"value":6789
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2048)",
"ipv4(tos=32, proto=17, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"udp(dst_port=2222, src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2048)",
"ipv4(tos=32, proto=17, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"udp(dst_port=6789, src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/vlan/ipv4/udp(dst_port=2222)-->'udp_dst=2222,actions=set_field:6789->udp_dst,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2048
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":17
}
},
{
"OXMTlv":{
"field":"udp_dst",
"value":2222
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"udp_dst",
"value":6789
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2048)",
"ipv4(tos=32, proto=17, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"udp(dst_port=2222, src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2048)",
"ipv4(tos=32, proto=17, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"udp(dst_port=6789, src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/mpls/ipv4/udp(dst_port=2222)-->'actions=pop_mpls:0x0800,goto_table:1','table_id:1,udp_dst=2222,actions=set_field:6789->udp_dst,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34887
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionPopMpls":{
"ethertype":2048
}
}
],
"type":4
}
},
{
"OFPInstructionGotoTable":{
"table_id":1
}
}
]
}
},
{
"OFPFlowMod":{
"table_id":1,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2048
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":17
}
},
{
"OXMTlv":{
"field":"udp_dst",
"value":2222
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"udp_dst",
"value":6789
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34887)",
"mpls(bsb=1, label=100, exp=3, ttl=64)",
"ipv4(tos=32, proto=17, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"udp(dst_port=2222, src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2048)",
"ipv4(tos=32, proto=17, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"udp(dst_port=6789, src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/svlan/itag/ethernet/svlan/vlan/ipv4/udp(dst_port=2222)-->'udp_dst=2222,actions=set_field:6789->udp_dst,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2048
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":17
}
},
{
"OXMTlv":{
"field":"udp_dst",
"value":2222
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"udp_dst",
"value":6789
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2048)",
"ipv4(tos=32, proto=17, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"udp(dst_port=2222, src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2048)",
"ipv4(tos=32, proto=17, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"udp(dst_port=6789, src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
}
]

View File

@ -0,0 +1,348 @@
[
"action: set_field: 16_UDP_DST (IPv6)",
{
"description": "ethernet/ipv6/udp(dst_port=2222)-->'udp_dst=2222,actions=set_field:6789->udp_dst,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":17
}
},
{
"OXMTlv":{
"field":"udp_dst",
"value":2222
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"udp_dst",
"value":6789
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=17, hop_limit=64, traffic_class=32)",
"udp(dst_port=2222, src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=17, hop_limit=64, traffic_class=32)",
"udp(dst_port=6789, src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/vlan/ipv6/udp(dst_port=2222)-->'udp_dst=2222,actions=set_field:6789->udp_dst,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":17
}
},
{
"OXMTlv":{
"field":"udp_dst",
"value":2222
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"udp_dst",
"value":6789
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=17, hop_limit=64, traffic_class=32)",
"udp(dst_port=2222, src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=17, hop_limit=64, traffic_class=32)",
"udp(dst_port=6789, src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/mpls/ipv6/udp(dst_port=2222)-->'actions=pop_mpls:0x86dd,goto_table:1','table_id:1,udp_dst=2222,actions=set_field:6789->udp_dst,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34887
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionPopMpls":{
"ethertype":34525
}
}
],
"type":4
}
},
{
"OFPInstructionGotoTable":{
"table_id":1
}
}
]
}
},
{
"OFPFlowMod":{
"table_id":1,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":17
}
},
{
"OXMTlv":{
"field":"udp_dst",
"value":2222
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"udp_dst",
"value":6789
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34887)",
"mpls(bsb=1, label=100, exp=3, ttl=64)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=17, hop_limit=64, traffic_class=32)",
"udp(dst_port=2222, src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=17, hop_limit=64, traffic_class=32)",
"udp(dst_port=6789, src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/svlan/itag/ethernet/svlan/vlan/ipv6/udp(dst_port=2222)-->'udp_dst=2222,actions=set_field:6789->udp_dst,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":17
}
},
{
"OXMTlv":{
"field":"udp_dst",
"value":2222
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"udp_dst",
"value":6789
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=17, hop_limit=64, traffic_class=32)",
"udp(dst_port=2222, src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=17, hop_limit=64, traffic_class=32)",
"udp(dst_port=6789, src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
}
]

View File

@ -0,0 +1,340 @@
[
"action: set_field: 17_SCTP_SRC (IPv4)",
{
"description": "ethernet/ipv4/sctp(src_port=11111)-->'sctp_src=11111,actions=set_field:12345->sctp_src,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2048
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":132
}
},
{
"OXMTlv":{
"field":"sctp_src",
"value":11111
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"sctp_src",
"value":12345
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2048)",
"ipv4(tos=32, proto=132, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"sctp(chunks=[chunk_data(payload_data='0123456789abcdefghijklmnopqrstuvwxyz')], dst_port=2222, src_port=11111)"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2048)",
"ipv4(tos=32, proto=132, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"sctp(chunks=[chunk_data(payload_data='0123456789abcdefghijklmnopqrstuvwxyz')], dst_port=2222, src_port=12345)"
]
}
]
},
{
"description": "ethernet/vlan/ipv4/sctp(src_port=11111)-->'sctp_src=11111,actions=set_field:12345->sctp_src,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2048
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":132
}
},
{
"OXMTlv":{
"field":"sctp_src",
"value":11111
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"sctp_src",
"value":12345
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2048)",
"ipv4(tos=32, proto=132, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"sctp(chunks=[chunk_data(payload_data='0123456789abcdefghijklmnopqrstuvwxyz')], dst_port=2222, src_port=11111)"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2048)",
"ipv4(tos=32, proto=132, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"sctp(chunks=[chunk_data(payload_data='0123456789abcdefghijklmnopqrstuvwxyz')], dst_port=2222, src_port=12345)"
]
}
]
},
{
"description": "ethernet/mpls/ipv4/sctp(src_port=11111)-->'actions=pop_mpls:0x0800,goto_table:1','table_id:1,sctp_src=11111,actions=set_field:12345->sctp_src,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34887
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionPopMpls":{
"ethertype":2048
}
}
],
"type":4
}
},
{
"OFPInstructionGotoTable":{
"table_id":1
}
}
]
}
},
{
"OFPFlowMod":{
"table_id":1,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2048
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":132
}
},
{
"OXMTlv":{
"field":"sctp_src",
"value":11111
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"sctp_src",
"value":12345
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34887)",
"mpls(bsb=1, label=100, exp=3, ttl=64)",
"ipv4(tos=32, proto=132, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"sctp(chunks=[chunk_data(payload_data='0123456789abcdefghijklmnopqrstuvwxyz')], dst_port=2222, src_port=11111)"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2048)",
"ipv4(tos=32, proto=132, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"sctp(chunks=[chunk_data(payload_data='0123456789abcdefghijklmnopqrstuvwxyz')], dst_port=2222, src_port=12345)"
]
}
]
},
{
"description": "ethernet/svlan/itag/ethernet/svlan/vlan/ipv4/sctp(src_port=11111)-->'sctp_src=11111,actions=set_field:12345->sctp_src,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2048
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":132
}
},
{
"OXMTlv":{
"field":"sctp_src",
"value":11111
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"sctp_src",
"value":12345
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2048)",
"ipv4(tos=32, proto=132, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"sctp(chunks=[chunk_data(payload_data='0123456789abcdefghijklmnopqrstuvwxyz')], dst_port=2222, src_port=11111)"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2048)",
"ipv4(tos=32, proto=132, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"sctp(chunks=[chunk_data(payload_data='0123456789abcdefghijklmnopqrstuvwxyz')], dst_port=2222, src_port=12345)"
]
}
]
}
]

View File

@ -0,0 +1,340 @@
[
"action: set_field: 17_SCTP_SRC (IPv6)",
{
"description": "ethernet/ipv6/udp(sctp_port=11111)-->'sctp_src=11111,actions=set_field:12345->sctp_src,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":132
}
},
{
"OXMTlv":{
"field":"sctp_src",
"value":11111
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"sctp_src",
"value":12345
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=132, hop_limit=64, traffic_class=32)",
"sctp(chunks=[chunk_data(payload_data='0123456789abcdefghijklmnopqrstuvwxyz')], dst_port=2222, src_port=11111)"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=132, hop_limit=64, traffic_class=32)",
"sctp(chunks=[chunk_data(payload_data='0123456789abcdefghijklmnopqrstuvwxyz')], dst_port=2222, src_port=12345)"
]
}
]
},
{
"description": "ethernet/vlan/ipv6/sctp(src_port=11111)-->'sctp_src=11111,actions=set_field:12345->sctp_src,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":132
}
},
{
"OXMTlv":{
"field":"sctp_src",
"value":11111
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"sctp_src",
"value":12345
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=132, hop_limit=64, traffic_class=32)",
"sctp(chunks=[chunk_data(payload_data='0123456789abcdefghijklmnopqrstuvwxyz')], dst_port=2222, src_port=11111)"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=132, hop_limit=64, traffic_class=32)",
"sctp(chunks=[chunk_data(payload_data='0123456789abcdefghijklmnopqrstuvwxyz')], dst_port=2222, src_port=12345)"
]
}
]
},
{
"description": "ethernet/mpls/ipv6/sctp(src_port=11111)-->'actions=pop_mpls:0x86dd,goto_table:1','table_id:1,sctp_src=11111,actions=set_field:12345->sctp_src,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34887
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionPopMpls":{
"ethertype":34525
}
}
],
"type":4
}
},
{
"OFPInstructionGotoTable":{
"table_id":1
}
}
]
}
},
{
"OFPFlowMod":{
"table_id":1,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":132
}
},
{
"OXMTlv":{
"field":"sctp_src",
"value":11111
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"sctp_src",
"value":12345
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34887)",
"mpls(bsb=1, label=100, exp=3, ttl=64)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=132, hop_limit=64, traffic_class=32)",
"sctp(chunks=[chunk_data(payload_data='0123456789abcdefghijklmnopqrstuvwxyz')], dst_port=2222, src_port=11111)"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=132, hop_limit=64, traffic_class=32)",
"sctp(chunks=[chunk_data(payload_data='0123456789abcdefghijklmnopqrstuvwxyz')], dst_port=2222, src_port=12345)"
]
}
]
},
{
"description": "ethernet/svlan/itag/ethernet/svlan/vlan/ipv6/sctp(src_port=11111)-->'sctp_src=11111,actions=set_field:12345->sctp_src,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":132
}
},
{
"OXMTlv":{
"field":"sctp_src",
"value":11111
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"sctp_src",
"value":12345
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=132, hop_limit=64, traffic_class=32)",
"sctp(chunks=[chunk_data(payload_data='0123456789abcdefghijklmnopqrstuvwxyz')], dst_port=2222, src_port=11111)"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=132, hop_limit=64, traffic_class=32)",
"sctp(chunks=[chunk_data(payload_data='0123456789abcdefghijklmnopqrstuvwxyz')], dst_port=2222, src_port=12345)"
]
}
]
}
]

View File

@ -0,0 +1,340 @@
[
"action: set_field: 18_SCTP_DST (IPv4)",
{
"description": "ethernet/ipv4/sctp(dst_port=2222)-->'sctp_dst=2222,actions=set_field:6789->sctp_dst,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2048
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":132
}
},
{
"OXMTlv":{
"field":"sctp_dst",
"value":2222
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"sctp_dst",
"value":6789
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2048)",
"ipv4(tos=32, proto=132, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"sctp(chunks=[chunk_data(payload_data='0123456789abcdefghijklmnopqrstuvwxyz')], dst_port=2222, src_port=11111)"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2048)",
"ipv4(tos=32, proto=132, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"sctp(chunks=[chunk_data(payload_data='0123456789abcdefghijklmnopqrstuvwxyz')], dst_port=6789, src_port=11111)"
]
}
]
},
{
"description": "ethernet/vlan/ipv4/sctp(dst_port=2222)-->'sctp_dst=2222,actions=set_field:6789->sctp_dst,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2048
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":132
}
},
{
"OXMTlv":{
"field":"sctp_dst",
"value":2222
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"sctp_dst",
"value":6789
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2048)",
"ipv4(tos=32, proto=132, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"sctp(chunks=[chunk_data(payload_data='0123456789abcdefghijklmnopqrstuvwxyz')], dst_port=2222, src_port=11111)"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2048)",
"ipv4(tos=32, proto=132, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"sctp(chunks=[chunk_data(payload_data='0123456789abcdefghijklmnopqrstuvwxyz')], dst_port=6789, src_port=11111)"
]
}
]
},
{
"description": "ethernet/mpls/ipv4/sctp(dst_port=2222)-->'actions=pop_mpls:0x0800,goto_table:1','table_id:1,sctp_dst=2222,actions=set_field:6789->sctp_dst,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34887
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionPopMpls":{
"ethertype":2048
}
}
],
"type":4
}
},
{
"OFPInstructionGotoTable":{
"table_id":1
}
}
]
}
},
{
"OFPFlowMod":{
"table_id":1,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2048
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":132
}
},
{
"OXMTlv":{
"field":"sctp_dst",
"value":2222
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"sctp_dst",
"value":6789
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34887)",
"mpls(bsb=1, label=100, exp=3, ttl=64)",
"ipv4(tos=32, proto=132, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"sctp(chunks=[chunk_data(payload_data='0123456789abcdefghijklmnopqrstuvwxyz')], dst_port=2222, src_port=11111)"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2048)",
"ipv4(tos=32, proto=132, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"sctp(chunks=[chunk_data(payload_data='0123456789abcdefghijklmnopqrstuvwxyz')], dst_port=6789, src_port=11111)"
]
}
]
},
{
"description": "ethernet/svlan/itag/ethernet/svlan/vlan/ipv4/sctp(dst_port=2222)-->'sctp_dst=2222,actions=set_field:6789->sctp_dst,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2048
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":132
}
},
{
"OXMTlv":{
"field":"sctp_dst",
"value":2222
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"sctp_dst",
"value":6789
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2048)",
"ipv4(tos=32, proto=132, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"sctp(chunks=[chunk_data(payload_data='0123456789abcdefghijklmnopqrstuvwxyz')], dst_port=2222, src_port=11111)"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2048)",
"ipv4(tos=32, proto=132, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"sctp(chunks=[chunk_data(payload_data='0123456789abcdefghijklmnopqrstuvwxyz')], dst_port=6789, src_port=11111)"
]
}
]
}
]

View File

@ -0,0 +1,340 @@
[
"action: set_field: 18_SCTP_DST (IPv6)",
{
"description": "ethernet/ipv6/sctp(dst_port=2222)-->'sctp_dst=2222,actions=set_field:6789->sctp_dst,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":132
}
},
{
"OXMTlv":{
"field":"sctp_dst",
"value":2222
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"sctp_dst",
"value":6789
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=132, hop_limit=64, traffic_class=32)",
"sctp(chunks=[chunk_data(payload_data='0123456789abcdefghijklmnopqrstuvwxyz')], dst_port=2222, src_port=11111)"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=132, hop_limit=64, traffic_class=32)",
"sctp(chunks=[chunk_data(payload_data='0123456789abcdefghijklmnopqrstuvwxyz')], dst_port=6789, src_port=11111)"
]
}
]
},
{
"description": "ethernet/vlan/ipv6/sctp(dst_port=2222)-->'sctp_dst=2222,actions=set_field:6789->sctp_dst,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":132
}
},
{
"OXMTlv":{
"field":"sctp_dst",
"value":2222
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"sctp_dst",
"value":6789
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=132, hop_limit=64, traffic_class=32)",
"sctp(chunks=[chunk_data(payload_data='0123456789abcdefghijklmnopqrstuvwxyz')], dst_port=2222, src_port=11111)"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=132, hop_limit=64, traffic_class=32)",
"sctp(chunks=[chunk_data(payload_data='0123456789abcdefghijklmnopqrstuvwxyz')], dst_port=6789, src_port=11111)"
]
}
]
},
{
"description": "ethernet/mpls/ipv6/sctp(dst_port=2222)-->'actions=pop_mpls:0x86dd,goto_table:1','table_id:1,sctp_dst=2222,actions=set_field:6789->sctp_dst,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34887
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionPopMpls":{
"ethertype":34525
}
}
],
"type":4
}
},
{
"OFPInstructionGotoTable":{
"table_id":1
}
}
]
}
},
{
"OFPFlowMod":{
"table_id":1,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":132
}
},
{
"OXMTlv":{
"field":"sctp_dst",
"value":2222
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"sctp_dst",
"value":6789
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34887)",
"mpls(bsb=1, label=100, exp=3, ttl=64)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=132, hop_limit=64, traffic_class=32)",
"sctp(chunks=[chunk_data(payload_data='0123456789abcdefghijklmnopqrstuvwxyz')], dst_port=2222, src_port=11111)"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=132, hop_limit=64, traffic_class=32)",
"sctp(chunks=[chunk_data(payload_data='0123456789abcdefghijklmnopqrstuvwxyz')], dst_port=6789, src_port=11111)"
]
}
]
},
{
"description": "ethernet/svlan/itag/ethernet/svlan/vlan/ipv6/sctp(dst_port=2222)-->'sctp_dst=2222,actions=set_field:6789->sctp_dst,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":132
}
},
{
"OXMTlv":{
"field":"sctp_dst",
"value":2222
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"sctp_dst",
"value":6789
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=132, hop_limit=64, traffic_class=32)",
"sctp(chunks=[chunk_data(payload_data='0123456789abcdefghijklmnopqrstuvwxyz')], dst_port=2222, src_port=11111)"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=132, hop_limit=64, traffic_class=32)",
"sctp(chunks=[chunk_data(payload_data='0123456789abcdefghijklmnopqrstuvwxyz')], dst_port=6789, src_port=11111)"
]
}
]
}
]

View File

@ -0,0 +1,340 @@
[
"action: set_field: 19_ICMPV4_TYPE",
{
"description": "ethernet/ipv4/icmp(type=8)-->'icmpv4_type=8,actions=set_field:0->icmpv4_type,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2048
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":1
}
},
{
"OXMTlv":{
"field":"icmpv4_type",
"value":8
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"icmpv4_type",
"value":0
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2048)",
"ipv4(tos=32, proto=1, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"icmp(code=0,csum=0,data=echo(data='0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKL'),type_=8)"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2048)",
"ipv4(tos=32, proto=1, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"icmp(code=0,csum=0,data=echo(data='0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKL'),type_=0)"
]
}
]
},
{
"description": "ethernet/vlan/ipv4/icmp(type=8)-->'icmpv4_type=8,actions=set_field:0->icmpv4_type,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2048
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":1
}
},
{
"OXMTlv":{
"field":"icmpv4_type",
"value":8
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"icmpv4_type",
"value":0
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2048)",
"ipv4(tos=32, proto=1, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"icmp(code=0,csum=0,data=echo(data='0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKL'),type_=8)"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2048)",
"ipv4(tos=32, proto=1, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"icmp(code=0,csum=0,data=echo(data='0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKL'),type_=0)"
]
}
]
},
{
"description": "ethernet/mpls/ipv4/icmp(type=8)-->'actions=pop_mpls:0x0800,goto_table:1','table_id:1,icmpv4_type=8,actions=set_field:0->icmpv4_type,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34887
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionPopMpls":{
"ethertype":2048
}
}
],
"type":4
}
},
{
"OFPInstructionGotoTable":{
"table_id":1
}
}
]
}
},
{
"OFPFlowMod":{
"table_id":1,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2048
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":1
}
},
{
"OXMTlv":{
"field":"icmpv4_type",
"value":8
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"icmpv4_type",
"value":0
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34887)",
"mpls(bsb=1, label=100, exp=3, ttl=64)",
"ipv4(tos=32, proto=1, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"icmp(code=0,csum=0,data=echo(data='0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKL'),type_=8)"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2048)",
"ipv4(tos=32, proto=1, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"icmp(code=0,csum=0,data=echo(data='0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKL'),type_=0)"
]
}
]
},
{
"description": "ethernet/svlan/itag/ethernet/svlan/vlan/ipv4/icmp(type=8)-->'icmpv4_type=8,actions=set_field:0->icmpv4_type,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2048
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":1
}
},
{
"OXMTlv":{
"field":"icmpv4_type",
"value":8
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"icmpv4_type",
"value":0
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2048)",
"ipv4(tos=32, proto=1, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"icmp(code=0,csum=0,data=echo(data='0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKL'),type_=8)"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2048)",
"ipv4(tos=32, proto=1, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"icmp(code=0,csum=0,data=echo(data='0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKL'),type_=0)"
]
}
]
}
]

View File

@ -0,0 +1,340 @@
[
"action: set_field: 20_ICMPV4_CODE",
{
"description": "ethernet/ipv4/icmp(code=0)-->'icmpv4_code=0,actions=set_field:10->icmpv4_code,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2048
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":1
}
},
{
"OXMTlv":{
"field":"icmpv4_code",
"value":0
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"icmpv4_code",
"value":10
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2048)",
"ipv4(tos=32, proto=1, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"icmp(code=0,csum=0,data=echo(data='0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKL'),type_=8)"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2048)",
"ipv4(tos=32, proto=1, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"icmp(code=10,csum=0,data=echo(data='0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKL'),type_=8)"
]
}
]
},
{
"description": "ethernet/vlan/ipv4/icmp(code=0)-->'icmpv4_code=0,actions=set_field:10->icmpv4_code,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2048
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":1
}
},
{
"OXMTlv":{
"field":"icmpv4_code",
"value":0
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"icmpv4_code",
"value":10
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2048)",
"ipv4(tos=32, proto=1, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"icmp(code=0,csum=0,data=echo(data='0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKL'),type_=8)"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2048)",
"ipv4(tos=32, proto=1, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"icmp(code=10,csum=0,data=echo(data='0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKL'),type_=8)"
]
}
]
},
{
"description": "ethernet/mpls/ipv4/icmp(code=0)-->'actions=pop_mpls:0x0800,goto_table:1','table_id:1,icmpv4_code=0,actions=set_field:10->icmpv4_code,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34887
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionPopMpls":{
"ethertype":2048
}
}
],
"type":4
}
},
{
"OFPInstructionGotoTable":{
"table_id":1
}
}
]
}
},
{
"OFPFlowMod":{
"table_id":1,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2048
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":1
}
},
{
"OXMTlv":{
"field":"icmpv4_code",
"value":0
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"icmpv4_code",
"value":10
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34887)",
"mpls(bsb=1, label=100, exp=3, ttl=64)",
"ipv4(tos=32, proto=1, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"icmp(code=0,csum=0,data=echo(data='0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKL'),type_=8)"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2048)",
"ipv4(tos=32, proto=1, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"icmp(code=10,csum=0,data=echo(data='0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKL'),type_=8)"
]
}
]
},
{
"description": "ethernet/svlan/itag/ethernet/svlan/vlan/ipv4/icmp(code=0)-->'icmpv4_code=0,actions=set_field:10->icmpv4_code,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2048
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":1
}
},
{
"OXMTlv":{
"field":"icmpv4_code",
"value":0
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"icmpv4_code",
"value":10
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2048)",
"ipv4(tos=32, proto=1, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"icmp(code=0,csum=0,data=echo(data='0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKL'),type_=8)"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2048)",
"ipv4(tos=32, proto=1, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"icmp(code=10,csum=0,data=echo(data='0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKL'),type_=8)"
]
}
]
}
]

View File

@ -0,0 +1,316 @@
[
"action: set_field: 21_ARP_OP",
{
"description": "ethernet/arp(opcode=1)-->'arp_op=1,actions=set_field:2->arp_op,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2054
}
},
{
"OXMTlv":{
"field":"arp_op",
"value":1
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"arp_op",
"value":2
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2054)",
"arp(dst_ip='192.168.20.20',dst_mac='22:22:22:22:22:22', opcode=1, src_ip='192.168.10.10',src_mac='11:11:11:11:11:11')",
"'\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2054)",
"arp(dst_ip='192.168.20.20',dst_mac='22:22:22:22:22:22', opcode=2, src_ip='192.168.10.10',src_mac='11:11:11:11:11:11')",
"'\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00'"
]
}
]
},
{
"description": "ethernet/vlan/arp(opcode=1)-->'arp_op=1,actions=set_field:2->arp_op,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2054
}
},
{
"OXMTlv":{
"field":"arp_op",
"value":1
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"arp_op",
"value":2
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2054)",
"arp(dst_ip='192.168.20.20',dst_mac='22:22:22:22:22:22', opcode=1, src_ip='192.168.10.10',src_mac='11:11:11:11:11:11')",
"'\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2054)",
"arp(dst_ip='192.168.20.20',dst_mac='22:22:22:22:22:22', opcode=2, src_ip='192.168.10.10',src_mac='11:11:11:11:11:11')",
"'\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00'"
]
}
]
},
{
"description": "ethernet/mpls/arp(opcode=1)-->'actions=pop_mpls:0x0800,goto_table:1','table_id:1,arp_op=1,actions=set_field:2->arp_op,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34887
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionPopMpls":{
"ethertype":2054
}
}
],
"type":4
}
},
{
"OFPInstructionGotoTable":{
"table_id":1
}
}
]
}
},
{
"OFPFlowMod":{
"table_id":1,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2054
}
},
{
"OXMTlv":{
"field":"arp_op",
"value":1
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"arp_op",
"value":2
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34887)",
"mpls(bsb=1, label=100, exp=3, ttl=64)",
"arp(dst_ip='192.168.20.20',dst_mac='22:22:22:22:22:22', opcode=1, src_ip='192.168.10.10',src_mac='11:11:11:11:11:11')",
"'\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2054)",
"arp(dst_ip='192.168.20.20',dst_mac='22:22:22:22:22:22', opcode=2, src_ip='192.168.10.10',src_mac='11:11:11:11:11:11')",
"'\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00'"
]
}
]
},
{
"description": "ethernet/svlan/itag/ethernet/svlan/vlan/arp(opcode=1)-->'arp_op=1,actions=set_field:2->arp_op,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2054
}
},
{
"OXMTlv":{
"field":"arp_op",
"value":1
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"arp_op",
"value":2
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2054)",
"arp(dst_ip='192.168.20.20',dst_mac='22:22:22:22:22:22', opcode=1, src_ip='192.168.10.10',src_mac='11:11:11:11:11:11')",
"'\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2054)",
"arp(dst_ip='192.168.20.20',dst_mac='22:22:22:22:22:22', opcode=2, src_ip='192.168.10.10',src_mac='11:11:11:11:11:11')",
"'\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00'"
]
}
]
}
]

View File

@ -0,0 +1,316 @@
[
"action: set_field: 22_ARP_SPA",
{
"description": "ethernet/arp(src_ip='192.168.10.10')-->'arp_spa=192.168.10.10,actions=set_field:10.10.10.10->arp_spa,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2054
}
},
{
"OXMTlv":{
"field":"arp_spa",
"value":"192.168.10.10"
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"arp_spa",
"value":"10.10.10.10"
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2054)",
"arp(dst_ip='192.168.20.20',dst_mac='22:22:22:22:22:22', opcode=1, src_ip='192.168.10.10',src_mac='11:11:11:11:11:11')",
"'\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2054)",
"arp(dst_ip='192.168.20.20',dst_mac='22:22:22:22:22:22', opcode=1, src_ip='10.10.10.10',src_mac='11:11:11:11:11:11')",
"'\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00'"
]
}
]
},
{
"description": "ethernet/vlan/arp(src_ip='192.168.10.10')-->'arp_spa=192.168.10.10,actions=set_field:10.10.10.10->arp_spa,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2054
}
},
{
"OXMTlv":{
"field":"arp_spa",
"value":"192.168.10.10"
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"arp_spa",
"value":"10.10.10.10"
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2054)",
"arp(dst_ip='192.168.20.20',dst_mac='22:22:22:22:22:22', opcode=1, src_ip='192.168.10.10',src_mac='11:11:11:11:11:11')",
"'\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2054)",
"arp(dst_ip='192.168.20.20',dst_mac='22:22:22:22:22:22', opcode=1, src_ip='10.10.10.10',src_mac='11:11:11:11:11:11')",
"'\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00'"
]
}
]
},
{
"description": "ethernet/mpls/arp(src_ip='192.168.10.10')-->'actions=pop_mpls:0x0800,goto_table:1','table_id:1,arp_spa=192.168.10.10,actions=set_field:10.10.10.10->arp_spa,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34887
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionPopMpls":{
"ethertype":2054
}
}
],
"type":4
}
},
{
"OFPInstructionGotoTable":{
"table_id":1
}
}
]
}
},
{
"OFPFlowMod":{
"table_id":1,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2054
}
},
{
"OXMTlv":{
"field":"arp_spa",
"value":"192.168.10.10"
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"arp_spa",
"value":"10.10.10.10"
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34887)",
"mpls(bsb=1, label=100, exp=3, ttl=64)",
"arp(dst_ip='192.168.20.20',dst_mac='22:22:22:22:22:22', opcode=1, src_ip='192.168.10.10',src_mac='11:11:11:11:11:11')",
"'\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2054)",
"arp(dst_ip='192.168.20.20',dst_mac='22:22:22:22:22:22', opcode=1, src_ip='10.10.10.10',src_mac='11:11:11:11:11:11')",
"'\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00'"
]
}
]
},
{
"description": "ethernet/svlan/itag/ethernet/svlan/vlan/arp(src_ip='192.168.10.10')-->'arp_spa=192.168.10.10,actions=set_field:10.10.10.10->arp_spa,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2054
}
},
{
"OXMTlv":{
"field":"arp_spa",
"value":"192.168.10.10"
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"arp_spa",
"value":"10.10.10.10"
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2054)",
"arp(dst_ip='192.168.20.20',dst_mac='22:22:22:22:22:22', opcode=1, src_ip='192.168.10.10',src_mac='11:11:11:11:11:11')",
"'\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2054)",
"arp(dst_ip='192.168.20.20',dst_mac='22:22:22:22:22:22', opcode=1, src_ip='10.10.10.10',src_mac='11:11:11:11:11:11')",
"'\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00'"
]
}
]
}
]

View File

@ -0,0 +1,316 @@
[
"action: set_field: 23_ARP_TPA",
{
"description": "ethernet/arp(dst_ip='192.168.20.20')-->'arp_tpa=192.168.20.20,actions=set_field:10.10.20.20->arp_tpa,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2054
}
},
{
"OXMTlv":{
"field":"arp_tpa",
"value":"192.168.20.20"
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"arp_tpa",
"value":"10.10.20.20"
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2054)",
"arp(dst_ip='192.168.20.20',dst_mac='22:22:22:22:22:22', opcode=1, src_ip='192.168.10.10',src_mac='11:11:11:11:11:11')",
"'\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2054)",
"arp(dst_ip='10.10.20.20',dst_mac='22:22:22:22:22:22', opcode=1, src_ip='192.168.10.10',src_mac='11:11:11:11:11:11')",
"'\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00'"
]
}
]
},
{
"description": "ethernet/vlan/arp(dst_ip='192.168.20.20')-->'arp_tpa=192.168.20.20,actions=set_field:10.10.20.20->arp_tpa,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2054
}
},
{
"OXMTlv":{
"field":"arp_tpa",
"value":"192.168.20.20"
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"arp_tpa",
"value":"10.10.20.20"
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2054)",
"arp(dst_ip='192.168.20.20',dst_mac='22:22:22:22:22:22', opcode=1, src_ip='192.168.10.10',src_mac='11:11:11:11:11:11')",
"'\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2054)",
"arp(dst_ip='10.10.20.20',dst_mac='22:22:22:22:22:22', opcode=1, src_ip='192.168.10.10',src_mac='11:11:11:11:11:11')",
"'\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00'"
]
}
]
},
{
"description": "ethernet/mpls/arp(dst_ip='192.168.20.20')-->'actions=pop_mpls:0x0800,goto_table:1','table_id:1,arp_tpa=192.168.20.20,actions=set_field:10.10.20.20->arp_tpa,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34887
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionPopMpls":{
"ethertype":2054
}
}
],
"type":4
}
},
{
"OFPInstructionGotoTable":{
"table_id":1
}
}
]
}
},
{
"OFPFlowMod":{
"table_id":1,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2054
}
},
{
"OXMTlv":{
"field":"arp_tpa",
"value":"192.168.20.20"
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"arp_tpa",
"value":"10.10.20.20"
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34887)",
"mpls(bsb=1, label=100, exp=3, ttl=64)",
"arp(dst_ip='192.168.20.20',dst_mac='22:22:22:22:22:22', opcode=1, src_ip='192.168.10.10',src_mac='11:11:11:11:11:11')",
"'\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2054)",
"arp(dst_ip='10.10.20.20',dst_mac='22:22:22:22:22:22', opcode=1, src_ip='192.168.10.10',src_mac='11:11:11:11:11:11')",
"'\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00'"
]
}
]
},
{
"description": "ethernet/svlan/itag/ethernet/svlan/vlan/arp(dst_ip='192.168.20.20')-->'arp_tpa=192.168.20.20,actions=set_field:10.10.20.20->arp_tpa,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2054
}
},
{
"OXMTlv":{
"field":"arp_tpa",
"value":"192.168.20.20"
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"arp_tpa",
"value":"10.10.20.20"
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2054)",
"arp(dst_ip='192.168.20.20',dst_mac='22:22:22:22:22:22', opcode=1, src_ip='192.168.10.10',src_mac='11:11:11:11:11:11')",
"'\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2054)",
"arp(dst_ip='10.10.20.20',dst_mac='22:22:22:22:22:22', opcode=1, src_ip='192.168.10.10',src_mac='11:11:11:11:11:11')",
"'\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00'"
]
}
]
}
]

View File

@ -0,0 +1,316 @@
[
"action: set_field: 24_ARP_SHA",
{
"description": "ethernet/arp(src_mac='11:11:11:11:11:11')-->'arp_sha=11:11:11:11:11:11,actions=set_field:aa:aa:aa:aa:aa:aa->arp_sha,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2054
}
},
{
"OXMTlv":{
"field":"arp_sha",
"value":"11:11:11:11:11:11"
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"arp_sha",
"value":"aa:aa:aa:aa:aa:aa"
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2054)",
"arp(dst_ip='192.168.20.20',dst_mac='22:22:22:22:22:22', opcode=1, src_ip='192.168.10.10',src_mac='11:11:11:11:11:11')",
"'\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2054)",
"arp(dst_ip='192.168.20.20',dst_mac='22:22:22:22:22:22', opcode=1, src_ip='192.168.10.10',src_mac='aa:aa:aa:aa:aa:aa')",
"'\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00'"
]
}
]
},
{
"description": "ethernet/vlan/arp(src_mac='11:11:11:11:11:11')-->'arp_sha=11:11:11:11:11:11,actions=set_field:aa:aa:aa:aa:aa:aa->arp_sha,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2054
}
},
{
"OXMTlv":{
"field":"arp_sha",
"value":"11:11:11:11:11:11"
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"arp_sha",
"value":"aa:aa:aa:aa:aa:aa"
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2054)",
"arp(dst_ip='192.168.20.20',dst_mac='22:22:22:22:22:22', opcode=1, src_ip='192.168.10.10',src_mac='11:11:11:11:11:11')",
"'\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2054)",
"arp(dst_ip='192.168.20.20',dst_mac='22:22:22:22:22:22', opcode=1, src_ip='192.168.10.10',src_mac='aa:aa:aa:aa:aa:aa')",
"'\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00'"
]
}
]
},
{
"description": "ethernet/mpls/arp(src_mac='11:11:11:11:11:11')-->'actions=pop_mpls:0x0800,goto_table:1','table_id:1,arp_sha=11:11:11:11:11:11,actions=set_field:aa:aa:aa:aa:aa:aa->arp_sha,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34887
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionPopMpls":{
"ethertype":2054
}
}
],
"type":4
}
},
{
"OFPInstructionGotoTable":{
"table_id":1
}
}
]
}
},
{
"OFPFlowMod":{
"table_id":1,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2054
}
},
{
"OXMTlv":{
"field":"arp_sha",
"value":"11:11:11:11:11:11"
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"arp_sha",
"value":"aa:aa:aa:aa:aa:aa"
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34887)",
"mpls(bsb=1, label=100, exp=3, ttl=64)",
"arp(dst_ip='192.168.20.20',dst_mac='22:22:22:22:22:22', opcode=1, src_ip='192.168.10.10',src_mac='11:11:11:11:11:11')",
"'\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2054)",
"arp(dst_ip='192.168.20.20',dst_mac='22:22:22:22:22:22', opcode=1, src_ip='192.168.10.10',src_mac='aa:aa:aa:aa:aa:aa')",
"'\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00'"
]
}
]
},
{
"description": "ethernet/svlan/itag/ethernet/svlan/vlan/arp(src_mac='11:11:11:11:11:11')-->'arp_sha=11:11:11:11:11:11,actions=set_field:aa:aa:aa:aa:aa:aa->arp_sha,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2054
}
},
{
"OXMTlv":{
"field":"arp_sha",
"value":"11:11:11:11:11:11"
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"arp_sha",
"value":"aa:aa:aa:aa:aa:aa"
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2054)",
"arp(dst_ip='192.168.20.20',dst_mac='22:22:22:22:22:22', opcode=1, src_ip='192.168.10.10',src_mac='11:11:11:11:11:11')",
"'\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2054)",
"arp(dst_ip='192.168.20.20',dst_mac='22:22:22:22:22:22', opcode=1, src_ip='192.168.10.10',src_mac='aa:aa:aa:aa:aa:aa')",
"'\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00'"
]
}
]
}
]

View File

@ -0,0 +1,316 @@
[
"action: set_field: 25_ARP_THA",
{
"description": "ethernet/arp(dst_mac='22:22:22:22:22:22')-->'arp_tha=22:22:22:22:22:22,actions=set_field:bb:bb:bb:bb:bb:bb->arp_tha,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2054
}
},
{
"OXMTlv":{
"field":"arp_tha",
"value":"22:22:22:22:22:22"
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"arp_tha",
"value":"bb:bb:bb:bb:bb:bb"
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2054)",
"arp(dst_ip='192.168.20.20',dst_mac='22:22:22:22:22:22', opcode=1, src_ip='192.168.10.10',src_mac='11:11:11:11:11:11')",
"'\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2054)",
"arp(dst_ip='192.168.20.20',dst_mac='bb:bb:bb:bb:bb:bb', opcode=1, src_ip='192.168.10.10',src_mac='11:11:11:11:11:11')",
"'\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00'"
]
}
]
},
{
"description": "ethernet/vlan/arp(dst_mac='22:22:22:22:22:22')-->'arp_tha=22:22:22:22:22:22,actions=set_field:bb:bb:bb:bb:bb:bb->arp_tha,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2054
}
},
{
"OXMTlv":{
"field":"arp_tha",
"value":"22:22:22:22:22:22"
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"arp_tha",
"value":"bb:bb:bb:bb:bb:bb"
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2054)",
"arp(dst_ip='192.168.20.20',dst_mac='22:22:22:22:22:22', opcode=1, src_ip='192.168.10.10',src_mac='11:11:11:11:11:11')",
"'\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2054)",
"arp(dst_ip='192.168.20.20',dst_mac='bb:bb:bb:bb:bb:bb', opcode=1, src_ip='192.168.10.10',src_mac='11:11:11:11:11:11')",
"'\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00'"
]
}
]
},
{
"description": "ethernet/mpls/arp(dst_mac='22:22:22:22:22:22')-->'actions=pop_mpls:0x0800,goto_table:1','table_id:1,arp_tha=22:22:22:22:22:22,actions=set_field:bb:bb:bb:bb:bb:bb->arp_tha,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34887
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionPopMpls":{
"ethertype":2054
}
}
],
"type":4
}
},
{
"OFPInstructionGotoTable":{
"table_id":1
}
}
]
}
},
{
"OFPFlowMod":{
"table_id":1,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2054
}
},
{
"OXMTlv":{
"field":"arp_tha",
"value":"22:22:22:22:22:22"
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"arp_tha",
"value":"bb:bb:bb:bb:bb:bb"
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34887)",
"mpls(bsb=1, label=100, exp=3, ttl=64)",
"arp(dst_ip='192.168.20.20',dst_mac='22:22:22:22:22:22', opcode=1, src_ip='192.168.10.10',src_mac='11:11:11:11:11:11')",
"'\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2054)",
"arp(dst_ip='192.168.20.20',dst_mac='bb:bb:bb:bb:bb:bb', opcode=1, src_ip='192.168.10.10',src_mac='11:11:11:11:11:11')",
"'\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00'"
]
}
]
},
{
"description": "ethernet/svlan/itag/ethernet/svlan/vlan/arp(dst_mac='22:22:22:22:22:22')-->'arp_tha=22:22:22:22:22:22,actions=set_field:bb:bb:bb:bb:bb:bb->arp_tha,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":2054
}
},
{
"OXMTlv":{
"field":"arp_tha",
"value":"22:22:22:22:22:22"
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"arp_tha",
"value":"bb:bb:bb:bb:bb:bb"
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2054)",
"arp(dst_ip='192.168.20.20',dst_mac='22:22:22:22:22:22', opcode=1, src_ip='192.168.10.10',src_mac='11:11:11:11:11:11')",
"'\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2054)",
"arp(dst_ip='192.168.20.20',dst_mac='bb:bb:bb:bb:bb:bb', opcode=1, src_ip='192.168.10.10',src_mac='11:11:11:11:11:11')",
"'\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00'"
]
}
]
}
]

View File

@ -0,0 +1,324 @@
[
"action: set_field: 26_IPV6_SRC",
{
"description": "ethernet/ipv6(src='10::10')/tcp-->'ipv6_src=10::10,actions=set_field:a0::a0->ipv6_src,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ipv6_src",
"value":"10::10"
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"ipv6_src",
"value":"a0::a0"
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='a0::a0', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/vlan/ipv6(src='10::10')/tcp-->'ipv6_src=10::10,actions=set_field:a0::a0->ipv6_src,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ipv6_src",
"value":"10::10"
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"ipv6_src",
"value":"a0::a0"
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='a0::a0', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/mpls/ipv6(src='10::10')/tcp-->'actions=pop_mpls:0x86dd,goto_table:1','table_id:1,ipv6_src=10::10,actions=set_field:a0::a0->ipv6_src,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34887
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionPopMpls":{
"ethertype":34525
}
}
],
"type":4
}
},
{
"OFPInstructionGotoTable":{
"table_id":1
}
}
]
}
},
{
"OFPFlowMod":{
"table_id":1,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ipv6_src",
"value":"10::10"
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"ipv6_src",
"value":"a0::a0"
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34887)",
"mpls(bsb=1, label=100, exp=3, ttl=64)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='a0::a0', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/svlan/itag/ethernet/svlan/vlan/ipv6(src='10::10')/tcp-->'ipv6_src=10::10,actions=set_field:a0::a0->ipv6_src,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ipv6_src",
"value":"10::10"
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"ipv6_src",
"value":"a0::a0"
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='a0::a0', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
}
]

View File

@ -0,0 +1,324 @@
[
"action: set_field: 27_IPV6_DST",
{
"description": "ethernet/ipv6(dst='20::20')/tcp-->'ipv6_dst=20::20,actions=set_field:b0::b0->ipv6_dst,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ipv6_dst",
"value":"20::20"
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"ipv6_dst",
"value":"b0::b0"
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34525)",
"ipv6(dst='b0::b0', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/vlan/ipv6(dst='20::20')/tcp-->'ipv6_dst=20::20,actions=set_field:b0::b0->ipv6_dst,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ipv6_dst",
"value":"20::20"
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"ipv6_dst",
"value":"b0::b0"
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='b0::b0', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/mpls/ipv6(dst='20::20')/tcp-->'actions=pop_mpls:0x86dd,goto_table:1','table_id:1,ipv6_dst=20::20,actions=set_field:b0::b0->ipv6_dst,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34887
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionPopMpls":{
"ethertype":34525
}
}
],
"type":4
}
},
{
"OFPInstructionGotoTable":{
"table_id":1
}
}
]
}
},
{
"OFPFlowMod":{
"table_id":1,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ipv6_dst",
"value":"20::20"
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"ipv6_dst",
"value":"b0::b0"
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34887)",
"mpls(bsb=1, label=100, exp=3, ttl=64)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34525)",
"ipv6(dst='b0::b0', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/svlan/itag/ethernet/svlan/vlan/ipv6(dst='20::20')/tcp--->'ipv6_dst=20::20,actions=set_field:b0::b0->ipv6_dst,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ipv6_dst",
"value":"20::20"
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"ipv6_dst",
"value":"b0::b0"
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='b0::b0', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
}
]

View File

@ -0,0 +1,324 @@
[
"action: set_field: 28_IPV6_FLABEL",
{
"description": "ethernet/ipv6(flow_label=100)/tcp-->'ipv6_flabel=100,actions=set_field:203->ipv6_flabel,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ipv6_flabel",
"value":100
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"ipv6_flabel",
"value":203
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34525)",
"ipv6(dst='20::20', flow_label=203, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/vlan/ipv6(flow_label=100)/tcp-->'ipv6_flabel=100,actions=set_field:203->ipv6_flabel,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ipv6_flabel",
"value":100
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"ipv6_flabel",
"value":203
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=203, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/mpls/ipv6(flow_label=100)/tcp-->'actions=pop_mpls:0x86dd,goto_table:1','table_id:1,ipv6_flabel=100,actions=set_field:203->ipv6_flabel,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34887
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionPopMpls":{
"ethertype":34525
}
}
],
"type":4
}
},
{
"OFPInstructionGotoTable":{
"table_id":1
}
}
]
}
},
{
"OFPFlowMod":{
"table_id":1,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ipv6_flabel",
"value":100
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"ipv6_flabel",
"value":203
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34887)",
"mpls(bsb=1, label=100, exp=3, ttl=64)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34525)",
"ipv6(dst='20::20', flow_label=203, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/svlan/itag/ethernet/svlan/vlan/ipv6(flow_label=100)/tcp-->'ipv6_flabel=100,actions=set_field:203->ipv6_flabel,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ipv6_flabel",
"value":100
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"ipv6_flabel",
"value":203
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=203, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
}
]

View File

@ -0,0 +1,340 @@
[
"action: set_field: 29_ICMPV6_TYPE",
{
"description": "ethernet/ipv6/icmpv6(type=128)-->'icmpv6_type=128,actions=set_field:135->icmpv6_type,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":58
}
},
{
"OXMTlv":{
"field":"icmpv6_type",
"value":128
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"icmpv6_type",
"value":135
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=58, hop_limit=64, traffic_class=32)",
"icmpv6(code=0,data=echo(data='\\x00\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f !\"#$%&\\'()*+,-./0123'),type_=128)"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=58, hop_limit=64, traffic_class=32)",
"icmpv6(code=0,data=echo(data='\\x00\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f !\"#$%&\\'()*+,-./0123'),type_=135)"
]
}
]
},
{
"description": "ethernet/vlan/ipv6/icmpv6(type=128)-->'icmpv6_type=128,actions=set_field:135->icmpv6_type,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":58
}
},
{
"OXMTlv":{
"field":"icmpv6_type",
"value":128
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"icmpv6_type",
"value":135
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=58, hop_limit=64, traffic_class=32)",
"icmpv6(code=0,data=echo(data='\\x00\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f !\"#$%&\\'()*+,-./0123'),type_=128)"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=58, hop_limit=64, traffic_class=32)",
"icmpv6(code=0,data=echo(data='\\x00\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f !\"#$%&\\'()*+,-./0123'),type_=135)"
]
}
]
},
{
"description": "ethernet/mpls/ipv6/icmpv6(type=128)-->'actions=pop_mpls:0x86dd,goto_table:1','table_id:1,icmpv6_type=128,actions=set_field:135->icmpv6_type,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34887
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionPopMpls":{
"ethertype":34525
}
}
],
"type":4
}
},
{
"OFPInstructionGotoTable":{
"table_id":1
}
}
]
}
},
{
"OFPFlowMod":{
"table_id":1,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":58
}
},
{
"OXMTlv":{
"field":"icmpv6_type",
"value":128
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"icmpv6_type",
"value":135
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34887)",
"mpls(bsb=1, label=100, exp=3, ttl=64)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=58, hop_limit=64, traffic_class=32)",
"icmpv6(code=0,data=echo(data='\\x00\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f !\"#$%&\\'()*+,-./0123'),type_=128)"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=58, hop_limit=64, traffic_class=32)",
"icmpv6(code=0,data=echo(data='\\x00\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f !\"#$%&\\'()*+,-./0123'),type_=135)"
]
}
]
},
{
"description": "ethernet/svlan/itag/ethernet/svlan/vlan/ipv6/icmpv6(type=128)-->'icmpv6_type=128,actions=set_field:135->icmpv6_type,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":58
}
},
{
"OXMTlv":{
"field":"icmpv6_type",
"value":128
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"icmpv6_type",
"value":135
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=58, hop_limit=64, traffic_class=32)",
"icmpv6(code=0,data=echo(data='\\x00\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f !\"#$%&\\'()*+,-./0123'),type_=128)"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=58, hop_limit=64, traffic_class=32)",
"icmpv6(code=0,data=echo(data='\\x00\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f !\"#$%&\\'()*+,-./0123'),type_=135)"
]
}
]
}
]

View File

@ -0,0 +1,340 @@
[
"action: set_field: 30_ICMPV6_CODE",
{
"description": "ethernet/ipv6/icmpv6(code=0)-->'icmpv6_code=0,actions=set_field:1->icmpv6_code,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":58
}
},
{
"OXMTlv":{
"field":"icmpv6_code",
"value":0
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"icmpv6_code",
"value":1
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=58, hop_limit=64, traffic_class=32)",
"icmpv6(code=0,data=echo(data='\\x00\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f !\"#$%&\\'()*+,-./0123'),type_=128)"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=58, hop_limit=64, traffic_class=32)",
"icmpv6(code=1,data=echo(data='\\x00\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f !\"#$%&\\'()*+,-./0123'),type_=128)"
]
}
]
},
{
"description": "ethernet/vlan/ipv6/icmpv6(code=0)-->'icmpv6_code=0,actions=set_field:1->icmpv6_code,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":58
}
},
{
"OXMTlv":{
"field":"icmpv6_code",
"value":0
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"icmpv6_code",
"value":1
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=58, hop_limit=64, traffic_class=32)",
"icmpv6(code=0,data=echo(data='\\x00\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f !\"#$%&\\'()*+,-./0123'),type_=128)"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=58, hop_limit=64, traffic_class=32)",
"icmpv6(code=1,data=echo(data='\\x00\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f !\"#$%&\\'()*+,-./0123'),type_=128)"
]
}
]
},
{
"description": "ethernet/mpls/ipv6/icmpv6(code=0)-->'actions=pop_mpls:0x86dd,goto_table:1','table_id:1,icmpv6_code=0,actions=set_field:1->icmpv6_code,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34887
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionPopMpls":{
"ethertype":34525
}
}
],
"type":4
}
},
{
"OFPInstructionGotoTable":{
"table_id":1
}
}
]
}
},
{
"OFPFlowMod":{
"table_id":1,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":58
}
},
{
"OXMTlv":{
"field":"icmpv6_code",
"value":0
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"icmpv6_code",
"value":1
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34887)",
"mpls(bsb=1, label=100, exp=3, ttl=64)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=58, hop_limit=64, traffic_class=32)",
"icmpv6(code=0,data=echo(data='\\x00\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f !\"#$%&\\'()*+,-./0123'),type_=128)"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=58, hop_limit=64, traffic_class=32)",
"icmpv6(code=1,data=echo(data='\\x00\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f !\"#$%&\\'()*+,-./0123'),type_=128)"
]
}
]
},
{
"description": "ethernet/svlan/itag/ethernet/svlan/vlan/ipv6/icmpv6(code=0)-->'icmpv6_code=0,actions=set_field:1->icmpv6_code,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":58
}
},
{
"OXMTlv":{
"field":"icmpv6_code",
"value":0
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"icmpv6_code",
"value":1
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=58, hop_limit=64, traffic_class=32)",
"icmpv6(code=0,data=echo(data='\\x00\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f !\"#$%&\\'()*+,-./0123'),type_=128)"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=58, hop_limit=64, traffic_class=32)",
"icmpv6(code=1,data=echo(data='\\x00\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f !\"#$%&\\'()*+,-./0123'),type_=128)"
]
}
]
}
]

View File

@ -0,0 +1,364 @@
[
"action: set_field: 31_IPV6_ND_TARGET",
{
"description": "ethernet/ipv6/icmpv6(data=nd_neighbor(dst='20::20'))-->'ipv6_nd_target=20::20,actions=set_field:a0::a0->ipv6_nd_target,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":58
}
},
{
"OXMTlv":{
"field":"icmpv6_type",
"value":135
}
},
{
"OXMTlv":{
"field":"ipv6_nd_target",
"value":"20::20"
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"ipv6_nd_target",
"value":"a0::a0"
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=58, hop_limit=64, traffic_class=32)",
"icmpv6(code=0,data=nd_neighbor(option=nd_option_sla(hw_src='11:11:11:11:11:11'),dst='20::20'),type_=135)"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=58, hop_limit=64, traffic_class=32)",
"icmpv6(code=0,data=nd_neighbor(option=nd_option_sla(hw_src='11:11:11:11:11:11'),dst='a0::a0'),type_=135)"
]
}
]
},
{
"description": "ethernet/vlan/ipv6/icmpv6(data=nd_neighbor(dst='20::20'))-->'ipv6_nd_target=20::20,actions=set_field:a0::a0->ipv6_nd_target,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":58
}
},
{
"OXMTlv":{
"field":"icmpv6_type",
"value":135
}
},
{
"OXMTlv":{
"field":"ipv6_nd_target",
"value":"20::20"
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"ipv6_nd_target",
"value":"a0::a0"
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=58, hop_limit=64, traffic_class=32)",
"icmpv6(code=0,data=nd_neighbor(option=nd_option_sla(hw_src='11:11:11:11:11:11'),dst='20::20'),type_=135)"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=58, hop_limit=64, traffic_class=32)",
"icmpv6(code=0,data=nd_neighbor(option=nd_option_sla(hw_src='11:11:11:11:11:11'),dst='a0::a0'),type_=135)"
]
}
]
},
{
"description": "ethernet/mpls/ipv6/icmpv6(data=nd_neighbor(dst='20::20'))-->'actions=pop_mpls:0x86dd,goto_table:1','table_id:1,ipv6_nd_target=20::20,actions=set_field:a0::a0->ipv6_nd_target,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34887
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionPopMpls":{
"ethertype":34525
}
}
],
"type":4
}
},
{
"OFPInstructionGotoTable":{
"table_id":1
}
}
]
}
},
{
"OFPFlowMod":{
"table_id":1,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":58
}
},
{
"OXMTlv":{
"field":"icmpv6_type",
"value":135
}
},
{
"OXMTlv":{
"field":"ipv6_nd_target",
"value":"20::20"
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"ipv6_nd_target",
"value":"a0::a0"
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34887)",
"mpls(bsb=1, label=100, exp=3, ttl=64)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=58, hop_limit=64, traffic_class=32)",
"icmpv6(code=0,data=nd_neighbor(option=nd_option_sla(hw_src='11:11:11:11:11:11'),dst='20::20'),type_=135)"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=58, hop_limit=64, traffic_class=32)",
"icmpv6(code=0,data=nd_neighbor(option=nd_option_sla(hw_src='11:11:11:11:11:11'),dst='a0::a0'),type_=135)"
]
}
]
},
{
"description": "ethernet/svlan/itag/ethernet/svlan/vlan/ipv6/icmpv6(data=nd_neighbor(dst='20::20'))-->'ipv6_nd_target=20::20,actions=set_field:a0::a0->ipv6_nd_target,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":58
}
},
{
"OXMTlv":{
"field":"icmpv6_type",
"value":135
}
},
{
"OXMTlv":{
"field":"ipv6_nd_target",
"value":"20::20"
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"ipv6_nd_target",
"value":"a0::a0"
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=58, hop_limit=64, traffic_class=32)",
"icmpv6(code=0,data=nd_neighbor(option=nd_option_sla(hw_src='11:11:11:11:11:11'),dst='20::20'),type_=135)"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=58, hop_limit=64, traffic_class=32)",
"icmpv6(code=0,data=nd_neighbor(option=nd_option_sla(hw_src='11:11:11:11:11:11'),dst='a0::a0'),type_=135)"
]
}
]
}
]

View File

@ -0,0 +1,364 @@
[
"action: set_field: 32_IPV6_ND_SLL",
{
"description": "ethernet/ipv6/icmpv6(data=nd_neighbor(option=nd_option_sla(hw_src='11:11:11:11:11:11')))-->'ipv6_nd_sll=11:11:11:11:11:11,actions=set_field:aa:aa:aa:aa:aa:aa->ipv6_nd_sll,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":58
}
},
{
"OXMTlv":{
"field":"icmpv6_type",
"value":135
}
},
{
"OXMTlv":{
"field":"ipv6_nd_sll",
"value":"11:11:11:11:11:11"
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"ipv6_nd_sll",
"value":"aa:aa:aa:aa:aa:aa"
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=58, hop_limit=64, traffic_class=32)",
"icmpv6(code=0,data=nd_neighbor(option=nd_option_sla(hw_src='11:11:11:11:11:11'),dst='20::20'),type_=135)"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=58, hop_limit=64, traffic_class=32)",
"icmpv6(code=0,data=nd_neighbor(option=nd_option_sla(hw_src='aa:aa:aa:aa:aa:aa'),dst='20::20'),type_=135)"
]
}
]
},
{
"description": "ethernet/vlan/ipv6/icmpv6(data=nd_neighbor(option=nd_option_sla(hw_src='11:11:11:11:11:11')))-->'ipv6_nd_sll=11:11:11:111:11,actions=set_field:aa:aa:aa:aa:aa:aa->ipv6_nd_sll,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":58
}
},
{
"OXMTlv":{
"field":"icmpv6_type",
"value":135
}
},
{
"OXMTlv":{
"field":"ipv6_nd_sll",
"value":"11:11:11:11:11:11"
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"ipv6_nd_sll",
"value":"aa:aa:aa:aa:aa:aa"
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=58, hop_limit=64, traffic_class=32)",
"icmpv6(code=0,data=nd_neighbor(option=nd_option_sla(hw_src='11:11:11:11:11:11'),dst='20::20'),type_=135)"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=58, hop_limit=64, traffic_class=32)",
"icmpv6(code=0,data=nd_neighbor(option=nd_option_sla(hw_src='aa:aa:aa:aa:aa:aa'),dst='20::20'),type_=135)"
]
}
]
},
{
"description": "ethernet/mpls/ipv6/icmpv6(data=nd_neighbor(option=nd_option_sla(hw_src='11:11:11:11:11:11')))-->'actions=pop_mpls:0x86dd,goto_table:1','table_id:1,ipv6_nd_sll=11:11:11:11:11:11,actions=set_field:aa:aa:aa:aa:aa:aa->ipv6_nd_sll,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34887
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionPopMpls":{
"ethertype":34525
}
}
],
"type":4
}
},
{
"OFPInstructionGotoTable":{
"table_id":1
}
}
]
}
},
{
"OFPFlowMod":{
"table_id":1,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":58
}
},
{
"OXMTlv":{
"field":"icmpv6_type",
"value":135
}
},
{
"OXMTlv":{
"field":"ipv6_nd_sll",
"value":"11:11:11:11:11:11"
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"ipv6_nd_sll",
"value":"aa:aa:aa:aa:aa:aa"
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34887)",
"mpls(bsb=1, label=100, exp=3, ttl=64)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=58, hop_limit=64, traffic_class=32)",
"icmpv6(code=0,data=nd_neighbor(option=nd_option_sla(hw_src='11:11:11:11:11:11'),dst='20::20'),type_=135)"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=58, hop_limit=64, traffic_class=32)",
"icmpv6(code=0,data=nd_neighbor(option=nd_option_sla(hw_src='aa:aa:aa:aa:aa:aa'),dst='20::20'),type_=135)"
]
}
]
},
{
"description": "ethernet/svlan/itag/ethernet/svlan/vlan/ipv6/icmpv6(data=nd_neighbor(option=nd_option_sla(hw_src='11:11:11:11:11:11')))-->'ipv6_nd_sll=11:11:11:11:11:11,actions=set_field:aa:aa:aa:aa:aa:aa->ipv6_nd_sll,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":58
}
},
{
"OXMTlv":{
"field":"icmpv6_type",
"value":135
}
},
{
"OXMTlv":{
"field":"ipv6_nd_sll",
"value":"11:11:11:11:11:11"
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"ipv6_nd_sll",
"value":"aa:aa:aa:aa:aa:aa"
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=58, hop_limit=64, traffic_class=32)",
"icmpv6(code=0,data=nd_neighbor(option=nd_option_sla(hw_src='11:11:11:11:11:11'),dst='20::20'),type_=135)"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=58, hop_limit=64, traffic_class=32)",
"icmpv6(code=0,data=nd_neighbor(option=nd_option_sla(hw_src='aa:aa:aa:aa:aa:aa'),dst='20::20'),type_=135)"
]
}
]
}
]

View File

@ -0,0 +1,364 @@
[
"action: set_field: 33_IPV6_ND_TLL",
{
"description": "ethernet/ipv6/icmpv6(data=nd_neighbor(option=nd_option_tla(hw_src='11:11:11:11:11:11')))-->'ipv6_nd_tll=11:11:11:11:11:11,actions=set_field:aa:aa:aa:aa:aa:aa->ipv6_nd_tll,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":58
}
},
{
"OXMTlv":{
"field":"icmpv6_type",
"value":136
}
},
{
"OXMTlv":{
"field":"ipv6_nd_tll",
"value":"11:11:11:11:11:11"
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"ipv6_nd_tll",
"value":"aa:aa:aa:aa:aa:aa"
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=58, hop_limit=64, traffic_class=32)",
"icmpv6(code=0,data=nd_neighbor(option=nd_option_tla(hw_src='11:11:11:11:11:11'),dst='20::20'),type_=136)"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=58, hop_limit=64, traffic_class=32)",
"icmpv6(code=0,data=nd_neighbor(option=nd_option_tla(hw_src='aa:aa:aa:aa:aa:aa'),dst='20::20'),type_=136)"
]
}
]
},
{
"description": "ethernet/vlan/ipv6/icmpv6(data=nd_neighbor(option=nd_option_tla(hw_src='11:11:11:11:11:11')))-->'ipv6_nd_tll=11:11:11:111:11,actions=set_field:aa:aa:aa:aa:aa:aa->ipv6_nd_tll,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":58
}
},
{
"OXMTlv":{
"field":"icmpv6_type",
"value":136
}
},
{
"OXMTlv":{
"field":"ipv6_nd_tll",
"value":"11:11:11:11:11:11"
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"ipv6_nd_tll",
"value":"aa:aa:aa:aa:aa:aa"
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=58, hop_limit=64, traffic_class=32)",
"icmpv6(code=0,data=nd_neighbor(option=nd_option_tla(hw_src='11:11:11:11:11:11'),dst='20::20'),type_=136)"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=33024)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=58, hop_limit=64, traffic_class=32)",
"icmpv6(code=0,data=nd_neighbor(option=nd_option_tla(hw_src='aa:aa:aa:aa:aa:aa'),dst='20::20'),type_=136)"
]
}
]
},
{
"description": "ethernet/mpls/ipv6/icmpv6(data=nd_neighbor(option=nd_option_tla(hw_src='11:11:11:11:11:11')))-->'actions=pop_mpls:0x86dd,goto_table:1','table_id:1,ipv6_nd_tll=11:11:11:11:11:11,actions=set_field:aa:aa:aa:aa:aa:aa->ipv6_nd_tll,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34887
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionPopMpls":{
"ethertype":34525
}
}
],
"type":4
}
},
{
"OFPInstructionGotoTable":{
"table_id":1
}
}
]
}
},
{
"OFPFlowMod":{
"table_id":1,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":58
}
},
{
"OXMTlv":{
"field":"icmpv6_type",
"value":136
}
},
{
"OXMTlv":{
"field":"ipv6_nd_tll",
"value":"11:11:11:11:11:11"
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"ipv6_nd_tll",
"value":"aa:aa:aa:aa:aa:aa"
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34887)",
"mpls(bsb=1, label=100, exp=3, ttl=64)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=58, hop_limit=64, traffic_class=32)",
"icmpv6(code=0,data=nd_neighbor(option=nd_option_tla(hw_src='11:11:11:11:11:11'),dst='20::20'),type_=136)"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=58, hop_limit=64, traffic_class=32)",
"icmpv6(code=0,data=nd_neighbor(option=nd_option_tla(hw_src='aa:aa:aa:aa:aa:aa'),dst='20::20'),type_=136)"
]
}
]
},
{
"description": "ethernet/svlan/itag/ethernet/svlan/vlan/ipv6/icmpv6(data=nd_neighbor(option=nd_option_tla(hw_src='11:11:11:11:11:11')))-->'ipv6_nd_tll=11:11:11:11:11:11,actions=set_field:aa:aa:aa:aa:aa:aa->ipv6_nd_tll,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34525
}
},
{
"OXMTlv":{
"field":"ip_proto",
"value":58
}
},
{
"OXMTlv":{
"field":"icmpv6_type",
"value":136
}
},
{
"OXMTlv":{
"field":"ipv6_nd_tll",
"value":"11:11:11:11:11:11"
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"ipv6_nd_tll",
"value":"aa:aa:aa:aa:aa:aa"
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=58, hop_limit=64, traffic_class=32)",
"icmpv6(code=0,data=nd_neighbor(option=nd_option_tla(hw_src='11:11:11:11:11:11'),dst='20::20'),type_=136)"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=58, hop_limit=64, traffic_class=32)",
"icmpv6(code=0,data=nd_neighbor(option=nd_option_tla(hw_src='aa:aa:aa:aa:aa:aa'),dst='20::20'),type_=136)"
]
}
]
}
]

View File

@ -0,0 +1,211 @@
[
"action: set_field: 34_MPLS_LABEL",
{
"description": "ethernet/mpls(label=100)/ipv4/tcp-->'mpls_label=100,actions=set_field:203->mpls_label,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34887
}
},
{
"OXMTlv":{
"field":"mpls_label",
"value":100
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"mpls_label",
"value":203
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34887)",
"mpls(bsb=1, label=100, exp=3, ttl=64)",
"ipv4(tos=32, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34887)",
"mpls(bsb=1, label=203, exp=3, ttl=64)",
"ipv4(tos=32, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/mpls(label=100)/ipv6/tcp-->'mpls_label=100,actions=set_field:203->mpls_label,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34887
}
},
{
"OXMTlv":{
"field":"mpls_label",
"value":100
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"mpls_label",
"value":203
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34887)",
"mpls(bsb=1, label=100, exp=3, ttl=64)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34887)",
"mpls(bsb=1, label=203, exp=3, ttl=64)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/mpls(label=100)/arp-->'mpls_label=100,actions=set_field:203->mpls_label,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34887
}
},
{
"OXMTlv":{
"field":"mpls_label",
"value":100
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"mpls_label",
"value":203
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34887)",
"mpls(bsb=1, label=100, exp=3, ttl=64)",
"arp(dst_ip='192.168.20.20',dst_mac='22:22:22:22:22:22', opcode=1, src_ip='192.168.10.10',src_mac='11:11:11:11:11:11')",
"'\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34887)",
"mpls(bsb=1, label=203, exp=3, ttl=64)",
"arp(dst_ip='192.168.20.20',dst_mac='22:22:22:22:22:22', opcode=1, src_ip='192.168.10.10',src_mac='11:11:11:11:11:11')",
"'\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00'"
]
}
]
}
]

View File

@ -0,0 +1,211 @@
[
"action: set_field: 35_MPLS_TC",
{
"description": "ethernet/mpls(exp=3)/ipv4/tcp-->'mpls_tc=3,actions=set_field:5->mpls_tc,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34887
}
},
{
"OXMTlv":{
"field":"mpls_tc",
"value":3
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"mpls_tc",
"value":5
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34887)",
"mpls(bsb=1, label=100, exp=3, ttl=64)",
"ipv4(tos=32, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34887)",
"mpls(bsb=1, label=100, exp=5, ttl=64)",
"ipv4(tos=32, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/mpls(exp=3)/ipv6/tcp-->'mpls_tc=3,actions=set_field:5->mpls_tc,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34887
}
},
{
"OXMTlv":{
"field":"mpls_tc",
"value":3
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"mpls_tc",
"value":5
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34887)",
"mpls(bsb=1, label=100, exp=3, ttl=64)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34887)",
"mpls(bsb=1, label=100, exp=5, ttl=64)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/mpls(exp=3)/arp-->'mpls_tc=3,actions=set_field:5->mpls_tc,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34887
}
},
{
"OXMTlv":{
"field":"mpls_tc",
"value":3
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"mpls_tc",
"value":5
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34887)",
"mpls(bsb=1, label=100, exp=3, ttl=64)",
"arp(dst_ip='192.168.20.20',dst_mac='22:22:22:22:22:22', opcode=1, src_ip='192.168.10.10',src_mac='11:11:11:11:11:11')",
"'\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34887)",
"mpls(bsb=1, label=100, exp=5, ttl=64)",
"arp(dst_ip='192.168.20.20',dst_mac='22:22:22:22:22:22', opcode=1, src_ip='192.168.10.10',src_mac='11:11:11:11:11:11')",
"'\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00'"
]
}
]
}
]

View File

@ -0,0 +1,211 @@
[
"action: set_field: 36_MPLS_BOS",
{
"description": "ethernet/mpls(bsb=1)/ipv4/tcp-->'mpls_bos=1,actions=set_field:0->mpls_bos,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34887
}
},
{
"OXMTlv":{
"field":"mpls_bos",
"value":1
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"mpls_bos",
"value":0
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34887)",
"mpls(bsb=1, label=100, exp=3, ttl=64)",
"ipv4(tos=32, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34887)",
"mpls(bsb=0, label=100, exp=3, ttl=64)",
"ipv4(tos=32, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/mpls(bsb=1)/ipv6/tcp-->'mpls_bos=1,actions=set_field:0->mpls_bos,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34887
}
},
{
"OXMTlv":{
"field":"mpls_bos",
"value":1
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"mpls_bos",
"value":0
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34887)",
"mpls(bsb=1, label=100, exp=3, ttl=64)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34887)",
"mpls(bsb=0, label=100, exp=3, ttl=64)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/mpls(bsb=1)/arp-->'mpls_bos=1,actions=set_field:0->mpls_bos,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":34887
}
},
{
"OXMTlv":{
"field":"mpls_bos",
"value":1
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"mpls_bos",
"value":0
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34887)",
"mpls(bsb=1, label=100, exp=3, ttl=64)",
"arp(dst_ip='192.168.20.20',dst_mac='22:22:22:22:22:22', opcode=1, src_ip='192.168.10.10',src_mac='11:11:11:11:11:11')",
"'\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34887)",
"mpls(bsb=0, label=100, exp=3, ttl=64)",
"arp(dst_ip='192.168.20.20',dst_mac='22:22:22:22:22:22', opcode=1, src_ip='192.168.10.10',src_mac='11:11:11:11:11:11')",
"'\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00'"
]
}
]
}
]

View File

@ -0,0 +1,235 @@
[
"action: set_field: 37_PBB_ISID",
{
"description": "ethernet/svlan/itag(sid=100)/ethernet/svlan/vlan/ipv4/tcp-->'pbb_itag=100,actions=set_field:203->pbb_itag,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":35047
}
},
{
"OXMTlv":{
"field":"pbb_isid",
"value":100
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"pbb_isid",
"value":203
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2048)",
"ipv4(tos=32, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=203)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2048)",
"ipv4(tos=32, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/svlan/itag(sid=100)/ethernet/svlan/vlan/ipv6/tcp-->'pbb_itag=100,actions=set_field:203->pbb_itag,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":35047
}
},
{
"OXMTlv":{
"field":"pbb_isid",
"value":100
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"pbb_isid",
"value":203
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=203)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/svlan/itag(sid=100)/ethernet/svlan/vlan/arp-->'pbb_itag=100,actions=set_field:203->pbb_itag,output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"eth_type",
"value":35047
}
},
{
"OXMTlv":{
"field":"pbb_isid",
"value":100
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"pbb_isid",
"value":203
}
}
}
},
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=100)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2054)",
"arp(dst_ip='192.168.20.20',dst_mac='22:22:22:22:22:22', opcode=1, src_ip='192.168.10.10',src_mac='11:11:11:11:11:11')",
"'\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=35047, vid=10)",
"itag(sid=203)",
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34984)",
"svlan(ethertype=33024, vid=10)",
"vlan(pcp=3, cfi=0, vid=100, ethertype=2054)",
"arp(dst_ip='192.168.20.20',dst_mac='22:22:22:22:22:22', opcode=1, src_ip='192.168.10.10',src_mac='11:11:11:11:11:11')",
"'\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00'"
]
}
]
}
]

View File

@ -0,0 +1,280 @@
[
"action: set_field: 38_TUNNEL_ID",
{
"description": "ethernet/ipv4/tcp-->'actions=set_field:12345->tunnel_id,goto_table:1','table_id:1,tunnel_id=12345,actions=output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"in_port",
"value":1
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"tunnel_id",
"value":12345
}
}
}
}
],
"type":4
}
},
{
"OFPInstructionGotoTable":{
"table_id":1
}
}
]
}
},
{
"OFPFlowMod":{
"table_id":1,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"tunnel_id",
"value":12345
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2048)",
"ipv4(tos=32, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2048)",
"ipv4(tos=32, proto=6, src='192.168.10.10', dst='192.168.20.20', ttl=64)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/ipv6/tcp-->'actions=set_field:12345->tunnel_id,goto_table:1','table_id:1,tunnel_id=12345,actions=output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"in_port",
"value":1
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"tunnel_id",
"value":12345
}
}
}
}
],
"type":4
}
},
{
"OFPInstructionGotoTable":{
"table_id":1
}
}
]
}
},
{
"OFPFlowMod":{
"table_id":1,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"tunnel_id",
"value":12345
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=34525)",
"ipv6(dst='20::20', flow_label=100, src='10::10', nxt=6, hop_limit=64, traffic_class=32)",
"tcp(dst_port=2222, option='\\x00\\x00\\x00\\x00', src_port=11111)",
"'\\x01\\x02\\x03\\x04\\x05\\x06\\x07\\x08\\t\\n\\x0b\\x0c\\r\\x0e\\x0f\\x10\\x11\\x12\\x13\\x14\\x15\\x16\\x17\\x18\\x19\\x1a\\x1b\\x1c\\x1d\\x1e\\x1f'"
]
}
]
},
{
"description": "ethernet/arp-->'actions=set_field:12345->tunnel_id,goto_table:1','table_id:1,tunnel_id=12345,actions=output:2'",
"prerequisite":[
{
"OFPFlowMod":{
"table_id":0,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"in_port",
"value":1
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionSetField":{
"field":{
"OXMTlv":{
"field":"tunnel_id",
"value":12345
}
}
}
}
],
"type":4
}
},
{
"OFPInstructionGotoTable":{
"table_id":1
}
}
]
}
},
{
"OFPFlowMod":{
"table_id":1,
"match":{
"OFPMatch":{
"oxm_fields":[
{
"OXMTlv":{
"field":"tunnel_id",
"value":12345
}
}
]
}
},
"instructions":[
{
"OFPInstructionActions":{
"actions":[
{
"OFPActionOutput":{
"port":2
}
}
],
"type":4
}
}
]
}
}
],
"tests":[
{
"ingress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2054)",
"arp(dst_ip='192.168.20.20',dst_mac='22:22:22:22:22:22', opcode=1, src_ip='192.168.10.10',src_mac='11:11:11:11:11:11')",
"'\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00'"
],
"egress":[
"ethernet(dst='22:22:22:22:22:22', src='11:11:11:11:11:11', ethertype=2054)",
"arp(dst_ip='192.168.20.20',dst_mac='22:22:22:22:22:22', opcode=1, src_ip='192.168.10.10',src_mac='11:11:11:11:11:11')",
"'\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00'"
]
}
]
}
]