[RADIATOR] Change attribute value that send to proxy

Heikki Vatiainen hvn at open.com.au
Thu Aug 2 13:09:35 CDT 2012


On 08/02/2012 03:45 PM, eliran shlomo wrote:

> i need to change the value of attribute in the Access-Accept packet that
> sends to the proxy radius.

Try using 'StripFromRequest RB-Context-Name' with the Handler. Something
like this:

<Handler or Realm ...>
    StripFromRequest RB-Context-Name
    <AuthBy RADIUS>
        # Proxying done here
    </AuthBy>
</Handler or Realm>

> i figure out that i need to use ReplyHook
> but can you point me how to do it?
> i tried this one

ReplyHook runs when the reply is received from the proxy. The hook will
modify the request sent to proxy, but it will do it too late. The
request was already sent.

Thanks,
Heikki

> sub
> {
>     my $p = ${$_[0]};   # proxy reply packet
>     my $rp = ${$_[1]};  # reply packet to NAS
>     my $op = ${$_[2]};  # original request packet
>     my $sp = ${$_[3]};  # packet sent to proxy
> 
>     my $code = $p->code;
> 
>     if ($code eq 'Access-Accept')
>     {
>                    $sp->delete_attr('RB-Context-Name');
> }
> 
>     return;
> }
> 
> 
> 
> 
> _______________________________________________
> radiator mailing list
> radiator at open.com.au
> http://www.open.com.au/mailman/listinfo/radiator
> 


-- 
Heikki Vatiainen <hvn at open.com.au>

Radiator: the most portable, flexible and configurable RADIUS server
anywhere. SQL, proxy, DBM, files, LDAP, NIS+, password, NT, Emerald,
Platypus, Freeside, TACACS+, PAM, external, Active Directory, EAP, TLS,
TTLS, PEAP, TNC, WiMAX, RSA, Vasco, Yubikey, MOTP, HOTP, TOTP,
DIAMETER etc. Full source on Unix, Windows, MacOSX, Solaris, VMS,
NetWare etc.


More information about the radiator mailing list