ltm rule command POLICY rulesΒΆ

iRule(1)		      BIG-IP TMSH Manual		      iRule(1)



POLICY::rules
       Returns the policy rules of the supplied policy that had actions
       executed.

SYNOPSIS
       POLICY::rules ('matched')? POLICY_NAME

DESCRIPTION
       Returns the policy rules of the supplied policy that had actions
       executed.

       Syntax

       POLICY::rules matched 

	    * Returns the policy rules of the supplied policy that had actions
	      executed.

RETURN VALUE
VALID DURING
EXAMPLES
	# Log the policy targets for this virtual server
	when HTTP_REQUEST {

		log local0. "Looping through \[POLICY::names matched\]: [POLICY::names matched]"
		foreach policy [POLICY::names matched] {
			log local0. "\[POLICY::rules matched $policy\]: [POLICY::rules matched $policy]"
		}
	}

	# /var/log/ltm output:
	: Looping through [POLICY::names matched]: /Common/serverssl_policy /Common/uri_to_pool_policy
	: [POLICY::rules matched /Common/serverssl_policy]: serverssl_disable_default_rule
	: [POLICY::rules matched /Common/uri_to_pool_policy]: pool2_rule

HINTS
SEE ALSO
CHANGE LOG
       @BIGIP-11.4.0 --First introduced the command.



BIG-IP				  2017-01-31			      iRule(1)