On Mon, 1 Nov 1999, David S. Madole wrote:

> To answer the original request, the following
> will strip any "xxx\" prefix, any "@xxx" suffix, and any leading or
> trailing spaces:
> 
>      # make life easier for our customers
>      RewriteUsername s/^.*\\|@.*$|^\s+|\s+$//g

This is a gem, much better than mine for the job at hand.


> If you are so concerned about performance that you're afraid to do
> things like this, you either shouldn't be running a RADIUS server
> written in Perl, or you shouldn't be running on a 386. If you were to
> profile Radiator, you would find these rewrites to be of trivial
> impact.

Being "concerned about performance" is one thing, but outright wasting
performance for no reason is another. My comments about this were based
on the original poster having a separate RewriteUsername for individual
operations which were more effectively combined as you demonstrated in
your message...reducing the entire thing to just two Rewrites.


===
Archive at http://www.thesite.com.au/~radiator/
To unsubscribe, email '[EMAIL PROTECTED]' with
'unsubscribe radiator' in the body of the message.

Reply via email to