0 Replies Latest reply on Aug 17, 2015 3:22 PM by James Donohue

    Compliance Rule: How to check for a value range in a text file

    James Donohue

      Hi Community,

      I already found a way(thru this Board) to check the REV in the EXPORTS file on my Windows Devices but wanted to ask a more specific question. Is there a way to check for a numeric range in a text file? My current rule does the following:


      "Configuration File Entry:/C/Windows/rsc/exports//*" exists  AND


      foreach "Configuration File Entry:/C/Windows/rsc/exports//*"

         "Value4 as String (All OS)" = "REV=9"  OR

         "Value4 as String (All OS)" = "REV=10"  OR

         "Value4 as String (All OS)" = "REV=11"  OR

         "Value4 as String (All OS)" = "REV=12"



      Can a Rule be constructed to 'drill down' to the REV= portion of the file and check the data directly following it? I'm trying to see if I could check the data after the equal sign and ensure that it is between 9 and 12.


      The line in the EXPORTS file is formatted like this:    ro       #PROD    TestBox1.testbc.com    REV=12