[minigraph-parser] Update the definition of acl table type BMCDATA and BMCDATAV6 (#16249)
Why I did it According to ACL-Table-Type-HLD, the value type of MATCHES, ACTIONS and BIND_POINTS should be list instead of string. Opening this PR to update the definition of BMCDATA and BMCDATAV6. How I did it Update the definition of BMCDATA and BMCDATAV6 in minigraph-parser. How to verify it Verified by UT and build SONiC image.
This commit is contained in:
parent
82fa2d6a26
commit
2941df3289
@ -54,14 +54,14 @@ vni_default = 8000
|
|||||||
# Defination of custom acl table types
|
# Defination of custom acl table types
|
||||||
acl_table_type_defination = {
|
acl_table_type_defination = {
|
||||||
'BMCDATA': {
|
'BMCDATA': {
|
||||||
"ACTIONS": "PACKET_ACTION,COUNTER",
|
"ACTIONS": ["PACKET_ACTION", "COUNTER"],
|
||||||
"BIND_POINTS": "PORT",
|
"BIND_POINTS": ["PORT"],
|
||||||
"MATCHES": "SRC_IP,DST_IP,ETHER_TYPE,IP_TYPE,IP_PROTOCOL,IN_PORTS,L4_SRC_PORT,L4_DST_PORT,L4_SRC_PORT_RANGE,L4_DST_PORT_RANGE",
|
"MATCHES": ["SRC_IP", "DST_IP", "ETHER_TYPE", "IP_TYPE", "IP_PROTOCOL", "IN_PORTS", "L4_SRC_PORT", "L4_DST_PORT", "L4_SRC_PORT_RANGE", "L4_DST_PORT_RANGE"]
|
||||||
},
|
},
|
||||||
'BMCDATAV6': {
|
'BMCDATAV6': {
|
||||||
"ACTIONS": "PACKET_ACTION,COUNTER",
|
"ACTIONS": ["PACKET_ACTION", "COUNTER"],
|
||||||
"BIND_POINTS": "PORT",
|
"BIND_POINTS": ["PORT"],
|
||||||
"MATCHES": "SRC_IPV6,DST_IPV6,ETHER_TYPE,IP_TYPE,IP_PROTOCOL,IN_PORTS,L4_SRC_PORT,L4_DST_PORT,L4_SRC_PORT_RANGE,L4_DST_PORT_RANGE",
|
"MATCHES": ["SRC_IPV6", "DST_IPV6", "ETHER_TYPE", "IP_TYPE", "IP_PROTOCOL", "IN_PORTS", "L4_SRC_PORT", "L4_DST_PORT", "L4_SRC_PORT_RANGE", "L4_DST_PORT_RANGE"]
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -497,14 +497,14 @@ class TestCfgGenCaseInsensitive(TestCase):
|
|||||||
|
|
||||||
def test_minigraph_acl_type_bmcdata(self):
|
def test_minigraph_acl_type_bmcdata(self):
|
||||||
expected_acl_type_bmcdata = {
|
expected_acl_type_bmcdata = {
|
||||||
"ACTIONS": "PACKET_ACTION,COUNTER",
|
"ACTIONS": ["PACKET_ACTION", "COUNTER"],
|
||||||
"BIND_POINTS": "PORT",
|
"BIND_POINTS": ["PORT"],
|
||||||
"MATCHES": "SRC_IP,DST_IP,ETHER_TYPE,IP_TYPE,IP_PROTOCOL,IN_PORTS,L4_SRC_PORT,L4_DST_PORT,L4_SRC_PORT_RANGE,L4_DST_PORT_RANGE",
|
"MATCHES": ["SRC_IP", "DST_IP", "ETHER_TYPE", "IP_TYPE", "IP_PROTOCOL", "IN_PORTS", "L4_SRC_PORT", "L4_DST_PORT", "L4_SRC_PORT_RANGE", "L4_DST_PORT_RANGE"],
|
||||||
}
|
}
|
||||||
expected_acl_type_bmcdatav6 = {
|
expected_acl_type_bmcdatav6 = {
|
||||||
"ACTIONS": "PACKET_ACTION,COUNTER",
|
"ACTIONS": ["PACKET_ACTION", "COUNTER"],
|
||||||
"BIND_POINTS": "PORT",
|
"BIND_POINTS": ["PORT"],
|
||||||
"MATCHES": "SRC_IPV6,DST_IPV6,ETHER_TYPE,IP_TYPE,IP_PROTOCOL,IN_PORTS,L4_SRC_PORT,L4_DST_PORT,L4_SRC_PORT_RANGE,L4_DST_PORT_RANGE",
|
"MATCHES": ["SRC_IPV6", "DST_IPV6", "ETHER_TYPE", "IP_TYPE", "IP_PROTOCOL", "IN_PORTS", "L4_SRC_PORT", "L4_DST_PORT", "L4_SRC_PORT_RANGE", "L4_DST_PORT_RANGE"],
|
||||||
}
|
}
|
||||||
expected_acl_table_bmc_acl_northbound = {
|
expected_acl_table_bmc_acl_northbound = {
|
||||||
'policy_desc': 'BMC_ACL_NORTHBOUND',
|
'policy_desc': 'BMC_ACL_NORTHBOUND',
|
||||||
|
Loading…
Reference in New Issue
Block a user