Note
This module is part of the fortinet.fortimanager collection (version 2.10.0).
You might already have this collection installed if you are using the ansible package. It is not included in ansible-core. To check whether it is installed, run ansible-galaxy collection list.
To install it, use: ansible-galaxy collection install fortinet.fortimanager.
To use it in a playbook, specify: fortinet.fortimanager.fmgr_pkg_firewall_dospolicy.
New in fortinet.fortimanager 2.0.0
Parameter | Comments |
|---|---|
access_token string | The token to access FortiManager without using username and password. |
adom string / required | The parameter (adom) in requested url. |
bypass_validation boolean | Only set to True when module schema diffs with FortiManager API structure, module continues to execute without validating parameters. Choices:
|
enable_log boolean | Enable/Disable logging for task. Choices:
|
forticloud_access_token string | Authenticate Ansible client with forticloud API access token. |
pkg string / required | The parameter (pkg) in requested url. |
pkg_firewall_dospolicy dictionary | The top level parameters set. |
|
anomaly list / elements=dictionary |
Anomaly. |
|
action string |
Action taken when the threshold is reached. Choices:
|
|
log string |
Enable/disable logging for this anomaly. Choices:
|
|
name string |
Anomaly name. |
|
quarantine string |
Quarantine method. Choices:
|
|
quarantine_expiry aliases: quarantine-expiry string |
Duration of quarantine, from 1 minute to 364 days, 23 hours, and 59 minutes from now. |
|
quarantine_log aliases: quarantine-log string |
Enable/disable quarantine logging. Choices:
|
|
status string |
Enable/disable the active status of this anomaly sensor. Choices:
|
|
synproxy-tcp-mss string |
Deprecated, please rename it to synproxy_tcp_mss. Determine TCP maximum segment size Choices:
|
|
synproxy-tcp-sack string |
Deprecated, please rename it to synproxy_tcp_sack. Enable/disable TCP selective acknowledage Choices:
|
|
synproxy-tcp-timestamp string |
Deprecated, please rename it to synproxy_tcp_timestamp. Enable/disable TCP timestamp option for packets replied by… Choices:
|
|
synproxy-tcp-window string |
Deprecated, please rename it to synproxy_tcp_window. Determine TCP Window size for packets replied by syn proxy mo… Choices:
|
|
synproxy-tcp-windowscale string |
Deprecated, please rename it to synproxy_tcp_windowscale. Determine TCP window scale option value for packets repl… Choices:
|
|
synproxy-tos string |
Deprecated, please rename it to synproxy_tos. Determine TCP differentiated services code point value Choices:
|
|
synproxy-ttl string |
Deprecated, please rename it to synproxy_ttl. Determine Time to live Choices:
|
|
synproxy_tcp_mss string |
Determine TCP maximum segment size Choices:
|
|
synproxy_tcp_sack string |
Enable/disable TCP selective acknowledage Choices:
|
|
synproxy_tcp_timestamp string |
Enable/disable TCP timestamp option for packets replied by syn proxy module. Choices:
|
|
synproxy_tcp_window string |
Determine TCP Window size for packets replied by syn proxy module. Choices:
|
|
synproxy_tcp_windowscale string |
Determine TCP window scale option value for packets replied by syn proxy module. Choices:
|
|
synproxy_tos string |
Determine TCP differentiated services code point value Choices:
|
|
synproxy_ttl string |
Determine Time to live Choices:
|
|
threshold integer |
Number of detected instances per minute which triggers action |
|
threshold_default aliases: threshold(default) integer |
Threshold |
|
comments string |
Comment. |
|
dstaddr any |
(list or str) Destination address name from available addresses. |
|
interface string |
Incoming interface name from available interfaces. |
|
name string |
Policy name. |
|
policyid integer / required |
Policy ID. |
|
service any |
(list or str) Service object from available options. |
|
srcaddr any |
(list or str) Source address name from available addresses. |
|
status string |
Enable/disable this policy. Choices:
|
|
uuid string |
Universally Unique Identifier |
proposed_method string | The overridden method for the underlying Json RPC request. Choices:
|
rc_failed list / elements=integer | The rc codes list with which the conditions to fail will be overriden. |
rc_succeeded list / elements=integer | The rc codes list with which the conditions to succeed will be overriden. |
state string / required | The directive to create, update or delete an object. Choices:
|
workspace_locking_adom string | The adom to lock for FortiManager running in workspace mode, the value can be global and others including root. |
workspace_locking_timeout integer | The maximum time in seconds to wait for other user to release the workspace lock. Default: |
Note
- name: Example playbook
hosts: fortimanagers
gather_facts: false
connection: httpapi
vars:
ansible_httpapi_use_ssl: true
ansible_httpapi_validate_certs: false
ansible_httpapi_port: 443
tasks:
- name: Configure IPv4 DoS policies.
fortinet.fortimanager.fmgr_pkg_firewall_dospolicy:
bypass_validation: false
adom: ansible
pkg: ansible # package name
state: present
pkg_firewall_dospolicy:
comments: "ansible-comment1"
interface: "sslvpn_tun_intf"
policyid: 1
status: enable
- name: Gathering fortimanager facts
hosts: fortimanagers
gather_facts: false
connection: httpapi
vars:
ansible_httpapi_use_ssl: true
ansible_httpapi_validate_certs: false
ansible_httpapi_port: 443
tasks:
- name: Retrieve all the IPv4 DoS policies
fortinet.fortimanager.fmgr_fact:
facts:
selector: "pkg_firewall_dospolicy"
params:
adom: "ansible"
pkg: "ansible" # package name
DoS-policy: "your_value"
Common return values are documented here, the following are the fields unique to this module:
Key | Description |
|---|---|
meta dictionary | The result of the request. Returned: always |
|
request_url string |
The full url requested. Returned: always Sample: |
|
response_code integer |
The status of api request. Returned: always Sample: |
|
response_data list / elements=string |
The api response. Returned: always |
|
response_message string |
The descriptive message of the api response. Returned: always Sample: |
|
system_information dictionary |
The information of the target system. Returned: always |
rc integer | The status the request. Returned: always Sample: |
version_check_warning list / elements=string | Warning if the parameters used in the playbook are not supported by the current FortiManager version. Returned: complex |
© 2012–2018 Michael DeHaan
© 2018–2025 Red Hat, Inc.
Licensed under the GNU General Public License version 3.
https://docs.ansible.com/ansible/latest/collections/fortinet/fortimanager/fmgr_pkg_firewall_dospolicy_module.html