questions about module rlm_perl

Arran Cudbard-Bell a.cudbardb at freeradius.org
Thu Feb 19 21:02:42 CET 2015


> On 19 Feb 2015, at 14:39, HAKNER J <hak at cooper.edu> wrote:
> 
> Working with version 2.2.6, two questions about rlm_perl, perhaps these
> belong on the developers list?
> 
> 1: Why is this module unable to set items on the CONFIG list?
> Looking in the source code rlm_perl.c at function rlmperl_call,
> the hashes RAD_REPLY,RAD_CHECK,RAD_CONFIG,RAD_REQUEST,RAD_REQUEST_PROXY
> and RAD_REQUEST_PROXY_REPLY are all pre-loaded with the value pairs from
> the corresponding lists before the perl subroutine (e.g. authorize) is
> called.  After the subroutine returns, all of these hashes are examined and
> the values put back into the radiusd value pairs, except RAD_CONFIG.
> I have worked around it, but why can't this module do this?

It does, in v3.0.x.

> 2: The detach subroutine is a placebo.  It doesn't get called during SIGHUP
> processing because in main/modules.c, before reloading a module, the code
> checks to see if the RLM_TYPE_HUP_SAFE flag is set.  rlm_perl.c does not
> set this flag.  There are some sketchy areas of the perl_detach function
> so maybe this didn't work or caused crashes?  Again, I can work around it
> but it would have been nice to hook SIGHUP and take certain actions, e.g.
> suppose your Perl module has additional config stuff that needs to be reloaded.

Sure. Feel free to add the flag and experiment. I recommend working with
the v3.0.x branch, as v2.2.x is in permanent feature freeze.

-Arran

Arran Cudbard-Bell <a.cudbardb at freeradius.org>
FreeRADIUS development team

FD31 3077 42EC 7FCD 32FE 5EE2 56CF 27F9 30A8 CAA2

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 872 bytes
Desc: Message signed with OpenPGP using GPGMail
URL: <http://lists.freeradius.org/pipermail/freeradius-users/attachments/20150219/4d0dcb52/attachment.sig>


More information about the Freeradius-Users mailing list