Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[aclorch] Add ACL_TABLE_TYPE configuration #1982

Merged
merged 40 commits into from
Nov 23, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
40 commits
Select commit Hold shift + click to select a range
2fa988e
[aclorch] Add ACL_TABLE_TYPE configuration
stepanblyschak Oct 19, 2021
0e85da1
refactor acl range match validation
stepanblyschak Oct 21, 2021
99eaca9
internal review comments
stepanblyschak Oct 22, 2021
1a34188
make getAttributeIdName static
stepanblyschak Oct 22, 2021
c1b3947
[aclorch] remove IN_PORTS, OUT_PORTS from L3 tables. Fix VS tests as …
stepanblyschak Oct 25, 2021
743027b
update doc
stepanblyschak Oct 29, 2021
6dd517f
Merge branch 'master' of github.com:azure/sonic-swss into acl_table_type
stepanblyschak Nov 10, 2021
823986d
JUST FOR TEST
stepanblyschak Nov 10, 2021
f74917b
Merge branch 'master' of github.com:azure/sonic-swss into acl_table_type
stepanblyschak Nov 11, 2021
ea5acfe
Revert "JUST FOR TEST"
stepanblyschak Nov 11, 2021
a8508c1
split in out ports tests
stepanblyschak Nov 11, 2021
1434140
[temporary] print git status and commit hash before build to check if…
stepanblyschak Nov 11, 2021
4caf56e
Revert "[temporary] print git status and commit hash before build to …
stepanblyschak Nov 11, 2021
01cfa90
[temporary] add throw message for debug on ci
stepanblyschak Nov 11, 2021
ebe36ee
Revert "[temporary] add throw message for debug on ci"
stepanblyschak Nov 11, 2021
8c54a14
temporary disable the check for action list
stepanblyschak Nov 11, 2021
e35b5a9
Revert "temporary disable the check for action list"
stepanblyschak Nov 11, 2021
7c96d4e
temporary disable check
stepanblyschak Nov 17, 2021
566fbbd
add missing fields in L3 table
stepanblyschak Nov 17, 2021
fbbb6f2
remove ETHER_TYPE from V6 table types
stepanblyschak Nov 17, 2021
03a9d61
remove a test case test_AclBindMirrorV6WrongConfig because IPv6 rules…
stepanblyschak Nov 17, 2021
381a73d
Revert "temporary disable check"
stepanblyschak Nov 17, 2021
056cbd9
Revert "add missing fields in L3 table"
stepanblyschak Nov 17, 2021
5667e64
change test_acl_egress_table to work with table types
stepanblyschak Nov 17, 2021
2a4d63e
add a table with matches and mirror table types
stepanblyschak Nov 18, 2021
fe09424
add libgmock-dev
stepanblyschak Nov 18, 2021
e2b1d3e
Revert "add libgmock-dev"
stepanblyschak Nov 18, 2021
9b08a82
Merge branch 'master' into acl_table_type
stepanblyschak Nov 19, 2021
8264834
fix conflicts
stepanblyschak Nov 22, 2021
49f9dbd
fix conflicts
stepanblyschak Nov 22, 2021
a01ec61
fix conflicts
stepanblyschak Nov 22, 2021
1717a70
fix conflicts
stepanblyschak Nov 22, 2021
be32561
fix conflicts
stepanblyschak Nov 22, 2021
bf41eb4
fix conflicts
stepanblyschak Nov 22, 2021
869cd7e
fix conflicts
stepanblyschak Nov 22, 2021
aabdd8c
fix conflicts
stepanblyschak Nov 22, 2021
f49fb54
fix conflicts
stepanblyschak Nov 22, 2021
c7e8ac0
fix conflicts
stepanblyschak Nov 22, 2021
70d2c7d
fix conflicts
stepanblyschak Nov 22, 2021
ec26e51
Merge branch 'acl_table_type' of github.com:stepanblyschak/sonic-swss…
stepanblyschak Nov 22, 2021
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
40 changes: 40 additions & 0 deletions doc/Configuration.md
Original file line number Diff line number Diff line change
Expand Up @@ -286,6 +286,46 @@ and migration plan

```

***ACL table type configuration example***
```
{
"ACL_TABLE_TYPE": {
"CUSTOM_L3": {
"MATCHES": [
"IN_PORTS",
"OUT_PORTS",
"SRC_IP"
],
"ACTIONS": [
"PACKET_ACTION",
"MIRROR_INGRESS_ACTION"
],
"BIND_POINTS": [
"PORT",
"LAG"
]
}
},
"ACL_TABLE": {
"DATAACL": {
"STAGE": "INGRESS",
"TYPE": "CUSTOM_L3",
"PORTS": [
"Ethernet0",
"PortChannel1"
]
}
},
"ACL_RULE": {
"DATAACL|RULE0": {
"PRIORITY": "999",
"PACKET_ACTION": "DROP",
"SRC_IP": "1.1.1.1/32",
}
}
}
```

### BGP Sessions

BGP session configuration is defined in **BGP_NEIGHBOR** table. BGP
Expand Down
24 changes: 23 additions & 1 deletion doc/swss-schema.md
Original file line number Diff line number Diff line change
Expand Up @@ -569,15 +569,37 @@ It's possible to create separate configuration files for different ASIC platform

----------------------------------------------

### ACL\_TABLE\_TYPE
Stores a definition of table - set of matches, actions and bind point types. ACL_TABLE references a key inside this table in "type" field.

```
key: ACL_TABLE_TYPE:name ; key of the ACL table type entry. The name is arbitary name user chooses.
; field = value
matches = match-list ; list of matches for this table, matches are same as in ACL_RULE table.
actions = action-list ; list of actions for this table, actions are same as in ACL_RULE table.
bind_points = bind-points-list ; list of bind point types for this table.

; values annotation
match = 1*64VCHAR
match-list = [1-max-matches]*match
action = 1*64VCHAR
action-list = [1-max-actions]*action
bind-point = port/lag
bind-points-list = [1-max-bind-points]*bind-point
```

### ACL\_TABLE
Stores information about ACL tables on the switch. Port names are defined in [port_config.ini](../portsyncd/port_config.ini).

key = ACL_TABLE:name ; acl_table_name must be unique
;field = value
policy_desc = 1*255VCHAR ; name of the ACL policy table description
type = "mirror"/"l3"/"l3v6" ; type of acl table, every type of
type = 1*255VCHAR ; type of acl table, every type of
; table defines the match/action a
; specific set of match and actions.
; There are pre-defined table types like
; "MIRROR", "MIRRORV6", "MIRROR_DSCP",
; "L3", "L3V6", "MCLAG", "PFCWD", "DROP".
ports = [0-max_ports]*port_name ; the ports to which this ACL
; table is applied, can be emtry
; value annotations
Expand Down
Loading