rewrite attribute in freeradius 3
Dave Aldwinckle
daldwinc at uwaterloo.ca
Thu Jun 11 14:14:47 CEST 2015
Hi Aleksander,
You shouldn't need to rewrite User-Name like that.
Look at:
/etc/raddb/mods-enabled/realm and
/etc/raddb/proxy.conf
Particularly, in proxy.conf...
<SNIP>
# Normally, when an incoming User-Name is matched against the
# realm, the realm name is "stripped" off, and the "stripped"
# user name is used to perform matches.
#
# e.g. User-Name = "bob at example.com" will result in two new
# attributes being created by the "realms" module:
#
# Stripped-User-Name = "bob"
# Realm = "example.com"
#
# The Stripped-User-Name is then used as a key in the "users"
# file, for example.
#
# If you do not want this to happen, uncomment "nostrip" below.
#
# nostrip
</SNIP>
Dave Aldwinckle
On 15-06-11 04:16 AM, Aleksander Vines wrote:
> Hi list,
>
>
> I'm trying to set up Freeradius (3.0.4 - as its whats included in the centos repo) for Eduroam. It should act as a proxy to an internal server.
>
>
> Essentially, what I'm stuck at now is to rewrite the incoming User-Name attribute to remove the @domain postfix.
>
>
> In earlier versions I could use something like this:
> attr_rewrite rewrite_realm {
> attribute = User-Name
> searchin = packet
> searchfor = "^(.*)@adsl\.realm1$"
> replacewith = "%{1}"
> ignore_case = no
> new_attribute = no
> max_matches = 10
> append = no
> }
>
>
> However, it seems its not supported in Freeradius 3:
>
>
>
> -
> List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html
More information about the Freeradius-Users
mailing list