paloaltonetworks.panos.panos_pbf_rule module – Manage Policy Based Forwarding rules on PAN-OS.
Note
This module is part of the paloaltonetworks.panos collection (version 2.21.2).
To install it, use: ansible-galaxy collection install paloaltonetworks.panos
.
You need further requirements to be able to use this module,
see Requirements for details.
To use it in a playbook, specify: paloaltonetworks.panos.panos_pbf_rule
.
New in paloaltonetworks.panos 1.0.0
Synopsis
Manage Policy Based Forwarding rules on PAN-OS.
Requirements
The below requirements are needed on the host that executes this module.
pandevice >= 0.13.0
pan-python
Parameters
Parameter |
Comments |
---|---|
Deprecated Use provider to specify PAN-OS connectivity instead. The API key to use instead of generating it using username / password. |
|
List of applications. Default: :ansible-option-default:`["any"]` |
|
Add an audit comment to the rule being defined. This is only applied if there was a change to the rule. |
|
The description. |
|
List of destination addresses. When referencing predefined EDLs, use config names of the EDLS not their full names. The config names can be found with the CLI… request system external-list show type predefined-ip name <tab> panw-bulletproof-ip-list panw-bulletproof-ip-list panw-highrisk-ip-list panw-highrisk-ip-list panw-known-ip-list panw-known-ip-list panw-torexit-ip-list panw-torexit-ip-list Default: :ansible-option-default:`["any"]` |
|
(Panorama only) The device group the operation should target. Default: :ansible-option-default:`"shared"` |
|
Disable this rule. Choices: |
|
Set to enforce symmetric return. Choices: |
|
|
|
The egress interface. |
|
Set to disable this rule if nexthop / monitor IP is unreachable. Choices: |
|
The monitor IP address. |
|
The monitor profile to use. |
|
The next hop type. Leave this as None for a next hop type of ‘None’. To specify a next-hop of none, leave this parameter unset. Choices: |
|
The next hop value if forward next hop type is not None. |
|
The vsys to forward to if action is set to forward to a vsys. |
|
Source from type. Choices: |
|
The source values for the given type. |
|
When state=gathered. An advanced filtering option to filter results returned from PAN-OS. Refer to the guide discussing gathered_filter for more information. |
|
The group tag. |
|
Deprecated Use provider to specify PAN-OS connectivity instead. The IP address or hostname of the PAN-OS device being configured. |
|
Position to place the rule in. Choices: |
|
Name of the rule. |
|
Set to negate the destination. Choices: |
|
Set to negate the source. Choices: |
|
Applicable for Panorama only. Negate the value for target. Choices: |
|
Deprecated Use provider to specify PAN-OS connectivity instead. The password to use for authentication. This is ignored if api_key is specified. |
|
Deprecated Use provider to specify PAN-OS connectivity instead. The port number to connect to the PAN-OS device on. Default: :ansible-option-default:`443` |
|
A dict object containing connection details. |
|
The API key to use instead of generating it using username / password. |
|
The IP address or hostname of the PAN-OS device being configured. |
|
The password to use for authentication. This is ignored if api_key is specified. |
|
The port number to connect to the PAN-OS device on. Default: :ansible-option-default:`443` |
|
The serial number of a firewall to use for targeted commands. If ip_address is not a Panorama PAN-OS device, then this param is ignored. |
|
The username to use for authentication. This is ignored if api_key is specified. Default: :ansible-option-default:`"admin"` |
|
The rulebase in which the rule is to exist. If left unspecified, this defaults to rulebase=pre-rulebase for Panorama. For NGFW, this is always set to be rulebase=rulebase. Choices: |
|
The schedule. |
|
List of services. Default: :ansible-option-default:`["any"]` |
|
List of source IP addresses. When referencing predefined EDLs, use config names of the EDLS not their full names. The config names can be found with the CLI… request system external-list show type predefined-ip name <tab> panw-bulletproof-ip-list panw-bulletproof-ip-list panw-highrisk-ip-list panw-highrisk-ip-list panw-known-ip-list panw-known-ip-list panw-torexit-ip-list panw-torexit-ip-list Default: :ansible-option-default:`["any"]` |
|
List of source users. Default: :ansible-option-default:`["any"]` |
|
List of symmetric return addresses. |
|
List of tags. |
|
Applicable for Panorama only. Apply this rule exclusively to the listed firewall serial numbers. |
|
Deprecated Use provider to specify PAN-OS connectivity instead. The username to use for authentication. This is ignored if api_key is specified. Default: :ansible-option-default:`"admin"` |
|
The rule UUID. Note that this is currently more of a read-only field. Usage of the UUID cannot currently take the place of using the rule name as the primary identifier. |
|
The vsys this object belongs to. Default: :ansible-option-default:`"vsys1"` |
Notes
Note
Checkmode is supported.
Panorama is supported.
PAN-OS connectivity should be specified using provider or the classic PAN-OS connectivity params (ip_address, username, password, api_key, and port). If both are present, then the classic params are ignored.
Examples
- name: add a pbf rule
paloaltonetworks.panos.panos_pbf_rule:
provider: '{{ provider }}'
name: 'my-pbf'
description: 'Made by Ansible'
from_value: ['myZone']
action: 'discard'