Commit 1d33a3e
committed
vpp: support binding multiple ACL tables by priority (#1732)
why
currently vpp doesn't support binding multiple ACL tables. Each table is appended with default permit-all rules. With multiple tables, this may cause acl matched by such rules and skip the actual rule to make in the tables after this one.
what this PR does
remove the default permit-all rules for each table
If a table is empty, create a dummy rule that won't match any traffic because vpp doesn't allow empty table. The dummy rule matches dest-ip to 0.0.0.0/32
sort all the tables by priority in the table group. vpp doesn't support parallel matching
added catch-all acl group to the end. vpp default behavior of no match is drop but sonic is accept.
Fix sonic-vpp crashing due to race condition during stats pull. If the interface to get stats has been removed, stat_segment_ls_r returns null.
Signed-off-by: Yue Gao <yuega2@cisco.com>1 parent feaa910 commit 1d33a3e
3 files changed
Lines changed: 204 additions & 82 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
622 | 622 | | |
623 | 623 | | |
624 | 624 | | |
| 625 | + | |
| 626 | + | |
| 627 | + | |
625 | 628 | | |
626 | 629 | | |
627 | 630 | | |
| |||
804 | 807 | | |
805 | 808 | | |
806 | 809 | | |
807 | | - | |
| 810 | + | |
808 | 811 | | |
809 | 812 | | |
| 813 | + | |
| 814 | + | |
810 | 815 | | |
811 | 816 | | |
812 | 817 | | |
| |||
0 commit comments