Bug 496966 - Max.Username Length is not respected
Max.Username Length is not respected
Status: CLOSED ERRATA
Product: freeIPA
Classification: Community
Component: ipa-server (Show other bugs)
1.2
All Linux
medium Severity medium
: v2 release
: ---
Assigned To: Rob Crittenden
Chandrasekar Kannan
:
Depends On:
Blocks: 431020
  Show dependency treegraph
 
Reported: 2009-04-21 16:46 EDT by Stefan Freyr Stefansson
Modified: 2015-01-04 18:37 EST (History)
3 users (show)

See Also:
Fixed In Version: freeipa-2.0.0-1.fc15
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2012-03-28 05:29:16 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Stefan Freyr Stefansson 2009-04-21 16:46:56 EDT
Description of problem:
We have set Max.Username Length to 255 in our policy but when we try to create a user with more than 33 characters in the username it fails with the error message "Enter only letters, numbers, _ (underscore), - (dash) or $".

How reproducible:
Always

Steps to Reproduce:
1) Set Max.Username Length to 255
2) Try to create user with >33 characters in username and it will fail.
  
Actual results:
Error message displayed: "Enter only letters, numbers, _ (underscore), - (dash) or $". This happens both in the web interface as well as in the CLI.

Expected results:
User should be created.
Comment 1 Rob Crittenden 2010-01-29 11:04:12 EST
Yes, I suppose we should document what the maximum is. This is bounded based on what shadowutils supports. We use the following regular expression:

^[a-zA-Z0-9_.][a-zA-Z0-9_.-]{0,30}[a-zA-Z0-9_.$-]?$

The trailing $ is there to support samba machine names.
Comment 2 David O'Brien 2010-01-31 22:14:08 EST
When I was documenting this for version 1.x I was provided with the following regex: [a-zA-Z0-9_.][a-zA-Z0-9_.-]{0,30}[a-zA-Z0-9_.$-]

Has this changed or are we looking at two different things?
Comment 3 Rob Crittenden 2010-02-01 09:10:28 EST
Perhaps you were provided with a truncated version, probably by me :-(
Comment 5 Rob Crittenden 2010-09-14 13:00:07 EDT
https://fedorahosted.org/freeipa/ticket/226
Comment 6 Rob Crittenden 2010-10-13 13:03:26 EDT
master: 3d55b66e48466bf190f85d78d15c040d27bc136d

Note You need to log in before you can comment on or make changes to this bug.