Error for mismatched brackets
We recently got caught with someone writing ++++? if ("%{request:Assigned-IP-Address)" !~ /./) instead of ++++? if ("%{request:Assigned-IP-Address}" !~ /./) I stared at it for ages but couldn't see the problem, until I put the server into debug mode and picked through it with a fine-toothed comb. Could I suggest these sort of syntactic bugs be bumped up to an ERROR rather than DEBUG, similar to commit 0dbd06ce ? Regards, Brian.
On Wed, May 25, 2011 at 10:53:19AM +0200, Alan DeKok wrote:
I've also added rlm_replicate. See raddb/modules/replicate.
Very neat! One thought: for (i = 0; i < sizeof(packet->vector); i++) { packet->vector[i] = fr_rand() & 0xff; } If you are replicating auth packets, won't it break CHAP if you don't copy the message authenticator from the request? (Since it holds the CHAP challenge) My main application for this is accounting, but I'm now quite interested in being able to replicate a stream of auth requests to a test server too. Regards, Brian.
Brian Candler wrote:
Very neat!
Thanks. Small is good.
If you are replicating auth packets, won't it break CHAP if you don't copy the message authenticator from the request? (Since it holds the CHAP challenge)
Yeah. See src/main/event.c for how it deals with CHAP-Challenge when proxying. I've added the same kind of code to rlm_replicate.
My main application for this is accounting, but I'm now quite interested in being able to replicate a stream of auth requests to a test server too.
Yup. Alan DeKok.
participants (2)
-
Alan DeKok -
Brian Candler