(RADIATOR) Using PreHandlerHook via LDAP

Peter Crystal peter.c at staff.iinet.net.au
Mon Oct 3 19:48:00 CDT 2005


Currently we have a certain Client 'device' defined in LDAP. Due to its
nature we need to apply a PreHandlerHook to it to manipulate the packet
and sanitize it.

We have defined the PreHandlerHook using the LDAP value (as according to
the schema that comes with Radiator) via oscRadiusPreHandlerHook.

Looking at the debug we can see the contents of the hook being returned
to the Radiator session but it never gets executed. Debugging on runHook
it recognises it but never runs it as there is no compiled version.

We have tested it using the following code fragments:

	sub { ${$_[0]}->add_attr("test-attr","test-value"); open(OUTF,
">>/tmp/outf1.txt"); print OUTF "We are here\n"; close(OUTF); }

And

	${$_[0]}->add_attr("test-attr","test-value"); open(OUTF,
">>/tmp/outf1.txt"); print OUTF "We are here\n"; close(OUTF);

And neither is compiled or executed. 

Question is, are we approaching the code fragments the wrong way or is
this functionality not working?

And yes, am new to the list. Running this on Debian GNU/Linux servers
using Radiator 3.11.

Debug as follows:

Tue Oct  4 06:44:33 2005: DEBUG: ClientListLDAP got result for
cn=iPasstmp,ou=radius_clients,ou=network,o=iinet
Tue Oct  4 06:44:33 2005: DEBUG: ClientListLDAP got oscRadiusClientName:
10.2.1.3
Tue Oct  4 06:44:33 2005: DEBUG: ClientListLDAP got oscRadiusNasType:
ipass
Tue Oct  4 06:44:33 2005: DEBUG: ClientListLDAP got oscRadiusSecret:
xxxxxxxxxx
Tue Oct  4 06:44:33 2005: DEBUG: ClientListLDAP got
oscRadiusPreHandlerHook: ${$_[0]}->add_attr("test-attr","test-value");
open(OUTF, ">>/tmp/outf1.txt"); print OUTF "We are here\n"; close(OUTF);


This one is stumping us here :)

Thanks.
--
[ Peter Crystal                | Programmer                  ]

[ e: peter.c at team.iinet.net.au | w: http://www.iinet.net.au/ ]
[ p: +618 9213 1345            | f: n/a                      ]
[                              |                             ]
[                  Quis custodiet ipsos custodes             ]
 

--
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