Tolerate failures when setting MTU
[csit.git] / resources / test_data / honeycomb / acl.py
1 # Copyright (c) 2016 Cisco and/or its affiliates.
2 # Licensed under the Apache License, Version 2.0 (the "License");
3 # you may not use this file except in compliance with the License.
4 # You may obtain a copy of the License at:
5 #
6 #     http://www.apache.org/licenses/LICENSE-2.0
7 #
8 # Unless required by applicable law or agreed to in writing, software
9 # distributed under the License is distributed on an "AS IS" BASIS,
10 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
11 # See the License for the specific language governing permissions and
12 # limitations under the License.
13
14 """Test variables for access control list test suite."""
15
16 # settings for acl tables
17 hc_acl_table = {
18     "name": "acl_table_test",
19     "nbuckets": 1,
20     "memory_size": 1048576,
21     "skip_n_vectors": 0,
22     "miss_next": "permit",
23     "mask": "00:00:00:00:00:00:ff:ff:ff:ff:ff:ff:00:00:00:00"
24 }
25
26 hc_acl_table2 = {
27     "name": "acl_table_test2",
28     "nbuckets": 2,
29     "memory_size": 1048576,
30     "skip_n_vectors": 1,
31     "next_table": "acl_table_test",
32     "miss_next": "deny",
33     "mask": "ff:ff:ff:00:00:00:ff:ff:ff:ff:ff:ff:00:00:00:00"
34 }
35
36 #TODO: remove once memory_size is visible in oper data(HC2VPP-10)
37 hc_acl_table_oper = {
38     "name": "acl_table_test",
39     "nbuckets": 1,
40     "skip_n_vectors": 0,
41     "miss_next": "permit",
42     "mask": "00:00:00:00:00:00:ff:ff:ff:ff:ff:ff:00:00:00:00"
43 }
44
45 hc_acl_table2_oper = {
46     "name": "acl_table_test2",
47     "nbuckets": 2,
48     "skip_n_vectors": 1,
49     "next_table": "acl_table_test",
50     "miss_next": "deny",
51     "mask": "ff:ff:ff:00:00:00:ff:ff:ff:ff:ff:ff:00:00:00:00"
52 }
53
54 # representation of table settings in VAT
55 table_index = 0
56 vat_acl_table = {
57     "nbuckets": hc_acl_table['nbuckets'],
58     "skip": 0,
59     "match": 1,
60     "nextnode": -1,
61     "nexttbl": -1,
62     "mask": hc_acl_table['mask'].replace(":", ""),
63 }
64 table_index2 = 1
65 vat_acl_table2 = {
66     "nbuckets": hc_acl_table2['nbuckets'],
67     "skip": 1,
68     "match": 1,
69     "nextnode": 0,
70     "nexttbl": table_index,
71     "mask": hc_acl_table2['mask'].replace(":", ""),
72 }
73 # setting for acl sessions
74 hc_acl_session = {
75     "match": "00:00:00:00:00:00:01:02:03:04:05:06:00:00:00:00",
76     "hit_next": "permit",
77     "opaque_index": 1,
78     "advance": 1
79 }
80
81 hc_acl_session2 = {
82     "match": "00:00:00:00:00:00:06:05:04:03:02:01:00:00:00:00",
83     "hit_next": "deny",
84     "opaque_index": 2,
85     "advance": 1
86 }
87 # representation of session settings in VAT
88 session_index = 0
89 vat_acl_session = {
90     "match": hc_acl_session['match'].replace(":", ""),
91     "advance": hc_acl_session['advance'],
92     "opaque": 1,
93     "next_index": -1
94 }
95 session_index2 = 1
96 vat_acl_session2 = {
97     "match": hc_acl_session2['match'].replace(":", ""),
98     "advance": hc_acl_session2['advance'],
99     "opaque": 2,
100     "next_index": session_index
101 }