summaryrefslogtreecommitdiffstats
path: root/ipaserver/plugins/baseuser.py
diff options
context:
space:
mode:
authorMartin Basti <mbasti@redhat.com>2016-09-14 12:55:01 +0200
committerMartin Babinsky <mbabinsk@redhat.com>2016-09-20 17:35:28 +0200
commit37200806118d39ef8afe84ad5887a294d54e2659 (patch)
tree73838afb601e72a1a14b2fff339637fd3dca4220 /ipaserver/plugins/baseuser.py
parent2bc70a5d5f5eb953969e7341179c5083c147221a (diff)
downloadfreeipa-37200806118d39ef8afe84ad5887a294d54e2659.tar.gz
freeipa-37200806118d39ef8afe84ad5887a294d54e2659.tar.xz
freeipa-37200806118d39ef8afe84ad5887a294d54e2659.zip
Fix regexp patterns in parameters to not enforce length
Regexp should not enforce lenght of string, we have different checks for that. Secondly regexp with length specified produces an incorrect error message. https://fedorahosted.org/freeipa/ticket/5822 Reviewed-By: Stanislav Laznicka <slaznick@redhat.com> Reviewed-By: Alexander Bokovoy <abokovoy@redhat.com>
Diffstat (limited to 'ipaserver/plugins/baseuser.py')
-rw-r--r--ipaserver/plugins/baseuser.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/ipaserver/plugins/baseuser.py b/ipaserver/plugins/baseuser.py
index 5e36a6620..608e2d4fb 100644
--- a/ipaserver/plugins/baseuser.py
+++ b/ipaserver/plugins/baseuser.py
@@ -172,7 +172,7 @@ class baseuser(LDAPObject):
takes_params = (
Str('uid',
- pattern='^[a-zA-Z0-9_.][a-zA-Z0-9_.-]{0,252}[a-zA-Z0-9_.$-]?$',
+ pattern='^[a-zA-Z0-9_.][a-zA-Z0-9_.-]*[a-zA-Z0-9_.$-]?$',
pattern_errmsg='may only include letters, numbers, _, -, . and $',
maxlength=255,
cli_name='login',