Hello Dave -
On Thu, 16 Mar 2000, Dave Kitabjian wrote:
> We have a surprising number of "No such user" failures which appear to be
> caused by leading or trailing spaces around the username. In Unix, I would
> fix this as:
>
> echo " dave " | sed -e 's/^ *//' -e 's/ *$//'
>
> Since I don't know perl, I'm not sure how to test this without going live,
> so I was wondering if someone could confirm the proper perl/radiator
> syntax. My guess is:
>
> RewriteUsername s/^ *//
> RewriteUsername s/ *$//
>
> Is this correct? Thanks all! (Btw, how *would* I test this with perl?)
>
Try this:
RewriteUsername s/\s//g
In other words, "substitute (s) whitespace (/\s/) to nothing (//) everywhere
(g - globally) in the line.
To find out how to do it in Perl, I suggest the Llama book (Learning Perl from
O'Reilly & Associates - www.ora.com).
hth
Hugh
--
Radiator: the most portable, flexible and configurable RADIUS server
anywhere. SQL, proxy, DBM, files, LDAP, NIS+, password, NT, Emerald,
Platypus, Freeside, Interbiller, TACACS+, PAM, external, etc, etc.
Available on Unix, Linux, FreeBSD, Windows 95/98/2000, NT, MacOS X.
===
Archive at http://www.starport.net/~radiator/
Announcements on [EMAIL PROTECTED]
To unsubscribe, email '[EMAIL PROTECTED]' with
'unsubscribe radiator' in the body of the message.