Heikki,
This is what I ended up with in my pre-Handler hook:
unless (my $r = $p->get_attr('Realm')) {
if (my $ci = $p->get_attr('Connect-Info')) {
if ($ci =~ /([^\.]+\.[^\.]+)$/) {
$p->changeUserName(lc($un.'@'.$1));
$p->change_attr('Connect-Info', '');
}
}
}
Assuming I get no ‘Realm’ (user did not login with user@realm), then I can pull
the domain part out and try to realm with that. The “connect-info” is an
arbitrary text that we can supply from the NAS side.
--
inoc.net!rblayzor
XMPP: rblayzor.AT.inoc.net
PGP: https://inoc.net/~rblayzor/
> On Nov 15, 2017, at 10:39 AM, Heikki Vatiainen <[email protected]> wrote:
>
> Since get_attr('Realm') does not work, to get the realm part from the
> username you need to do something like below (using shorthand syntax):
_______________________________________________
radiator mailing list
[email protected]
http://lists.open.com.au/mailman/listinfo/radiator