Alan DeKok wrote:
Joe Maimon wrote:
The if matches just fine and updates with rlm_policy, but I couldnt get
something reasonable in unlang to parse successfully. I would appreciate
some tips.

Here is what I am doing with rlm_policy


        if (request:Class =* "" ) {
                if (request:Client-Short-Name == "noc03rt07") {
                        control .= {
                                Home-Server-Pool := "pool-noc03-8e6"
                        }
                }
        }


Here is how I tried doing it with unlang

               if (request:Class =* "" ) {
                       if (request:Client-Short-Name == "noc03rt07") {
                               update request {
                                    Home-Server-Pool := "pool-noc03-8e6"
                               }
                       }
               }

I also tried this

               if (request:Class =~ ".*" ) {
                       if (request:Client-Short-Name == "noc03rt07") {
                               update request {
                                    Home-Server-Pool := "pool-noc03-8e6"
                               }
                       }
               }


As I am currently carrying patches for rlm_policy, the question is
whether it is worthwhile to switch focus to unlang.

  IIRC, most of the patches you had for the policy module went into
source control.  What's left?

You got the "big" one.

These are all the patches I am currently carrying.

020-client-short-name.dpatch
030-substar_regex.patch
080-keep-local-av-proxy.dpatch
130-rlm-policy-fix.dpatch
140-rlm-policy-subops.dpatch
200-cmp-operators-fix.dpatch
230-fix-policy-null-myvp.dpatch
245-policy-xlat.dpatch
310-rlm_exec-nullchecks.dpatch
380-rlm_policy-evaluate-seg
400-rlm_policy-parse-assert
430-rlm_policy-missing-policy-ok
440-proxy-home-server-pool

Some are hacks, most are old and you have probably seen them before.

About the only thing I can say with confidence, is worksforme.

I suppose I should use bugzilla to post them even if the attached tarball comes through.



  Alan DeKok.
-
List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html


Attachment: jm-freeradius-2.1.8-git-20090923.tar.gz
Description: GNU Zip compressed data

-
List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html

Reply via email to