summaryrefslogtreecommitdiffstats
path: root/src/lib/Bcfg2/Server/Lint
diff options
context:
space:
mode:
authorChris St. Pierre <chris.a.st.pierre@gmail.com>2013-02-22 09:34:25 -0500
committerChris St. Pierre <chris.a.st.pierre@gmail.com>2013-02-22 09:34:25 -0500
commit9bd7987fb031619f4d748b9a150009835053cf47 (patch)
treeb41e390f6eb743553d898c4cc9544b2ccc815d23 /src/lib/Bcfg2/Server/Lint
parent1df2b8ccdb0db12087b7c33fd20fb6e50fb8238e (diff)
downloadbcfg2-9bd7987fb031619f4d748b9a150009835053cf47.tar.gz
bcfg2-9bd7987fb031619f4d748b9a150009835053cf47.tar.bz2
bcfg2-9bd7987fb031619f4d748b9a150009835053cf47.zip
bcfg2-lint: fixed username regex
Diffstat (limited to 'src/lib/Bcfg2/Server/Lint')
-rw-r--r--src/lib/Bcfg2/Server/Lint/RequiredAttrs.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/lib/Bcfg2/Server/Lint/RequiredAttrs.py b/src/lib/Bcfg2/Server/Lint/RequiredAttrs.py
index 61b737a82..19b187eea 100644
--- a/src/lib/Bcfg2/Server/Lint/RequiredAttrs.py
+++ b/src/lib/Bcfg2/Server/Lint/RequiredAttrs.py
@@ -43,7 +43,7 @@ def is_octal_mode(val):
def is_username(val):
""" Return True if val is a string giving either a positive
integer uid, or a valid Unix username """
- return re.match(r'^([a-z]\w{0,30}|\d+)$', val)
+ return re.match(r'^([a-z][_-a-z0-9]{0,30}|\d+)$', val)
def is_device_mode(val):