Bug 704610 - Set a reasonable length on username creation
Summary: Set a reasonable length on username creation
Keywords:
Status: CLOSED UPSTREAM
Alias: None
Product: Red Hat Satellite
Classification: Red Hat
Component: WebUI
Version: 6.0.0
Hardware: Unspecified
OS: Unspecified
low
low vote
Target Milestone: Unspecified
Assignee: Partha Aji
QA Contact: Katello QA List
URL:
Whiteboard:
Depends On: 702052
Blocks:
TreeView+ depends on / blocked
 
Reported: 2011-05-13 18:33 UTC by Corey Welton
Modified: 2019-09-26 13:16 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2013-09-19 18:15:57 UTC
Target Upstream Version:


Attachments (Terms of Use)

Description Corey Welton 2011-05-13 18:33:10 UTC
Description of problem:
I don't know what the db limit is, but usernames can currently be at least 100 characters long.  This kind of messes up the UI a bit.

Version-Release number of selected component (if applicable):


How reproducible:


Steps to Reproduce:
1.  Create a new user with the name "0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789"
2.  Submit
3.  Look at user list
  
Actual results:
Ugly UI

Expected results:
A limit (in the db and matched in the UI) that is reasonable.  20 chars?

Additional info:

Comment 1 Corey Welton 2011-05-13 18:55:39 UTC
Note: We probably should limit role names as well.  But they should, at minimum, be username_limit + 5 (so that "_role" can be appended, per current functionality).  Don't know if we want a separate bug for this.

Comment 2 Corey Welton 2011-05-13 19:28:37 UTC
Side note: While these values seem to be getting accepted for user and role names, my server appears to become unresponsive sometime after entering them.  I am not sure if it is just coincidence, but possibly related

Comment 3 Corey Welton 2011-05-13 19:34:35 UTC
Unrelated.  Ignore comment #2

Comment 5 Corey Welton 2011-06-24 18:05:47 UTC
Something's still not kosher here.

If i use the very long string from above, I get an error message:

Validation Failed:

    Username cannot contain more than 64 characters

However, if I try something else that is even shorter than 64 characters ("012345678901234567890123456789012345678901234567890123456789"), I get a slightly different error message:

Validation Failed:

    Name cannot contain more than 64 characters


So distilled:
* Even usernames that are shorter than 64 characters are triggering a failure
* It may or may not be something of a concern that we're evidently going down two slightly separate codepaths here, as is evident in the differing error messages.

Comment 7 Sachin Ghai 2011-08-18 10:13:43 UTC
Verified with latest katello build:
katello-0.1.64-1.git.0.0b431ff.fc15.noarch

While creating a user of more than 64 characters a pop-up appears with message:

undefined:
"Username cannot contain more than 64 characters"

However user having less than 64 characters in name is created successfully.  But user list looks very ugly due to a long name.  And the name is even crossing
the Left pane of the screen.

So Ideally, either we should truncate the name of the user so as to adjust it in the left pane of user list or we should reduce the no. of characters in the username.

Comment 8 Mike McCune 2012-01-26 19:39:18 UTC
mass move to CFSE product.

Comment 10 Partha Aji 2013-01-22 20:08:02 UTC
Sounds like this has been resolved in katello 1.2

Comment 11 Mike McCune 2013-09-19 18:15:57 UTC
These bugs have been resolved in upstream projects for a period of months so I'm mass-closing them as CLOSED:UPSTREAM.  If this is a mistake feel free to re-open.


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