Create a limit on how long usernames for registered users can be

VERIFIED FIXED in 1.2.1

Status

support.mozilla.org
Forum
VERIFIED FIXED
9 years ago
9 years ago

People

(Reporter: Noah, Assigned: paulc)

Tracking

unspecified
1.2.1
x86
All

Firefox Tracking Flags

(Not tracked)

Details

(Whiteboard: sumo_only)

Attachments

(1 attachment)

(Reporter)

Description

9 years ago
User-Agent:       Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.2a1pre) Gecko/20090420 Firefox/3.0
Build Identifier: 

In the forums, someone had an extremely long name that widened the forum index. We need to limit the length of usernames.

Reproducible: Always
(Reporter)

Comment 1

9 years ago
Created attachment 374570 [details]
Screenshot of long username
(Assignee)

Comment 2

9 years ago
I'll look into it, see if there is actually a limit already built in.

If not, I'll make this an admin pref. A sensible default sounds like 15-20 characters. David, Laura: what do you think?
Assignee: nobody → paul.craciunoiu
Status: UNCONFIRMED → NEW
Ever confirmed: true
there is a pref, it's set to 50.

Comment 4

9 years ago
20 sounds like a reasonable limit. What happens with existing accounts with longer user names if we change this though?

Comment 5

9 years ago
1129 such logins ... almost all are e-mail addresses.

Comment 6

9 years ago
1129 logins longer than 20.  Only 73 have _ever_ done anything that is tracked in the actionlog (posted/answered a forum thread, contributed to the KB).  25 have done those things since 2009-01-01.  It's such a small number that we can go through the list manually and e-mail them if this is going to be a problem.

These are for registered users.

The screenshot above is for a not-registered user.  We won't be truncating that field in the tiki_comments table so I think as long as we limit that field size (which I don't think is specified by the pref but correct me if I'm wrong) we should be ok in that case as all usernames from here on out will be short.
(Assignee)

Comment 7

9 years ago
Ooo, good point Cheng. I think we should limit that field for anonymous users. That's actually more important than the username limit.

I just changed the pref to 20 on stage.

Updated

9 years ago
Blocks: 413579
(Assignee)

Comment 8

9 years ago
This too is ready for testing on stage. I tested a 25 long username and couldn't register. We can change it on prod once testing of stage is approved.
Target Milestone: --- → 1.3
(In reply to comment #8)
> This too is ready for testing on stage. I tested a 25 long username and
> couldn't register. We can change it on prod once testing of stage is approved.

I tested:

* 25: failed
* 20: passed
* 21: failed

Verified FIXED on https://support-stage.mozilla.org/tiki-register.php; Paul, want to resolve this as FIXED -- we'll then verify on production; thanks!
(Assignee)

Comment 10

9 years ago
This is ready to be changed on prod, and doesn't need any code push.
If I understand this correctly...
* We need to set this on prod. (I assume it's "Maximum username length:" on <https://support.mozilla.com/tiki-admin.php?page=login>, but it's also set to 50 on stage. Is that just because there was a recent sync?)
* We need to email registered users who exceed the limit (does that need to be done before changing the setting on prod?)
* We leave this bug open for limiting the field for non-registered users.
Paul verified on IRC that the URL in comment 11 is correct, and that we don't have to email registered users who exceed the limit before changing prod.

"Maximum username length:" is now set to 20 on prod.
(Assignee)

Comment 13

9 years ago
Next up is limiting input length in anonymous fields.
Summary: Create a limit on how long usernames can be → Create a limit on how long usernames and anonymous names can be
(Assignee)

Comment 14

9 years ago
Filed bug 502862 for comment 13 (comment 11 item #3)
Status: NEW → RESOLVED
Last Resolved: 9 years ago
Resolution: --- → FIXED
Summary: Create a limit on how long usernames and anonymous names can be → Create a limit on how long usernames for registered users can be

Comment 15

9 years ago
Verified on prod. Limit 20
Status: RESOLVED → VERIFIED
(Assignee)

Updated

9 years ago
Target Milestone: 1.3 → 1.2.1
Whiteboard: sumo_only
You need to log in before you can comment on or make changes to this bug.