diff options
author | Daniil Baturin <daniil@baturin.org> | 2018-05-16 03:27:52 +0200 |
---|---|---|
committer | Daniil Baturin <daniil@baturin.org> | 2018-05-16 03:27:52 +0200 |
commit | 64caf155434202abfda5909f07f5446124d5e970 (patch) | |
tree | 765f368556e36c1bdc0b7b335b4fbd052fc763d6 /src/helpers/validate-value.py | |
parent | a41145f0179c3f18234d613e41f6c5de9dcf006f (diff) | |
download | vyos-1x-64caf155434202abfda5909f07f5446124d5e970.tar.gz vyos-1x-64caf155434202abfda5909f07f5446124d5e970.zip |
T643: use fullmatch for regex validators so that people don't have to write ^...$ all the time.
Diffstat (limited to 'src/helpers/validate-value.py')
-rwxr-xr-x | src/helpers/validate-value.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/helpers/validate-value.py b/src/helpers/validate-value.py index e49bfb6f4..d702739b5 100755 --- a/src/helpers/validate-value.py +++ b/src/helpers/validate-value.py @@ -18,7 +18,7 @@ debug = False try: for r in args.regex: - if re.match(r, args.value): + if re.fullmatch(r, args.value): sys.exit(0) except Exception as exn: if debug: |