fortinet.fortios.fortios_system_np6 – Configure NP6 attributes in Fortinet’s FortiOS and FortiGate.
Note
This plugin is part of the fortinet.fortios collection (version 2.1.3).
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.fortios
.
To use it in a playbook, specify: fortinet.fortios.fortios_system_np6
.
New in version 2.10: of fortinet.fortios
Synopsis
This module is able to configure a FortiGate or FortiOS (FOS) device by allowing the user to set and modify system feature and np6 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.9.0
Parameters
Parameter |
Comments |
---|---|
Token-based authentication. Generated from GUI of Fortigate. |
|
Enable/Disable logging for task. Choices:
|
|
Member attribute path to operate on. Delimited by a slash character if there are more than one attribute. Parameter marked with member_path is legitimate for doing member operation. |
|
Add or delete a member under specified attribute path. When member_state is specified, the state option is ignored. Choices:
|
|
Indicates whether to create or remove the object. Choices:
|
|
Configure NP6 attributes. |
|
Enable/disable NP4 or NP6 offloading (also called fast path). Choices:
|
|
NP6 IPv4 anomaly protection. trap-to-host forwards anomaly sessions to the CPU. |
|
Invalid IPv4 ICMP checksum anomalies. Choices:
|
|
Layer 3 fragmented packets that could be part of layer 4 ICMP anomalies. Choices:
|
|
ICMP land anomalies. Choices:
|
|
Invalid IPv4 IP checksum anomalies. Choices:
|
|
Land anomalies. Choices:
|
|
Loose source record route option anomalies. Choices:
|
|
Record route option anomalies. Choices:
|
|
Security option anomalies. Choices:
|
|
Strict source record route option anomalies. Choices:
|
|
Stream option anomalies. Choices:
|
|
Timestamp option anomalies. Choices:
|
|
Invalid layer 4 protocol anomalies. Choices:
|
|
Unknown option anomalies. Choices:
|
|
Destination address as unspecified or loopback address anomalies. Choices:
|
|
Land anomalies. Choices:
|
|
End point identification anomalies. Choices:
|
|
Home address option anomalies. Choices:
|
|
Invalid option anomalies.Invalid option anomalies. Choices:
|
|
Jumbo options anomalies. Choices:
|
|
Network service access point address option anomalies. Choices:
|
|
Router alert option anomalies. Choices:
|
|
Tunnel encapsulation limit option anomalies. Choices:
|
|
Layer 4 invalid protocol anomalies. Choices:
|
|
Source address as multicast anomalies. Choices:
|
|
Unknown option anomalies. Choices:
|
|
Invalid IPv4 TCP checksum anomalies. Choices:
|
|
TCP SYN flood with FIN flag set without ACK setting anomalies. Choices:
|
|
TCP SYN flood with only FIN flag set anomalies. Choices:
|
|
TCP land anomalies. Choices:
|
|
TCP SYN flood with no flag set anomalies. Choices:
|
|
TCP SYN flood packets with data anomalies. Choices:
|
|
TCP SYN flood SYN/FIN flag set anomalies. Choices:
|
|
TCP WinNuke anomalies. Choices:
|
|
Invalid IPv4 UDP checksum anomalies. Choices:
|
|
UDP land anomalies. Choices:
|
|
Enable/disable garbage session collector. Choices:
|
|
HPE configuration. |
|
Maximum ARP packet rate (10K - 4G pps). |
|
Enable/Disable NPU host protection engine (HPE) shaper. Choices:
|
|
Maximum ESP packet rate (10K - 4G pps). |
|
Maximum ICMP packet rate (10K - 4G pps). |
|
Maximum fragmented IP packet rate (10K - 4G pps). |
|
Maximum IP packet rate for other packets (packet types that cannot be set with other options) (10G - 4G pps). |
|
Maximum L2 packet rate for L2 packets that are not ARP packets (10K - 4G pps). |
|
Maximum overflow rate of priority type traffic(10K - 4G pps). Includes L2: HA, 802.3ad LACP, heartbeats. L3: OSPF. L4_TCP: BGP. L4_UDP: IKE, SLBC, BFD. |
|
Maximum SCTP packet rate (10K - 4G pps). |
|
Maximum TCP packet rate (10K - 4G pps). |
|
Maximum TCP carries FIN or RST flags packet rate (1K - 1G pps). |
|
Maximum TCP carries SYN and ACK flags packet rate (1K - 1G pps). |
|
Maximum TCP SYN packet rate (10K - 4G pps). |
|
Maximum UDP packet rate (10K - 4G pps). |
|
Set hash function for IPSec outbound. Choices:
|
|
Enable/disable hash function for IPsec outbound traffic. Choices:
|
|
Enable/disable low latency mode. Choices:
|
|
Device Name. |
|
Enable/disable per-session accounting. Choices:
|
|
Set garbage session collection cleanup interval (1 - 100 sec). |
|
{disable | enable} Toggle between using fixed or random timeouts for refreshing NP6 sessions. Choices:
|
|
Set the fixed timeout for refreshing NP6 sessions (0 - 1000 sec). |
|
Set the random timeout range for refreshing NP6 sessions (0 - 1000 sec). |
|
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. Default: “root” |
Examples
- hosts: fortigates
collections:
- fortinet.fortios
connection: httpapi
vars:
vdom: "root"
ansible_httpapi_use_ssl: yes
ansible_httpapi_validate_certs: no
ansible_httpapi_port: 443
tasks:
- name: Configure NP6 attributes.
fortios_system_np6:
vdom: "{{ vdom }}"
state: "present"
access_token: "<your_own_value>"
system_np6:
fastpath: "disable"
fp_anomaly:
icmp_csum_err: "drop"
icmp_frag: "allow"
icmp_land: "allow"
ipv4_csum_err: "drop"
ipv4_land: "allow"
ipv4_optlsrr: "allow"
ipv4_optrr: "allow"
ipv4_optsecurity: "allow"
ipv4_optssrr: "allow"
ipv4_optstream: "allow"
ipv4_opttimestamp: "allow"
ipv4_proto_err: "allow"
ipv4_unknopt: "allow"
ipv6_daddr_err: "allow"
ipv6_land: "allow"
ipv6_optendpid: "allow"
ipv6_opthomeaddr: "allow"
ipv6_optinvld: "allow"
ipv6_optjumbo: "allow"
ipv6_optnsap: "allow"
ipv6_optralert: "allow"
ipv6_opttunnel: "allow"
ipv6_proto_err: "allow"
ipv6_saddr_err: "allow"
ipv6_unknopt: "allow"
tcp_csum_err: "drop"
tcp_fin_noack: "allow"
tcp_fin_only: "allow"
tcp_land: "allow"
tcp_no_flag: "allow"
tcp_syn_data: "allow"
tcp_syn_fin: "allow"
tcp_winnuke: "allow"
udp_csum_err: "drop"
udp_land: "allow"
garbage_session_collector: "disable"
hpe:
arp_max: "42"
enable_shaper: "disable"
esp_max: "44"
icmp_max: "45"
ip_frag_max: "46"
ip_others_max: "47"
l2_others_max: "48"
pri_type_max: "49"
sctp_max: "50"
tcp_max: "51"
tcpfin_rst_max: "52"
tcpsyn_ack_max: "53"
tcpsyn_max: "54"
udp_max: "55"
ipsec_ob_hash_function: "global-hash"
ipsec_outbound_hash: "disable"
low_latency_mode: "disable"
name: "default_name_59"
per_session_accounting: "disable"
session_collector_interval: "61"
session_timeout_fixed: "disable"
session_timeout_interval: "63"
session_timeout_random_range: "64"
Return Values
Common return values are documented here, the following are the fields unique to this module:
Key |
Description |
---|---|
Build number of the fortigate image Returned: always Sample: “1547” |
|
Last method used to provision the content into FortiGate Returned: always Sample: “PUT” |
|
Last result given by FortiGate on last operation applied Returned: always Sample: “200” |
|
Master key (id) used in the last call to FortiGate Returned: success Sample: “id” |
|
Name of the table used to fulfill the request Returned: always Sample: “urlfilter” |
|
Path of the table used to fulfill the request Returned: always Sample: “webfilter” |
|
Internal revision number Returned: always Sample: “17.0.2.10658” |
|
Serial number of the unit Returned: always Sample: “FGVMEVYYQT3AB5352” |
|
Indication of the operation’s result Returned: always Sample: “success” |
|
Virtual domain used Returned: always Sample: “root” |
|
Version of the FortiGate Returned: always Sample: “v5.6.3” |
Authors
Link Zheng (@chillancezen)
Jie Xue (@JieX19)
Hongbin Lu (@fgtdev-hblu)
Frank Shen (@frankshen01)
Miguel Angel Munoz (@mamunozgonzalez)
Nicolas Thomas (@thomnico)