3 Replies Latest reply on Jan 25, 2017 2:04 AM by asabban

    List.lastmatches

    feickholt

      Hi

      i have a problem with List.Lastmatches.

       

      I tried to figure out which elements is matched in an IpRangeList

       

      I used:

       

      stop rule set if client.ip is not in range list IPLIST

      then

      set element = list.lastmatches  (element is string)

       

      Using rule trace i can see list.lastmatches returns null.....

       

      cat i use  list.lastmatches  only with stringlists?

       

      Frank

        • 1. Re: List.lastmatches
          asabban

          You can use it with IP Range lists as well. Are you really doing a "Client.IP is not in range list..."? If so, there is no match, so List.LastMatches has nothing to add. I have tried "Client.IP is in range list..." and it correctly wrote the matching entry into a user-defined property as a string.

           

          Best,

          Andre

          • 2. Re: List.lastmatches
            feickholt

            This seems to be a bug. (7.5.2)

             

            If I try it my way this won't work.

            If there is no match in the first rule I'd like to finish executing the ruleset.

            If there is a match I expect this will be stores in the list.lastmatches property.

            and I can read it by the next rule.

             

            This does not work.

             

            If a say 

            if client.ip is in range list IPLIST then set element = list.lastmatches

            everthing is ok.

            • 3. Re: List.lastmatches
              asabban

              Hey Frank,

               

              unfortunately I don't understand what you try to do :-) Are you able to send me your rule set so that I can replicate the problem? Then I can hopefully tell you more.

               

              Best,

              Andre