[ic] problems with mixed case usernames
Mark Bryant
mark at vwe.net
Sun Apr 11 04:08:50 EDT 2004
At 22:10 10/04/2004, you wrote:
> > From: interchange-users-bounces at icdevgroup.org
>[mailto:interchange-users-
> > bounces at icdevgroup.org] On Behalf Of Eros Shop
> >
> > At 21:08 10/04/2004, you wrote:
> > > > From: interchange-users-bounces at icdevgroup.org
> > >[mailto:interchange-users-
> > > > bounces at icdevgroup.org] On Behalf Of Eros Shop
> > > >
> > > > Hi All,
> > > >
> > > > It seems that a lot of my users/customers are forgetful when it
>comes
> > >to
> > > > their login details and despite the provision of a means to
>retrieve
> > >their
> > > > logon details by email they tend to opt for creating a new
>account.
> > > >
> > > > After a bit of investigation, it appears that this all boils down
>to
> > >the
> > > > case of the letters in the username. IC appears to see "Mark" and
> > >"mark"
> > > > as
> > > > different when it comes to username/account creation and I
>wondered if
> > >it
> > > > was possible to make the process case insensitive or forced
>lowercase?
> > > >
> > > > Many thanks
> > > >
> > > > Mark
> > > >
> > >
> > >Check the ignore_case parameter for the new account function.
> > >
> > >http://www.icdevgroup.org/i/dev/docfly.html?mv_arg=icdatabase09%2e03
> > >
> > >-Ron
> >
> > Thanks for the pointer Ron,
> >
> > Sadly I'm not on the ball as much as I thought I was and I don't see
>how
> > to
> > use any of this with my login.html and new_account.html files :(
> >
> > I'm going to have to resort to the basics....
>
>[snip]
>
>Try changing this:
>
> > [if type=explicit compare="[userdb new_account]"]
>
>to this:
>
>[if type=explicit compare="[userdb function=new_account ignore_case=1]"]
>
>This is untested code.
>
>Good luck,
>-Ron
Sadly the above doesn't work :(
I put the ignore_case=1 into the line in new_account.html and no new
accounts could be created.
Submitting a request to create a new account returned a session error
of "Not logged in" or something very similar.
I also found "profiles.login" in <CATROOT>/etc which seemed to be dealing
with the login side of things and contained this:
__NAME__ Login
[if type=explicit compare="[userdb login]"]
[set mv_no_count][/set]
[set mv_no_session_id][/set]
mv_nextpage=[either][cgi mv_successpage][or][cgi mv_nextpage][/either]
[else]
mv_nextpage=[either][cgi mv_failpage][or][cgi mv_nextpage][/either]
[/else]
[/if]
I've assumed this is the bit that's doing the userdb query with data
submitted via the login.html page.
In the hope of login case insensitive I changed:
[if type=explicit compare="[userdb login]"]
to:
[if type=explicit compare="[userdb login ignore_case=1]"]
and that made it impossible for anyone to login to IC who already had an
account.
The error.log file shows the attempted logins as failures. The first was me
testing case insensitivity, the second with them in the correct case.
supercow.vwe.net rHvtcLJL:vwe.net - [10/April/2004:22:32:21 +0000] eros
/cgi-bin/eros/process.html Denied attempted login with nonexistent user
name 'TeST'
supercow.vwe.net rHvtcLJL:vwe.net - [10/April/2004:22:32:43 +0000] eros
/cgi-bin/eros/process.html Denied attempted login with nonexistent user
name 'test'
I if remove the ignore_case=1 stuff from the profiles.login everything goes
back to normal:
supercow.vwe.net PoAkjVmH:vwe.net - [10/April/2004:22:40:05 +0000] eros
/cgi-bin/eros/process.html Successful login by user 'test'
Does anyone have any ideas why this isn't working in either case? ATM the
finger is pointed at improper use of ingore_case=1 or that IC doesn't know
what this attribute is.
Many thanks
Mark
vwe internet ltd
EMail - info at vwe.net
WWW - http://www.vwe.net/
Tel - 0870 737 3369
Fax - 0870 737 4469
Tech Support - 0906 470 3369*
*UK only. Calls charged at 60p/min at all times
UK Broadband with modem, 1 filter and half price installation until
30/04/2004 - http://www.vwe.net/adsl
More information about the interchange-users
mailing list