mirror of
https://github.com/ansible-collections/community.routeros.git
synced 2025-06-21 17:39:04 +02:00
Fixes #236: Add missing parameters for the "ip firewall" subpaths and set the default value for the "disabled" parameter for most paths (#237)
* Fixes #236: Add missing parameters The parameters "address-list", "address-list-timeout", and "realm" were missing for some subpaths of "ip firewall" and are now added. Additionally the default value of "False" for the "disabled" parameter has been set so that an e.g. firewall rule, which was disabled (disabled=True) is enabled (disabled=False) after removing the "disabled" argument in the data. Some more parameters can now be removed, e.g. "jump-target", "log", and "log-prefix", which are not mandatory. * Add missing changes for #236 Additionally fixed the PR id in the changelog fragment. * Update changelogs/fragments/237-add-missing-ip-firewall-attributes.yml Full stop added at the end of the changelog fragment Co-authored-by: Felix Fontein <felix@fontein.de> * Update changelogs/fragments/237-add-missing-ip-firewall-attributes.yml Full stop added at the end of the changelog fragment Co-authored-by: Felix Fontein <felix@fontein.de> * Fix unit tests --------- Co-authored-by: Johannes Münch <git@washiza.eu> Co-authored-by: Felix Fontein <felix@fontein.de>
This commit is contained in:
parent
7de154e907
commit
ad6faf275d
4 changed files with 59 additions and 34 deletions
|
@ -0,0 +1,3 @@
|
||||||
|
minor_changes:
|
||||||
|
- api_info, api_modify - add missing parameters ``address-list``, ``address-list-timeout``, ``randomise-ports``, and ``realm`` to subpaths of the ``ip firewall`` path (https://github.com/ansible-collections/community.routeros/issues/236, https://github.com/ansible-collections/community.routeros/pull/237).
|
||||||
|
- api_info, api_modify - set the default value to ``false`` for the ``disabled`` parameter in some more paths where it can be seen in the documentation (https://github.com/ansible-collections/community.routeros/pull/237).
|
|
@ -959,7 +959,7 @@ PATHS = {
|
||||||
fields={
|
fields={
|
||||||
'name': KeyInfo(required=True),
|
'name': KeyInfo(required=True),
|
||||||
'comment': KeyInfo(can_disable=True, remove_value=''),
|
'comment': KeyInfo(can_disable=True, remove_value=''),
|
||||||
'disabled': KeyInfo(can_disable=True),
|
'disabled': KeyInfo(default=False),
|
||||||
'fib': KeyInfo(),
|
'fib': KeyInfo(),
|
||||||
},
|
},
|
||||||
)),
|
)),
|
||||||
|
@ -1007,7 +1007,7 @@ PATHS = {
|
||||||
'client-to-client-forwarding': KeyInfo(can_disable=True),
|
'client-to-client-forwarding': KeyInfo(can_disable=True),
|
||||||
'client-tx-limit': KeyInfo(can_disable=True),
|
'client-tx-limit': KeyInfo(can_disable=True),
|
||||||
'comment': KeyInfo(can_disable=True, remove_value=''),
|
'comment': KeyInfo(can_disable=True, remove_value=''),
|
||||||
'disabled': KeyInfo(),
|
'disabled': KeyInfo(default=False),
|
||||||
'interface': KeyInfo(can_disable=True),
|
'interface': KeyInfo(can_disable=True),
|
||||||
'mac-address': KeyInfo(can_disable=True),
|
'mac-address': KeyInfo(can_disable=True),
|
||||||
'mac-address-mask': KeyInfo(can_disable=True),
|
'mac-address-mask': KeyInfo(can_disable=True),
|
||||||
|
@ -1941,6 +1941,8 @@ PATHS = {
|
||||||
stratify_keys=('chain', ),
|
stratify_keys=('chain', ),
|
||||||
fields={
|
fields={
|
||||||
'action': KeyInfo(),
|
'action': KeyInfo(),
|
||||||
|
'address-list': KeyInfo(can_disable=True),
|
||||||
|
'address-list-timeout': KeyInfo(can_disable=True),
|
||||||
'chain': KeyInfo(),
|
'chain': KeyInfo(),
|
||||||
'comment': KeyInfo(can_disable=True, remove_value=''),
|
'comment': KeyInfo(can_disable=True, remove_value=''),
|
||||||
'connection-bytes': KeyInfo(can_disable=True),
|
'connection-bytes': KeyInfo(can_disable=True),
|
||||||
|
@ -1951,7 +1953,7 @@ PATHS = {
|
||||||
'connection-state': KeyInfo(can_disable=True),
|
'connection-state': KeyInfo(can_disable=True),
|
||||||
'connection-type': KeyInfo(can_disable=True),
|
'connection-type': KeyInfo(can_disable=True),
|
||||||
'content': KeyInfo(can_disable=True),
|
'content': KeyInfo(can_disable=True),
|
||||||
'disabled': KeyInfo(),
|
'disabled': KeyInfo(default=False),
|
||||||
'dscp': KeyInfo(can_disable=True),
|
'dscp': KeyInfo(can_disable=True),
|
||||||
'dst-address': KeyInfo(can_disable=True),
|
'dst-address': KeyInfo(can_disable=True),
|
||||||
'dst-address-list': KeyInfo(can_disable=True),
|
'dst-address-list': KeyInfo(can_disable=True),
|
||||||
|
@ -1969,11 +1971,11 @@ PATHS = {
|
||||||
'ingress-priority': KeyInfo(can_disable=True),
|
'ingress-priority': KeyInfo(can_disable=True),
|
||||||
'ipsec-policy': KeyInfo(can_disable=True),
|
'ipsec-policy': KeyInfo(can_disable=True),
|
||||||
'ipv4-options': KeyInfo(can_disable=True),
|
'ipv4-options': KeyInfo(can_disable=True),
|
||||||
'jump-target': KeyInfo(),
|
'jump-target': KeyInfo(can_disable=True),
|
||||||
'layer7-protocol': KeyInfo(can_disable=True),
|
'layer7-protocol': KeyInfo(can_disable=True),
|
||||||
'limit': KeyInfo(can_disable=True),
|
'limit': KeyInfo(can_disable=True),
|
||||||
'log': KeyInfo(),
|
'log': KeyInfo(can_disable=True),
|
||||||
'log-prefix': KeyInfo(),
|
'log-prefix': KeyInfo(can_disable=True),
|
||||||
'nth': KeyInfo(can_disable=True),
|
'nth': KeyInfo(can_disable=True),
|
||||||
'out-bridge-port': KeyInfo(can_disable=True),
|
'out-bridge-port': KeyInfo(can_disable=True),
|
||||||
'out-bridge-port-list': KeyInfo(can_disable=True),
|
'out-bridge-port-list': KeyInfo(can_disable=True),
|
||||||
|
@ -1988,7 +1990,8 @@ PATHS = {
|
||||||
'protocol': KeyInfo(can_disable=True),
|
'protocol': KeyInfo(can_disable=True),
|
||||||
'psd': KeyInfo(can_disable=True),
|
'psd': KeyInfo(can_disable=True),
|
||||||
'random': KeyInfo(can_disable=True),
|
'random': KeyInfo(can_disable=True),
|
||||||
'reject-with': KeyInfo(),
|
'realm': KeyInfo(can_disable=True),
|
||||||
|
'reject-with': KeyInfo(can_disable=True),
|
||||||
'routing-mark': KeyInfo(can_disable=True),
|
'routing-mark': KeyInfo(can_disable=True),
|
||||||
'routing-table': KeyInfo(can_disable=True),
|
'routing-table': KeyInfo(can_disable=True),
|
||||||
'src-address': KeyInfo(can_disable=True),
|
'src-address': KeyInfo(can_disable=True),
|
||||||
|
@ -2010,6 +2013,8 @@ PATHS = {
|
||||||
stratify_keys=('chain', ),
|
stratify_keys=('chain', ),
|
||||||
fields={
|
fields={
|
||||||
'action': KeyInfo(),
|
'action': KeyInfo(),
|
||||||
|
'address-list': KeyInfo(can_disable=True),
|
||||||
|
'address-list-timeout': KeyInfo(can_disable=True),
|
||||||
'chain': KeyInfo(),
|
'chain': KeyInfo(),
|
||||||
'comment': KeyInfo(can_disable=True, remove_value=''),
|
'comment': KeyInfo(can_disable=True, remove_value=''),
|
||||||
'connection-bytes': KeyInfo(can_disable=True),
|
'connection-bytes': KeyInfo(can_disable=True),
|
||||||
|
@ -2020,7 +2025,7 @@ PATHS = {
|
||||||
'connection-state': KeyInfo(can_disable=True),
|
'connection-state': KeyInfo(can_disable=True),
|
||||||
'connection-type': KeyInfo(can_disable=True),
|
'connection-type': KeyInfo(can_disable=True),
|
||||||
'content': KeyInfo(can_disable=True),
|
'content': KeyInfo(can_disable=True),
|
||||||
'disabled': KeyInfo(),
|
'disabled': KeyInfo(default=False),
|
||||||
'dscp': KeyInfo(can_disable=True),
|
'dscp': KeyInfo(can_disable=True),
|
||||||
'dst-address': KeyInfo(can_disable=True),
|
'dst-address': KeyInfo(can_disable=True),
|
||||||
'dst-address-list': KeyInfo(can_disable=True),
|
'dst-address-list': KeyInfo(can_disable=True),
|
||||||
|
@ -2037,11 +2042,11 @@ PATHS = {
|
||||||
'ingress-priority': KeyInfo(can_disable=True),
|
'ingress-priority': KeyInfo(can_disable=True),
|
||||||
'ipsec-policy': KeyInfo(can_disable=True),
|
'ipsec-policy': KeyInfo(can_disable=True),
|
||||||
'ipv4-options': KeyInfo(can_disable=True),
|
'ipv4-options': KeyInfo(can_disable=True),
|
||||||
'jump-target': KeyInfo(),
|
'jump-target': KeyInfo(can_disable=True),
|
||||||
'layer7-protocol': KeyInfo(can_disable=True),
|
'layer7-protocol': KeyInfo(can_disable=True),
|
||||||
'limit': KeyInfo(can_disable=True),
|
'limit': KeyInfo(can_disable=True),
|
||||||
'log': KeyInfo(),
|
'log': KeyInfo(can_disable=True),
|
||||||
'log-prefix': KeyInfo(),
|
'log-prefix': KeyInfo(can_disable=True),
|
||||||
'new-connection-mark': KeyInfo(can_disable=True),
|
'new-connection-mark': KeyInfo(can_disable=True),
|
||||||
'new-dscp': KeyInfo(can_disable=True),
|
'new-dscp': KeyInfo(can_disable=True),
|
||||||
'new-mss': KeyInfo(can_disable=True),
|
'new-mss': KeyInfo(can_disable=True),
|
||||||
|
@ -2064,6 +2069,7 @@ PATHS = {
|
||||||
'protocol': KeyInfo(can_disable=True),
|
'protocol': KeyInfo(can_disable=True),
|
||||||
'psd': KeyInfo(can_disable=True),
|
'psd': KeyInfo(can_disable=True),
|
||||||
'random': KeyInfo(can_disable=True),
|
'random': KeyInfo(can_disable=True),
|
||||||
|
'realm': KeyInfo(can_disable=True),
|
||||||
'route-dst': KeyInfo(can_disable=True),
|
'route-dst': KeyInfo(can_disable=True),
|
||||||
'routing-mark': KeyInfo(can_disable=True),
|
'routing-mark': KeyInfo(can_disable=True),
|
||||||
'routing-table': KeyInfo(can_disable=True),
|
'routing-table': KeyInfo(can_disable=True),
|
||||||
|
@ -2089,8 +2095,8 @@ PATHS = {
|
||||||
stratify_keys=('chain', ),
|
stratify_keys=('chain', ),
|
||||||
fields={
|
fields={
|
||||||
'action': KeyInfo(),
|
'action': KeyInfo(),
|
||||||
'address-list': KeyInfo(),
|
'address-list': KeyInfo(can_disable=True),
|
||||||
'address-list-timeout': KeyInfo(),
|
'address-list-timeout': KeyInfo(can_disable=True),
|
||||||
'chain': KeyInfo(),
|
'chain': KeyInfo(),
|
||||||
'comment': KeyInfo(can_disable=True, remove_value=''),
|
'comment': KeyInfo(can_disable=True, remove_value=''),
|
||||||
'connection-bytes': KeyInfo(can_disable=True),
|
'connection-bytes': KeyInfo(can_disable=True),
|
||||||
|
@ -2099,7 +2105,7 @@ PATHS = {
|
||||||
'connection-rate': KeyInfo(can_disable=True),
|
'connection-rate': KeyInfo(can_disable=True),
|
||||||
'connection-type': KeyInfo(can_disable=True),
|
'connection-type': KeyInfo(can_disable=True),
|
||||||
'content': KeyInfo(can_disable=True),
|
'content': KeyInfo(can_disable=True),
|
||||||
'disabled': KeyInfo(),
|
'disabled': KeyInfo(default=False),
|
||||||
'dscp': KeyInfo(can_disable=True),
|
'dscp': KeyInfo(can_disable=True),
|
||||||
'dst-address': KeyInfo(can_disable=True),
|
'dst-address': KeyInfo(can_disable=True),
|
||||||
'dst-address-list': KeyInfo(can_disable=True),
|
'dst-address-list': KeyInfo(can_disable=True),
|
||||||
|
@ -2116,11 +2122,11 @@ PATHS = {
|
||||||
'ingress-priority': KeyInfo(can_disable=True),
|
'ingress-priority': KeyInfo(can_disable=True),
|
||||||
'ipsec-policy': KeyInfo(can_disable=True),
|
'ipsec-policy': KeyInfo(can_disable=True),
|
||||||
'ipv4-options': KeyInfo(can_disable=True),
|
'ipv4-options': KeyInfo(can_disable=True),
|
||||||
'jump-target': KeyInfo(),
|
'jump-target': KeyInfo(can_disable=True),
|
||||||
'layer7-protocol': KeyInfo(can_disable=True),
|
'layer7-protocol': KeyInfo(can_disable=True),
|
||||||
'limit': KeyInfo(can_disable=True),
|
'limit': KeyInfo(can_disable=True),
|
||||||
'log': KeyInfo(),
|
'log': KeyInfo(can_disable=True),
|
||||||
'log-prefix': KeyInfo(),
|
'log-prefix': KeyInfo(can_disable=True),
|
||||||
'nth': KeyInfo(can_disable=True),
|
'nth': KeyInfo(can_disable=True),
|
||||||
'out-bridge-port': KeyInfo(can_disable=True),
|
'out-bridge-port': KeyInfo(can_disable=True),
|
||||||
'out-bridge-port-list': KeyInfo(can_disable=True),
|
'out-bridge-port-list': KeyInfo(can_disable=True),
|
||||||
|
@ -2134,9 +2140,10 @@ PATHS = {
|
||||||
'protocol': KeyInfo(can_disable=True),
|
'protocol': KeyInfo(can_disable=True),
|
||||||
'psd': KeyInfo(can_disable=True),
|
'psd': KeyInfo(can_disable=True),
|
||||||
'random': KeyInfo(can_disable=True),
|
'random': KeyInfo(can_disable=True),
|
||||||
|
'randomise-ports': KeyInfo(can_disable=True),
|
||||||
'realm': KeyInfo(can_disable=True),
|
'realm': KeyInfo(can_disable=True),
|
||||||
'routing-mark': KeyInfo(can_disable=True),
|
'routing-mark': KeyInfo(can_disable=True),
|
||||||
'same-not-by-dst': KeyInfo(),
|
'same-not-by-dst': KeyInfo(can_disable=True),
|
||||||
'src-address': KeyInfo(can_disable=True),
|
'src-address': KeyInfo(can_disable=True),
|
||||||
'src-address-list': KeyInfo(can_disable=True),
|
'src-address-list': KeyInfo(can_disable=True),
|
||||||
'src-address-type': KeyInfo(can_disable=True),
|
'src-address-type': KeyInfo(can_disable=True),
|
||||||
|
@ -2157,12 +2164,12 @@ PATHS = {
|
||||||
stratify_keys=('chain',),
|
stratify_keys=('chain',),
|
||||||
fields={
|
fields={
|
||||||
'action': KeyInfo(),
|
'action': KeyInfo(),
|
||||||
'address-list': KeyInfo(),
|
'address-list': KeyInfo(can_disable=True),
|
||||||
'address-list-timeout': KeyInfo(),
|
'address-list-timeout': KeyInfo(can_disable=True),
|
||||||
'chain': KeyInfo(),
|
'chain': KeyInfo(),
|
||||||
'comment': KeyInfo(can_disable=True, remove_value=''),
|
'comment': KeyInfo(can_disable=True, remove_value=''),
|
||||||
'content': KeyInfo(can_disable=True),
|
'content': KeyInfo(can_disable=True),
|
||||||
'disabled': KeyInfo(),
|
'disabled': KeyInfo(default=False),
|
||||||
'dscp': KeyInfo(can_disable=True),
|
'dscp': KeyInfo(can_disable=True),
|
||||||
'dst-address': KeyInfo(can_disable=True),
|
'dst-address': KeyInfo(can_disable=True),
|
||||||
'dst-address-list': KeyInfo(can_disable=True),
|
'dst-address-list': KeyInfo(can_disable=True),
|
||||||
|
@ -2179,10 +2186,10 @@ PATHS = {
|
||||||
'ingress-priority': KeyInfo(can_disable=True),
|
'ingress-priority': KeyInfo(can_disable=True),
|
||||||
'ipsec-policy': KeyInfo(can_disable=True),
|
'ipsec-policy': KeyInfo(can_disable=True),
|
||||||
'ipv4-options': KeyInfo(can_disable=True),
|
'ipv4-options': KeyInfo(can_disable=True),
|
||||||
'jump-target': KeyInfo(),
|
'jump-target': KeyInfo(can_disable=True),
|
||||||
'limit': KeyInfo(can_disable=True),
|
'limit': KeyInfo(can_disable=True),
|
||||||
'log': KeyInfo(),
|
'log': KeyInfo(can_disable=True),
|
||||||
'log-prefix': KeyInfo(),
|
'log-prefix': KeyInfo(can_disable=True),
|
||||||
'nth': KeyInfo(can_disable=True),
|
'nth': KeyInfo(can_disable=True),
|
||||||
'out-bridge-port': KeyInfo(can_disable=True),
|
'out-bridge-port': KeyInfo(can_disable=True),
|
||||||
'out-bridge-port-list': KeyInfo(can_disable=True),
|
'out-bridge-port-list': KeyInfo(can_disable=True),
|
||||||
|
@ -2503,6 +2510,8 @@ PATHS = {
|
||||||
stratify_keys=('chain', ),
|
stratify_keys=('chain', ),
|
||||||
fields={
|
fields={
|
||||||
'action': KeyInfo(),
|
'action': KeyInfo(),
|
||||||
|
'address-list': KeyInfo(can_disable=True),
|
||||||
|
'address-list-timeout': KeyInfo(can_disable=True),
|
||||||
'chain': KeyInfo(),
|
'chain': KeyInfo(),
|
||||||
'comment': KeyInfo(can_disable=True, remove_value=''),
|
'comment': KeyInfo(can_disable=True, remove_value=''),
|
||||||
'connection-bytes': KeyInfo(can_disable=True),
|
'connection-bytes': KeyInfo(can_disable=True),
|
||||||
|
@ -2512,7 +2521,7 @@ PATHS = {
|
||||||
'connection-state': KeyInfo(can_disable=True),
|
'connection-state': KeyInfo(can_disable=True),
|
||||||
'connection-type': KeyInfo(can_disable=True),
|
'connection-type': KeyInfo(can_disable=True),
|
||||||
'content': KeyInfo(can_disable=True),
|
'content': KeyInfo(can_disable=True),
|
||||||
'disabled': KeyInfo(),
|
'disabled': KeyInfo(default=False),
|
||||||
'dscp': KeyInfo(can_disable=True),
|
'dscp': KeyInfo(can_disable=True),
|
||||||
'dst-address': KeyInfo(can_disable=True),
|
'dst-address': KeyInfo(can_disable=True),
|
||||||
'dst-address-list': KeyInfo(can_disable=True),
|
'dst-address-list': KeyInfo(can_disable=True),
|
||||||
|
@ -2528,10 +2537,10 @@ PATHS = {
|
||||||
'in-interface-list': KeyInfo(can_disable=True),
|
'in-interface-list': KeyInfo(can_disable=True),
|
||||||
'ingress-priority': KeyInfo(can_disable=True),
|
'ingress-priority': KeyInfo(can_disable=True),
|
||||||
'ipsec-policy': KeyInfo(can_disable=True),
|
'ipsec-policy': KeyInfo(can_disable=True),
|
||||||
'jump-target': KeyInfo(),
|
'jump-target': KeyInfo(can_disable=True),
|
||||||
'limit': KeyInfo(can_disable=True),
|
'limit': KeyInfo(can_disable=True),
|
||||||
'log': KeyInfo(),
|
'log': KeyInfo(can_disable=False),
|
||||||
'log-prefix': KeyInfo(),
|
'log-prefix': KeyInfo(can_disable=False),
|
||||||
'nth': KeyInfo(can_disable=True),
|
'nth': KeyInfo(can_disable=True),
|
||||||
'out-bridge-port': KeyInfo(can_disable=True),
|
'out-bridge-port': KeyInfo(can_disable=True),
|
||||||
'out-bridge-port-list': KeyInfo(can_disable=True),
|
'out-bridge-port-list': KeyInfo(can_disable=True),
|
||||||
|
@ -2573,7 +2582,7 @@ PATHS = {
|
||||||
'connection-state': KeyInfo(can_disable=True),
|
'connection-state': KeyInfo(can_disable=True),
|
||||||
'connection-type': KeyInfo(can_disable=True),
|
'connection-type': KeyInfo(can_disable=True),
|
||||||
'content': KeyInfo(can_disable=True),
|
'content': KeyInfo(can_disable=True),
|
||||||
'disabled': KeyInfo(),
|
'disabled': KeyInfo(default=False),
|
||||||
'dscp': KeyInfo(can_disable=True),
|
'dscp': KeyInfo(can_disable=True),
|
||||||
'dst-address': KeyInfo(can_disable=True),
|
'dst-address': KeyInfo(can_disable=True),
|
||||||
'dst-address-list': KeyInfo(can_disable=True),
|
'dst-address-list': KeyInfo(can_disable=True),
|
||||||
|
@ -2647,7 +2656,7 @@ PATHS = {
|
||||||
'connection-state': KeyInfo(can_disable=True),
|
'connection-state': KeyInfo(can_disable=True),
|
||||||
'connection-type': KeyInfo(can_disable=True),
|
'connection-type': KeyInfo(can_disable=True),
|
||||||
'content': KeyInfo(can_disable=True),
|
'content': KeyInfo(can_disable=True),
|
||||||
'disabled': KeyInfo(),
|
'disabled': KeyInfo(default=False),
|
||||||
'dscp': KeyInfo(can_disable=True),
|
'dscp': KeyInfo(can_disable=True),
|
||||||
'dst-address': KeyInfo(can_disable=True),
|
'dst-address': KeyInfo(can_disable=True),
|
||||||
'dst-address-list': KeyInfo(can_disable=True),
|
'dst-address-list': KeyInfo(can_disable=True),
|
||||||
|
@ -2703,7 +2712,7 @@ PATHS = {
|
||||||
'chain': KeyInfo(),
|
'chain': KeyInfo(),
|
||||||
'comment': KeyInfo(can_disable=True, remove_value=''),
|
'comment': KeyInfo(can_disable=True, remove_value=''),
|
||||||
'content': KeyInfo(can_disable=True),
|
'content': KeyInfo(can_disable=True),
|
||||||
'disabled': KeyInfo(),
|
'disabled': KeyInfo(default=False),
|
||||||
'dscp': KeyInfo(can_disable=True),
|
'dscp': KeyInfo(can_disable=True),
|
||||||
'dst-address': KeyInfo(can_disable=True),
|
'dst-address': KeyInfo(can_disable=True),
|
||||||
'dst-address-list': KeyInfo(can_disable=True),
|
'dst-address-list': KeyInfo(can_disable=True),
|
||||||
|
@ -2796,7 +2805,7 @@ PATHS = {
|
||||||
'blackhole': KeyInfo(can_disable=True),
|
'blackhole': KeyInfo(can_disable=True),
|
||||||
'check-gateway': KeyInfo(can_disable=True),
|
'check-gateway': KeyInfo(can_disable=True),
|
||||||
'comment': KeyInfo(can_disable=True, remove_value=''),
|
'comment': KeyInfo(can_disable=True, remove_value=''),
|
||||||
'disabled': KeyInfo(),
|
'disabled': KeyInfo(default=False),
|
||||||
'distance': KeyInfo(default=1),
|
'distance': KeyInfo(default=1),
|
||||||
'dst-address': KeyInfo(),
|
'dst-address': KeyInfo(),
|
||||||
'gateway': KeyInfo(),
|
'gateway': KeyInfo(),
|
||||||
|
@ -3581,7 +3590,7 @@ PATHS = {
|
||||||
'cluster-id': KeyInfo(),
|
'cluster-id': KeyInfo(),
|
||||||
'comment': KeyInfo(),
|
'comment': KeyInfo(),
|
||||||
'connect': KeyInfo(default=True),
|
'connect': KeyInfo(default=True),
|
||||||
'disabled': KeyInfo(),
|
'disabled': KeyInfo(default=False),
|
||||||
'hold-time': KeyInfo(),
|
'hold-time': KeyInfo(),
|
||||||
'input.accept-communities': KeyInfo(),
|
'input.accept-communities': KeyInfo(),
|
||||||
'input.accept-ext-communities': KeyInfo(),
|
'input.accept-ext-communities': KeyInfo(),
|
||||||
|
@ -3640,7 +3649,7 @@ PATHS = {
|
||||||
'client-to-client-reflection': KeyInfo(),
|
'client-to-client-reflection': KeyInfo(),
|
||||||
'cluster-id': KeyInfo(can_disable=True),
|
'cluster-id': KeyInfo(can_disable=True),
|
||||||
'confederation': KeyInfo(can_disable=True),
|
'confederation': KeyInfo(can_disable=True),
|
||||||
'disabled': KeyInfo(),
|
'disabled': KeyInfo(default=False),
|
||||||
'ignore-as-path-len': KeyInfo(),
|
'ignore-as-path-len': KeyInfo(),
|
||||||
'name': KeyInfo(),
|
'name': KeyInfo(),
|
||||||
'out-filter': KeyInfo(),
|
'out-filter': KeyInfo(),
|
||||||
|
|
|
@ -619,24 +619,28 @@ class TestRouterosApiFindAndModifyModule(ModuleTestCase):
|
||||||
'chain': 'input',
|
'chain': 'input',
|
||||||
'comment': 'defconf',
|
'comment': 'defconf',
|
||||||
'protocol': 'icmp',
|
'protocol': 'icmp',
|
||||||
|
'disabled': False,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
'.id': '*3',
|
'.id': '*3',
|
||||||
'action': 'accept',
|
'action': 'accept',
|
||||||
'chain': 'input',
|
'chain': 'input',
|
||||||
'comment': 'defconf',
|
'comment': 'defconf',
|
||||||
|
'disabled': False,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
'.id': '*4',
|
'.id': '*4',
|
||||||
'action': 'accept',
|
'action': 'accept',
|
||||||
'chain': 'input',
|
'chain': 'input',
|
||||||
'comment': 'defconf',
|
'comment': 'defconf',
|
||||||
|
'disabled': False,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
'.id': '*7',
|
'.id': '*7',
|
||||||
'action': 'drop',
|
'action': 'drop',
|
||||||
'chain': 'input',
|
'chain': 'input',
|
||||||
'comment': 'defconf',
|
'comment': 'defconf',
|
||||||
|
'disabled': False,
|
||||||
'in-interface': 'wan',
|
'in-interface': 'wan',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
@ -645,6 +649,7 @@ class TestRouterosApiFindAndModifyModule(ModuleTestCase):
|
||||||
'chain': 'forward',
|
'chain': 'forward',
|
||||||
'comment': 'defconf',
|
'comment': 'defconf',
|
||||||
'connection-state': 'established',
|
'connection-state': 'established',
|
||||||
|
'disabled': False,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
'.id': '*9',
|
'.id': '*9',
|
||||||
|
@ -652,6 +657,7 @@ class TestRouterosApiFindAndModifyModule(ModuleTestCase):
|
||||||
'chain': 'forward',
|
'chain': 'forward',
|
||||||
'comment': 'defconf',
|
'comment': 'defconf',
|
||||||
'connection-state': 'related',
|
'connection-state': 'related',
|
||||||
|
'disabled': False,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
'.id': '*A',
|
'.id': '*A',
|
||||||
|
@ -659,6 +665,7 @@ class TestRouterosApiFindAndModifyModule(ModuleTestCase):
|
||||||
'chain': 'forward',
|
'chain': 'forward',
|
||||||
'comment': 'defconf',
|
'comment': 'defconf',
|
||||||
'connection-status': 'invalid',
|
'connection-status': 'invalid',
|
||||||
|
'disabled': False,
|
||||||
},
|
},
|
||||||
])
|
])
|
||||||
self.assertEqual(result['match_count'], 3)
|
self.assertEqual(result['match_count'], 3)
|
||||||
|
|
|
@ -198,6 +198,8 @@ class TestRouterosApiInfoModule(ModuleTestCase):
|
||||||
'chain': 'input',
|
'chain': 'input',
|
||||||
'in-interface-list': 'LAN',
|
'in-interface-list': 'LAN',
|
||||||
'!action': None,
|
'!action': None,
|
||||||
|
'!address-list': None,
|
||||||
|
'!address-list-timeout': None,
|
||||||
'!comment': None,
|
'!comment': None,
|
||||||
'!connection-bytes': None,
|
'!connection-bytes': None,
|
||||||
'!connection-limit': None,
|
'!connection-limit': None,
|
||||||
|
@ -243,6 +245,7 @@ class TestRouterosApiInfoModule(ModuleTestCase):
|
||||||
'!protocol': None,
|
'!protocol': None,
|
||||||
'!psd': None,
|
'!psd': None,
|
||||||
'!random': None,
|
'!random': None,
|
||||||
|
'!realm': None,
|
||||||
'!reject-with': None,
|
'!reject-with': None,
|
||||||
'!routing-mark': None,
|
'!routing-mark': None,
|
||||||
'!routing-table': None,
|
'!routing-table': None,
|
||||||
|
@ -284,6 +287,8 @@ class TestRouterosApiInfoModule(ModuleTestCase):
|
||||||
'chain': 'input',
|
'chain': 'input',
|
||||||
'in-interface-list': 'LAN',
|
'in-interface-list': 'LAN',
|
||||||
'action': None,
|
'action': None,
|
||||||
|
'address-list': None,
|
||||||
|
'address-list-timeout': None,
|
||||||
'comment': None,
|
'comment': None,
|
||||||
'connection-bytes': None,
|
'connection-bytes': None,
|
||||||
'connection-limit': None,
|
'connection-limit': None,
|
||||||
|
@ -329,6 +334,7 @@ class TestRouterosApiInfoModule(ModuleTestCase):
|
||||||
'protocol': None,
|
'protocol': None,
|
||||||
'psd': None,
|
'psd': None,
|
||||||
'random': None,
|
'random': None,
|
||||||
|
'realm': None,
|
||||||
'reject-with': None,
|
'reject-with': None,
|
||||||
'routing-mark': None,
|
'routing-mark': None,
|
||||||
'routing-table': None,
|
'routing-table': None,
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue