POLICY::controls¶
Description¶
Returns details about the policy controls for the policies associated
with the virtual server that the iRule is enabled on. Policy controls
are typically virtual server profiles or features which can be
enabled, disabled or modified per iRule execution via policies.
As of v11.4 the following controls are
available:
Policy control name | Description | Version added |
acceleration | Application Acceleration Manager (AAM) | v11.4 |
asm | Application Security Manager | v11.4 |
avr | Application Visibility and Reporting | v11.4 |
caching | HTTP caching | v11.4 |
classification | HTTP classification for Policy Enforcement Manager (PEM) | v11.4 |
compression | HTTP compression | v11.4 |
forwarding | pool, node, SNAT selection | v11.4 |
l7dos | Layer 7 Denial of Service profile | v11.4 |
request-adaptation | request adaptation | v11.4 |
response-adaptation | response adaptation | v11.4 |
server-ssl | Server SSL | v11.4 |
Syntax¶
POLICY::controls
POLICY::controls [ acceleration | asm | avr | caching | classification | compression | forwarding | l7dos | request-adaptation | response-adaptation | server-ssl ]
Examples¶
# Log the policy controls for this virtual server
when HTTP_REQUEST {
# Log the policy controls enabled on this virtual server
log local0. "\[POLICY::controls\]: [POLICY::controls]"
# Loop through each possible control type and log whether it is enabled or not (1 for enabled, 0 for not enabled)
foreach control {acceleration asm avr caching classification compression forwarding l7dos request-adaptation response-adaptation server-ssl} {
log local0. "\[POLICY::controls $control\]: [POLICY::controls $control]"
}
}
# /var/log/ltm output:
<HTTP_REQUEST>: [POLICY::controls]: forwarding compression server-ssl
<HTTP_REQUEST>: [POLICY::controls acceleration]: 0
<HTTP_REQUEST>: [POLICY::controls asm]: 0
<HTTP_REQUEST>: [POLICY::controls avr]: 0
<HTTP_REQUEST>: [POLICY::controls caching]: 0
<HTTP_REQUEST>: [POLICY::controls classification]: 0
<HTTP_REQUEST>: [POLICY::controls compression]: 1
<HTTP_REQUEST>: [POLICY::controls forwarding]: 1
<HTTP_REQUEST>: [POLICY::controls l7dos]: 0
<HTTP_REQUEST>: [POLICY::controls request-adaptation]: 0
<HTTP_REQUEST>: [POLICY::controls response-adaptation]: 0
<HTTP_REQUEST>: [POLICY::controls server-ssl]: 1