(RADIATOR) Rewriteusername Regular Expression Newbie

Andy De Petter adepette at krameria.net
Thu Apr 18 01:51:32 CDT 2002


Hi Barry,

Obviously, you could also use:

RewriteFunction sub { my ($a) = shift; $a =~ tr/A-Z/a-z/; $a =~
s/^([^@]+).*/$1/; $a; }

Cheers,

-Andy

> -----Original Message-----
> From: owner-radiator at open.com.au 
> [mailto:owner-radiator at open.com.au] On Behalf Of Barry Andersson
> Sent: donderdag 18 april 2002 3:45
> To: radiator at open.com.au
> Subject: (RADIATOR) Rewriteusername Regular Expression Newbie
> 
> 
> Hi,
> 
> I'm afraid Perl regular expressions are a bit foreign to me.
> 
> I want to force all usernames to lower case and strip any 
> domain suffix that
> may be attached. Do I simply add two RewriteUsername lines at the very
> beginning of my Radius.cfg before any AuthBy or Realm clauses such as:
> 
> RewriteUsername s/^([^@]+).*/$1/
> RewriteUsername tr/A-Z/a-z/
> 
> or can I combine the two into a single line? Note that we have five
> different realms that usres may inadvertently include.
> 
> Cheers
> 
> Barry Andersson
> 
> 
> ===
> Archive at http://www.open.com.au/archives/radiator/
> Announcements on radiator-announce at open.com.au
> To unsubscribe, email 'majordomo at open.com.au' with
> 'unsubscribe radiator' in the body of the message.
> 

===
Archive at http://www.open.com.au/archives/radiator/
Announcements on radiator-announce at open.com.au
To unsubscribe, email 'majordomo at open.com.au' with
'unsubscribe radiator' in the body of the message.


More information about the radiator mailing list