:source: fortios_wanopt_profile.py
:orphan:
.. fortios_wanopt_profile:
fortios_wanopt_profile -- Configure WAN optimization profiles in Fortinet's FortiOS and FortiGate.
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
.. versionadded:: 2.0.0
.. contents::
:local:
:depth: 1
Synopsis
--------
- This module is able to configure a FortiGate or FortiOS (FOS) device by allowing the user to set and modify wanopt feature and profile category. Examples include all parameters and values need to be adjusted to datasources before usage. Tested with FOS v6.0.0
Requirements
------------
The below requirements are needed on the host that executes this module.
- ansible>=2.16
Tips
----
Using member operation to add an element to an existing object.
FortiOS Version Compatibility
-----------------------------
Supported Version Ranges: v6.0.0 -> v7.6.6
Parameters
----------
.. raw:: html
- access_token - Token-based authentication. Generated from GUI of Fortigate. type: str required: false
- enable_log - Enable/Disable logging for task. type: bool required: false default: False
- vdom - Virtual domain, among those defined previously. A vdom is a virtual instance of the FortiGate that can be configured and used as a different unit. type: str default: root
- member_path - Member attribute path to operate on. type: str
- member_state - Add or delete a member under specified attribute path. type: str choices: present, absent
- state - Indicates whether to create or remove the object. type: str required: true choices: present, absent
- wanopt_profile - Configure WAN optimization profiles. type: dict
more...
| Supported Version Ranges |
| wanopt_profile |
v6.0.0 -> 7.6.6 |
- auth_group - Optionally add an authentication group to restrict access to the WAN Optimization tunnel to peers in the authentication group. Source wanopt.auth-group.name. type: str
more...
|
Supported Version Ranges |
| auth_group |
v6.0.0 -> 7.6.6 |
- cifs - Enable/disable CIFS (Windows sharing) WAN Optimization and configure CIFS WAN Optimization features. type: dict
more...
| Supported Version Ranges |
| cifs |
v6.0.0 -> 7.6.6 |
- byte_caching - Enable/disable byte-caching. Byte caching reduces the amount of traffic by caching file data sent across the WAN and in future serving if from the cache. type: str choices: enable, disable
more...
|
Supported Version Ranges |
| byte_caching |
v6.0.0 -> 7.6.6 |
| [enable] |
v6.0.0 -> 7.6.6 |
| [disable] |
v6.0.0 -> 7.6.6 |
- log_traffic - Enable/disable logging. type: str choices: enable, disable
more...
|
Supported Version Ranges |
| log_traffic |
v6.0.0 -> v7.2.2 |
| [enable] |
v6.0.0 -> v7.2.2 |
| [disable] |
v6.0.0 -> v7.2.2 |
- port - Single port number or port number range for CIFS. Only packets with a destination port number that matches this port number or range are accepted by this profile. type: int
more...
|
Supported Version Ranges |
| port |
v6.0.0 -> v6.2.7 |
- prefer_chunking - Select dynamic or fixed-size data chunking for WAN Optimization. type: str choices: dynamic, fix
more...
|
Supported Version Ranges |
| prefer_chunking |
v6.0.0 -> 7.6.6 |
| [dynamic] |
v6.0.0 -> 7.6.6 |
| [fix] |
v6.0.0 -> 7.6.6 |
- protocol_opt - Select protocol specific optimization or generic TCP optimization. type: str choices: protocol, tcp
more...
|
Supported Version Ranges |
| protocol_opt |
v6.4.0 -> 7.6.6 |
| [protocol] |
v6.4.0 -> 7.6.6 |
| [tcp] |
v6.4.0 -> 7.6.6 |
- secure_tunnel - Enable/disable securing the WAN Opt tunnel using SSL. Secure and non-secure tunnels use the same TCP port (7810). type: str choices: enable, disable
more...
|
Supported Version Ranges |
| secure_tunnel |
v6.0.0 -> 7.6.6 |
| [enable] |
v6.0.0 -> 7.6.6 |
| [disable] |
v6.0.0 -> 7.6.6 |
- status - Enable/disable WAN Optimization. type: str choices: enable, disable
more...
|
Supported Version Ranges |
| status |
v6.0.0 -> 7.6.6 |
| [enable] |
v6.0.0 -> 7.6.6 |
| [disable] |
v6.0.0 -> 7.6.6 |
- tunnel_sharing - Tunnel sharing mode for aggressive/non-aggressive and/or interactive/non-interactive protocols. type: str choices: shared, express-shared, private
more...
|
Supported Version Ranges |
| tunnel_sharing |
v6.0.0 -> 7.6.6 |
| [shared] |
v6.0.0 -> 7.6.6 |
| [express-shared] |
v6.0.0 -> 7.6.6 |
| [private] |
v6.0.0 -> 7.6.6 |
- comments - Comment. type: str
more...
|
Supported Version Ranges |
| comments |
v6.0.0 -> 7.6.6 |
- ftp - Enable/disable FTP WAN Optimization and configure FTP WAN Optimization features. type: dict
more...
| Supported Version Ranges |
| ftp |
v6.0.0 -> 7.6.6 |
- byte_caching - Enable/disable byte-caching. Byte caching reduces the amount of traffic by caching file data sent across the WAN and in future serving if from the cache. type: str choices: enable, disable
more...
|
Supported Version Ranges |
| byte_caching |
v6.0.0 -> 7.6.6 |
| [enable] |
v6.0.0 -> 7.6.6 |
| [disable] |
v6.0.0 -> 7.6.6 |
- log_traffic - Enable/disable logging. type: str choices: enable, disable
more...
|
Supported Version Ranges |
| log_traffic |
v6.0.0 -> v7.2.2 |
| [enable] |
v6.0.0 -> v7.2.2 |
| [disable] |
v6.0.0 -> v7.2.2 |
- port - Single port number or port number range for FTP. Only packets with a destination port number that matches this port number or range are accepted by this profile. type: int
more...
|
Supported Version Ranges |
| port |
v6.0.0 -> v6.2.7 |
- prefer_chunking - Select dynamic or fixed-size data chunking for WAN Optimization. type: str choices: dynamic, fix
more...
|
Supported Version Ranges |
| prefer_chunking |
v6.0.0 -> 7.6.6 |
| [dynamic] |
v6.0.0 -> 7.6.6 |
| [fix] |
v6.0.0 -> 7.6.6 |
- protocol_opt - Select protocol specific optimization or generic TCP optimization. type: str choices: protocol, tcp
more...
|
Supported Version Ranges |
| protocol_opt |
v6.4.0 -> 7.6.6 |
| [protocol] |
v6.4.0 -> 7.6.6 |
| [tcp] |
v6.4.0 -> 7.6.6 |
- secure_tunnel - Enable/disable securing the WAN Opt tunnel using SSL. Secure and non-secure tunnels use the same TCP port (7810). type: str choices: enable, disable
more...
|
Supported Version Ranges |
| secure_tunnel |
v6.0.0 -> 7.6.6 |
| [enable] |
v6.0.0 -> 7.6.6 |
| [disable] |
v6.0.0 -> 7.6.6 |
- ssl - Enable/disable SSL/TLS offloading (hardware acceleration) for traffic in this tunnel. type: str choices: enable, disable
more...
|
Supported Version Ranges |
| ssl |
v6.4.0 -> v7.2.2 |
| [enable] |
v6.4.0 -> v7.2.2 |
| [disable] |
v6.4.0 -> v7.2.2 |
- status - Enable/disable WAN Optimization. type: str choices: enable, disable
more...
|
Supported Version Ranges |
| status |
v6.0.0 -> 7.6.6 |
| [enable] |
v6.0.0 -> 7.6.6 |
| [disable] |
v6.0.0 -> 7.6.6 |
- tunnel_sharing - Tunnel sharing mode for aggressive/non-aggressive and/or interactive/non-interactive protocols. type: str choices: shared, express-shared, private
more...
|
Supported Version Ranges |
| tunnel_sharing |
v6.0.0 -> 7.6.6 |
| [shared] |
v6.0.0 -> 7.6.6 |
| [express-shared] |
v6.0.0 -> 7.6.6 |
| [private] |
v6.0.0 -> 7.6.6 |
- http - Enable/disable HTTP WAN Optimization and configure HTTP WAN Optimization features. type: dict
more...
| Supported Version Ranges |
| http |
v6.0.0 -> 7.6.6 |
- byte_caching - Enable/disable byte-caching. Byte caching reduces the amount of traffic by caching file data sent across the WAN and in future serving if from the cache. type: str choices: enable, disable
more...
|
Supported Version Ranges |
| byte_caching |
v6.0.0 -> 7.6.6 |
| [enable] |
v6.0.0 -> 7.6.6 |
| [disable] |
v6.0.0 -> 7.6.6 |
- log_traffic - Enable/disable logging. type: str choices: enable, disable
more...
|
Supported Version Ranges |
| log_traffic |
v6.0.0 -> v7.2.2 |
| [enable] |
v6.0.0 -> v7.2.2 |
| [disable] |
v6.0.0 -> v7.2.2 |
- port - Single port number or port number range for HTTP. Only packets with a destination port number that matches this port number or range are accepted by this profile. type: int
more...
|
Supported Version Ranges |
| port |
v6.0.0 -> v6.2.7 |
- prefer_chunking - Select dynamic or fixed-size data chunking for WAN Optimization. type: str choices: dynamic, fix
more...
|
Supported Version Ranges |
| prefer_chunking |
v6.0.0 -> 7.6.6 |
| [dynamic] |
v6.0.0 -> 7.6.6 |
| [fix] |
v6.0.0 -> 7.6.6 |
- protocol_opt - Select protocol specific optimization or generic TCP optimization. type: str choices: protocol, tcp
more...
|
Supported Version Ranges |
| protocol_opt |
v6.4.0 -> 7.6.6 |
| [protocol] |
v6.4.0 -> 7.6.6 |
| [tcp] |
v6.4.0 -> 7.6.6 |
- secure_tunnel - Enable/disable securing the WAN Opt tunnel using SSL. Secure and non-secure tunnels use the same TCP port (7810). type: str choices: enable, disable
more...
|
Supported Version Ranges |
| secure_tunnel |
v6.0.0 -> 7.6.6 |
| [enable] |
v6.0.0 -> 7.6.6 |
| [disable] |
v6.0.0 -> 7.6.6 |
- ssl - Enable/disable SSL/TLS offloading (hardware acceleration) for traffic in this tunnel. type: str choices: enable, disable
more...
|
Supported Version Ranges |
| ssl |
v6.0.0 -> 7.6.6 |
| [enable] |
v6.0.0 -> 7.6.6 |
| [disable] |
v6.0.0 -> 7.6.6 |
- ssl_port - Port on which to expect HTTPS traffic for SSL/TLS offloading. type: int
more...
|
Supported Version Ranges |
| ssl_port |
v6.0.0 -> v6.2.7 |
- status - Enable/disable WAN Optimization. type: str choices: enable, disable
more...
|
Supported Version Ranges |
| status |
v6.0.0 -> 7.6.6 |
| [enable] |
v6.0.0 -> 7.6.6 |
| [disable] |
v6.0.0 -> 7.6.6 |
- tunnel_non_http - Configure how to process non-HTTP traffic when a profile configured for HTTP traffic accepts a non-HTTP session. Can occur if an application sends non-HTTP traffic using an HTTP destination port. type: str choices: enable, disable
more...
|
Supported Version Ranges |
| tunnel_non_http |
v6.0.0 -> v6.2.7 |
| [enable] |
v6.0.0 -> v6.2.7 |
| [disable] |
v6.0.0 -> v6.2.7 |
- tunnel_sharing - Tunnel sharing mode for aggressive/non-aggressive and/or interactive/non-interactive protocols. type: str choices: shared, express-shared, private
more...
|
Supported Version Ranges |
| tunnel_sharing |
v6.0.0 -> 7.6.6 |
| [shared] |
v6.0.0 -> 7.6.6 |
| [express-shared] |
v6.0.0 -> 7.6.6 |
| [private] |
v6.0.0 -> 7.6.6 |
- unknown_http_version - How to handle HTTP sessions that do not comply with HTTP 0.9, 1.0, or 1.1. type: str choices: reject, tunnel, best-effort
more...
|
Supported Version Ranges |
| unknown_http_version |
v6.0.0 -> v6.2.7 |
| [reject] |
v6.0.0 -> v6.2.7 |
| [tunnel] |
v6.0.0 -> v6.2.7 |
| [best-effort] |
v6.0.0 -> v6.2.7 |
- mapi - Enable/disable MAPI email WAN Optimization and configure MAPI WAN Optimization features. type: dict
more...
| Supported Version Ranges |
| mapi |
v6.0.0 -> 7.6.6 |
- byte_caching - Enable/disable byte-caching. Byte caching reduces the amount of traffic by caching file data sent across the WAN and in future serving if from the cache. type: str choices: enable, disable
more...
|
Supported Version Ranges |
| byte_caching |
v6.0.0 -> 7.6.6 |
| [enable] |
v6.0.0 -> 7.6.6 |
| [disable] |
v6.0.0 -> 7.6.6 |
- log_traffic - Enable/disable logging. type: str choices: enable, disable
more...
|
Supported Version Ranges |
| log_traffic |
v6.0.0 -> v7.2.2 |
| [enable] |
v6.0.0 -> v7.2.2 |
| [disable] |
v6.0.0 -> v7.2.2 |
- port - Single port number or port number range for MAPI. Only packets with a destination port number that matches this port number or range are accepted by this profile. type: int
more...
|
Supported Version Ranges |
| port |
v6.0.0 -> v6.2.7 |
- secure_tunnel - Enable/disable securing the WAN Opt tunnel using SSL. Secure and non-secure tunnels use the same TCP port (7810). type: str choices: enable, disable
more...
|
Supported Version Ranges |
| secure_tunnel |
v6.0.0 -> 7.6.6 |
| [enable] |
v6.0.0 -> 7.6.6 |
| [disable] |
v6.0.0 -> 7.6.6 |
- status - Enable/disable WAN Optimization. type: str choices: enable, disable
more...
|
Supported Version Ranges |
| status |
v6.0.0 -> 7.6.6 |
| [enable] |
v6.0.0 -> 7.6.6 |
| [disable] |
v6.0.0 -> 7.6.6 |
- tunnel_sharing - Tunnel sharing mode for aggressive/non-aggressive and/or interactive/non-interactive protocols. type: str choices: shared, express-shared, private
more...
|
Supported Version Ranges |
| tunnel_sharing |
v6.0.0 -> 7.6.6 |
| [shared] |
v6.0.0 -> 7.6.6 |
| [express-shared] |
v6.0.0 -> 7.6.6 |
| [private] |
v6.0.0 -> 7.6.6 |
- name - Profile name. type: str required: true
more...
|
Supported Version Ranges |
| name |
v6.0.0 -> 7.6.6 |
- tcp - Enable/disable TCP WAN Optimization and configure TCP WAN Optimization features. type: dict
more...
| Supported Version Ranges |
| tcp |
v6.0.0 -> 7.6.6 |
- byte_caching - Enable/disable byte-caching. Byte caching reduces the amount of traffic by caching file data sent across the WAN and in future serving if from the cache. type: str choices: enable, disable
more...
|
Supported Version Ranges |
| byte_caching |
v6.0.0 -> 7.6.6 |
| [enable] |
v6.0.0 -> 7.6.6 |
| [disable] |
v6.0.0 -> 7.6.6 |
- byte_caching_opt - Select whether TCP byte-caching uses system memory only or both memory and disk space. type: str choices: mem-only, mem-disk
more...
|
Supported Version Ranges |
| byte_caching_opt |
v6.0.0 -> 7.6.6 |
| [mem-only] |
v6.0.0 -> 7.6.6 |
| [mem-disk] |
v6.0.0 -> 7.6.6 |
- log_traffic - Enable/disable logging. type: str choices: enable, disable
more...
|
Supported Version Ranges |
| log_traffic |
v6.0.0 -> v7.2.2 |
| [enable] |
v6.0.0 -> v7.2.2 |
| [disable] |
v6.0.0 -> v7.2.2 |
- port - Port numbers or port number ranges for TCP. Only packets with a destination port number that matches this port number or range are accepted by this profile. type: str
more...
|
Supported Version Ranges |
| port |
v6.0.0 -> 7.6.6 |
- secure_tunnel - Enable/disable securing the WAN Opt tunnel using SSL. Secure and non-secure tunnels use the same TCP port (7810). type: str choices: enable, disable
more...
|
Supported Version Ranges |
| secure_tunnel |
v6.0.0 -> 7.6.6 |
| [enable] |
v6.0.0 -> 7.6.6 |
| [disable] |
v6.0.0 -> 7.6.6 |
- ssl - Enable/disable SSL/TLS offloading (hardware acceleration) for traffic in this tunnel. type: str choices: enable, disable
more...
|
Supported Version Ranges |
| ssl |
v6.0.0 -> 7.6.6 |
| [enable] |
v6.0.0 -> 7.6.6 |
| [disable] |
v6.0.0 -> 7.6.6 |
- ssl_port - Port numbers or port number ranges on which to expect HTTPS traffic for SSL/TLS offloading. type: str
more...
|
Supported Version Ranges |
| ssl_port |
v6.0.0 -> 7.6.6 |
- status - Enable/disable WAN Optimization. type: str choices: enable, disable
more...
|
Supported Version Ranges |
| status |
v6.0.0 -> 7.6.6 |
| [enable] |
v6.0.0 -> 7.6.6 |
| [disable] |
v6.0.0 -> 7.6.6 |
- tunnel_sharing - Tunnel sharing mode for aggressive/non-aggressive and/or interactive/non-interactive protocols. type: str choices: shared, express-shared, private
more...
|
Supported Version Ranges |
| tunnel_sharing |
v6.0.0 -> 7.6.6 |
| [shared] |
v6.0.0 -> 7.6.6 |
| [express-shared] |
v6.0.0 -> 7.6.6 |
| [private] |
v6.0.0 -> 7.6.6 |
- transparent - Enable/disable transparent mode. type: str choices: enable, disable
more...
|
Supported Version Ranges |
| transparent |
v6.0.0 -> 7.6.6 |
| [enable] |
v6.0.0 -> 7.6.6 |
| [disable] |
v6.0.0 -> 7.6.6 |
Notes
-----
.. note::
- Legacy fortiosapi has been deprecated, httpapi is the preferred way to run playbooks
- The module supports check_mode.
Examples
--------
.. code-block:: yaml+jinja
- name: Configure WAN optimization profiles.
fortinet.fortios.fortios_wanopt_profile:
vdom: "{{ vdom }}"
state: "present"
access_token: ""
wanopt_profile:
auth_group: " (source wanopt.auth-group.name)"
cifs:
byte_caching: "enable"
log_traffic: "enable"
port: "32767"
prefer_chunking: "dynamic"
protocol_opt: "protocol"
secure_tunnel: "enable"
status: "enable"
tunnel_sharing: "shared"
comments: ""
ftp:
byte_caching: "enable"
log_traffic: "enable"
port: "32767"
prefer_chunking: "dynamic"
protocol_opt: "protocol"
secure_tunnel: "enable"
ssl: "enable"
status: "enable"
tunnel_sharing: "shared"
http:
byte_caching: "enable"
log_traffic: "enable"
port: "32767"
prefer_chunking: "dynamic"
protocol_opt: "protocol"
secure_tunnel: "enable"
ssl: "enable"
ssl_port: "32767"
status: "enable"
tunnel_non_http: "enable"
tunnel_sharing: "shared"
unknown_http_version: "reject"
mapi:
byte_caching: "enable"
log_traffic: "enable"
port: "32767"
secure_tunnel: "enable"
status: "enable"
tunnel_sharing: "shared"
name: "default_name_44"
tcp:
byte_caching: "enable"
byte_caching_opt: "mem-only"
log_traffic: "enable"
port: ""
secure_tunnel: "enable"
ssl: "enable"
ssl_port: ""
status: "enable"
tunnel_sharing: "shared"
transparent: "enable"
Return Values
-------------
Common return values are documented: https://docs.ansible.com/ansible/latest/reference_appendices/common_return_values.html#common-return-values, the following are the fields unique to this module:
.. raw:: html
- build - Build number of the fortigate image returned: always type: str sample: 1547
- http_method - Last method used to provision the content into FortiGate returned: always type: str sample: PUT
- http_status - Last result given by FortiGate on last operation applied returned: always type: str sample: 200
- mkey - Master key (id) used in the last call to FortiGate returned: success type: str sample: id
- name - Name of the table used to fulfill the request returned: always type: str sample: urlfilter
- path - Path of the table used to fulfill the request returned: always type: str sample: webfilter
- revision - Internal revision number returned: always type: str sample: 17.0.2.10658
- serial - Serial number of the unit returned: always type: str sample: FGVMEVYYQT3AB5352
- status - Indication of the operation's result returned: always type: str sample: success
- vdom - Virtual domain used returned: always type: str sample: root
- version - Version of the FortiGate returned: always type: str sample: v5.6.3
Status
------
- This module is not guaranteed to have a backwards compatible interface.
Authors
-------
- Link Zheng (@chillancezen)
- Jie Xue (@JieX19)
- Hongbin Lu (@fgtdev-hblu)
- Frank Shen (@frankshen01)
- Miguel Angel Munoz (@mamunozgonzalez)
- Nicolas Thomas (@thomnico)
.. hint::
If you notice any issues in this documentation, you can create a pull request to improve it.