RE: finding out which section we're in
Sorry, realise this request is a bit ambiguous - to state things better, I have policy.d unlang "scripts" which are called both in authorize, accounting and so on (same script), and in the script I want to say if (section==authorize) { stuff } elseif (section==accounting) { stuff } Thanks Andy -----Original Message----- From: Freeradius-Users [mailto:freeradius-users-bounces+andy.franks=sath.nhs.uk@lists.freeradius.org] On Behalf Of Franks Andy (IT Technical Architecture Manager) Sent: 02 December 2015 17:59 To: freeradius-users@lists.freeradius.org Subject: finding out which section we're in Hi all, Very quick question hopefully. Is there a way of (in unlang) finding out which section we're in? I have policies called from authorize, accounting etc which do similar things, but it would be nice to do something different based on "section". I've had a look at the runtime variables and dictionaries but can't anything obvious. Thanks Andy - List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html
On Dec 2, 2015, at 1:04 PM, Franks Andy (IT Technical Architecture Manager) <Andy.Franks@sath.nhs.uk> wrote:
Sorry, realise this request is a bit ambiguous - to state things better, I have policy.d unlang "scripts" which are called both in authorize, accounting and so on (same script), and in the script I want to say if (section==authorize) { stuff } elseif (section==accounting) { stuff }
It's probably best to just have 3 policies. There is a limited to the flexibility of "unlang". Alan DeKok.
On Dec 2, 2015, at 1:04 PM, Franks Andy (IT Technical Architecture Manager) <Andy.Franks@sath.nhs.uk> wrote:
Sorry, realise this request is a bit ambiguous - to state things better, I have policy.d unlang "scripts" which are called both in authorize, accounting and so on (same script), and in the script I want to say if (section==authorize) { stuff } elseif (section==accounting) { stuff }
%{Request-Processing-Stage} -Arran
participants (3)
-
Alan DeKok -
Arran Cudbard-Bell -
Franks Andy (IT Technical Architecture Manager)