On Mon, Mar 31, 2003 at 11:48:25AM -0500, Alan DeKok wrote:
> Try:
> detailfile = /radacct/%{%{config:Acct-Type}:-NOREALM}_%Y%m%d.log
>
> Acct-Type is a server configuration directive, and never goes into
> the reply.
I made some new experiences and I found a way to do what I want. This is
the way:
acct_users:
DEFAULT NAS-IP-Address==10.0.42.65, Called-Station-Id==9100
Realm := csd.sfr
radiusd.conf:
detailfile = /%{reply:Realm}_%Y%m%d.log
instantiate {
}
authorize {
suffix
autztype NoAuth {
ok
}
files
}
authenticate {
authtype NoAuth {
ok
}
}
preacct {
files
}
accounting {
detail
}
But some weird things:
1/ radiusd screams that "WARNING! Check item Realm ?found in reply item
list for user "DEFAULT". ?This attribute MUST go on the first line with
the other check items". But if I move "Realm := csd.sfr" on the first
line it doesn't work (ie %{reply:Realm} is empty).
2/ If I use the :- operator it doesn't work:
detailfile = /%{%{reply:Realm}:-NOREALM}_%Y%m%d.log
or detailfile = /%{NOREALM:-%{reply:Realm}}_%Y%m%d.log
don't do it: in the first case it returns NOREALM whatever the Realm is
defined or not; in the second case it only uses the Realm value even if
it is empty.
--
Christophe.
-
List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html