[TYPO3-english] Can I make usernames case-insensitive for felogin?

Peter Russ peter.russ at 4many.net
Thu Feb 11 10:17:47 CET 2010

--- Original Nachricht ---
Absender:   Xavier Perseguers
Datum:       11.02.2010 09:58:
> Hi,
>> I think it would be a great usability improvement to add
>> case-insensitive usernames as an option. It looks like the actual
>> username check doesn't happen in the extension felogin (or did I miss
>> something?). Some pointers for where to look in the code are welcome.
> First of all it may depend on client code. I don't know how you 
> configured your FE login but show source of your BE login form. If you 
> have superchallenge activated, you'll see this:
> function doChallengeResponse(superchallenged) {    //
>         password = document.loginform.p_field.value;
>         if (password)    {
>             if (superchallenged)    {
>                 password = MD5(password);    // this makes it 
> superchallenged!!
>             }
>             str = 
> document.loginform.username.value+":"+password+":"+document.loginform.challenge.value; 
>             document.loginform.userident.value = MD5(str);
>             document.loginform.p_field.value = "";
>             return true;
>         }
>     }
> Meaning the username the user typed will be used to compute a MD5 hash 
> with the password. If you ever want to have a case-insensitive username, 
> you'll certainly want to change this code and force lowercase in the 
> hash computation.
> Same thing happens in auth service (search for it in Core) or have a 
> look at existing extensions that provide authentication services. This 
> will direct you to where the authentication process is actually taking 
> place.

it shouldn't be that complicated:
1) When the user register transfer the username to lowercases. Depending 
  on the extension you are using there should be Typoscript to do that.
2) For existing users just transfer the username using sql statement
3) On the login form add an onchange action for the username field to 
change all characters to lower case.


loans that change lives http://www.kiva.org

uon GbR

More information about the TYPO3-english mailing list