diff options
author | sarthurdev <965089+sarthurdev@users.noreply.github.com> | 2022-01-12 00:59:53 +0100 |
---|---|---|
committer | sarthurdev <965089+sarthurdev@users.noreply.github.com> | 2022-01-12 11:26:47 +0100 |
commit | a132ba993e786994a3b129c72fb0024931339619 (patch) | |
tree | ddec5f51433c572143c293d0dcb43282d765d862 /src | |
parent | 391ce22b76190309f81e048ebffab778b0fdee1d (diff) | |
download | vyos-1x-a132ba993e786994a3b129c72fb0024931339619.tar.gz vyos-1x-a132ba993e786994a3b129c72fb0024931339619.zip |
firewall: T4160: Fix support for inverse matches
Diffstat (limited to 'src')
-rwxr-xr-x | src/validators/port-multi | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/validators/port-multi b/src/validators/port-multi index 017ea78fb..cef371563 100755 --- a/src/validators/port-multi +++ b/src/validators/port-multi @@ -22,6 +22,8 @@ if __name__ == '__main__': services = get_services() for port in ports: + if port and port[0] == '!': + port = port[1:] if re.match('^[0-9]{1,5}-[0-9]{1,5}$', port): port_1, port_2 = port.split('-') if int(port_1) not in range(1, 65536) or int(port_2) not in range(1, 65536): |