fmgr_firewall_address – Configure IPv4 addresses.¶
New in version 2.10.
Synopsis¶
- This module is able to configure a FortiManager device by allowing the user to [add, get, set, update] the following FortiManager json-rpc urls.
- /pm/config/adom/{adom}/obj/firewall/address
- /pm/config/global/obj/firewall/address
- Examples include all parameters and values need to be adjusted to data sources before usage.
- Tested with FortiManager v6.0.0
Requirements¶
The below requirements are needed on the host that executes this module.
- ansible>=2.10.0
Parameters¶
- loose_validation - Do parameter validation in a loose way type: bool required: false default: false
- workspace_locking_adom - Acquire the workspace lock if FortiManager is running in workspace mode type: str required: false choices: global, custom dom
- workspace_locking_timeout - The maximum time in seconds to wait for other users to release workspace lock type: integer required: false default: 300
- url_params - parameters in url path type: dict required: true
- adom - the domain prefix type: str choices: none, global, custom dom
- parameters for method: [add, set, update] - Configure IPv4 addresses.
- data - No description for the parameter type: array
- allow-routing - Enable/disable use of this address in the static route configuration. type: str choices: [disable, enable]
- associated-interface - Network interface associated with address. type: str
- cache-ttl - Defines the minimal TTL of individual IP addresses in FQDN cache measured in seconds. type: int
- color - Color of icon on the GUI. type: int
- comment - No description for the parameter type: str
- country - IP addresses associated to a specific country. type: str
- dynamic_mapping - No description for the parameter type: array
- _scope - No description for the parameter type: array
- name - No description for the parameter type: str
- vdom - No description for the parameter type: str
- allow-routing - No description for the parameter type: str choices: [disable, enable]
- associated-interface - No description for the parameter type: str
- cache-ttl - No description for the parameter type: int
- color - No description for the parameter type: int
- comment - No description for the parameter type: str
- country - No description for the parameter type: str
- end-ip - No description for the parameter type: str
- end-mac - No description for the parameter type: str
- epg-name - No description for the parameter type: str
- filter - No description for the parameter type: str
- fqdn - No description for the parameter type: str
- interface - No description for the parameter type: str
- obj-id - No description for the parameter type: str
- organization - No description for the parameter type: str
- policy-group - No description for the parameter type: str
- sdn - No description for the parameter type: str choices: [aci, aws, nsx, nuage, azure, gcp, oci, openstack]
- sdn-addr-type - No description for the parameter type: str choices: [private, public, all]
- sdn-tag - No description for the parameter type: str
- start-ip - No description for the parameter type: str
- start-mac - No description for the parameter type: str
- subnet - No description for the parameter type: str
- subnet-name - No description for the parameter type: str
- tags - No description for the parameter type: str
- tenant - No description for the parameter type: str
- type - No description for the parameter type: str choices: [ipmask, iprange, fqdn, wildcard, geography, url, wildcard-fqdn, nsx, aws, dynamic, interface-subnet, mac]
- url - No description for the parameter type: str
- uuid - No description for the parameter type: str
- visibility - No description for the parameter type: str choices: [disable, enable]
- wildcard - No description for the parameter type: str
- wildcard-fqdn - No description for the parameter type: str
- _scope - No description for the parameter type: array
- end-ip - Final IP address (inclusive) in the range for the address. type: str
- epg-name - Endpoint group name. type: str
- filter - Match criteria filter. type: str
- fqdn - Fully Qualified Domain Name address. type: str
- list - No description for the parameter type: array
- ip - IP. type: str
- name - Address name. type: str
- obj-id - Object ID for NSX. type: str
- organization - Organization domain name (Syntax: organization/domain). type: str
- policy-group - Policy group name. type: str
- sdn - SDN. type: str choices: [aci, aws, nsx, nuage, azure, gcp, oci, openstack]
- sdn-tag - SDN Tag. type: str
- start-ip - First IP address (inclusive) in the range for the address. type: str
- subnet - IP address and subnet mask of address. type: str
- subnet-name - Subnet name. type: str
- tagging - No description for the parameter type: array
- category - Tag category. type: str
- name - Tagging entry name. type: str
- tags - No description for the parameter type: array
- {no-name} - No description for the parameter type: str
- tenant - Tenant. type: str
- type - Type of address. type: str choices: [ipmask, iprange, fqdn, wildcard, geography, url, wildcard-fqdn, nsx, aws, dynamic, interface-subnet, mac]
- uuid - Universally Unique Identifier (UUID; automatically assigned but can be manually reset). type: str
- visibility - Enable/disable address visibility in the GUI. type: str choices: [disable, enable]
- wildcard - IP address and wildcard netmask. type: str
- wildcard-fqdn - Fully Qualified Domain Name with wildcard characters. type: str
- parameters for method: [get] - Configure IPv4 addresses.
- attr - The name of the attribute to retrieve its datasource. type: str
- fields - No description for the parameter type: array
- {no-name} - No description for the parameter type: array
- {no-name} - No description for the parameter type: str choices: [allow-routing, associated-interface, cache-ttl, color, country, end-ip, epg-name, filter, fqdn, name, obj-id, organization, policy-group, sdn, sdn-tag, start-ip, subnet, subnet-name, tenant, type, uuid, visibility, wildcard, wildcard-fqdn]
- {no-name} - No description for the parameter type: array
- filter - No description for the parameter type: array
- {no-name} - No description for the parameter type: str
- get used - No description for the parameter type: int
- loadsub - Enable or disable the return of any sub-objects. type: int
- option - Set fetch option for the request. type: str choices: [count, object member, datasrc, get reserved, syntax]
- range - No description for the parameter type: array
- {no-name} - No description for the parameter type: int
- sortings - No description for the parameter type: array
- {attr_name} - No description for the parameter type: int choices: [1, -1]
Notes¶
Note
- The module may supports multiple method, every method has different parameters definition
- One method may also have more than one parameter definition collection, each collection is dedicated to one API endpoint
- The module may include domain dependent urls, the domain can be specified in url_params as adom
- To run in workspace mode, the paremeter workspace_locking_adom must be included in the task
Examples¶
- hosts: fortimanager-inventory
collections:
- fortinet.fortimanager
connection: httpapi
vars:
ansible_httpapi_use_ssl: True
ansible_httpapi_validate_certs: False
ansible_httpapi_port: 443
tasks:
- name: REQUESTING /PM/CONFIG/OBJ/FIREWALL/ADDRESS
fmgr_firewall_address:
loose_validation: False
workspace_locking_adom: <value in [global, custom adom]>
workspace_locking_timeout: 300
method: <value in [add, set, update]>
url_params:
adom: <value in [none, global, custom dom]>
params:
-
data:
-
allow-routing: <value in [disable, enable]>
associated-interface: <value of string>
cache-ttl: <value of integer>
color: <value of integer>
comment: <value of string>
country: <value of string>
dynamic_mapping:
-
_scope:
-
name: <value of string>
vdom: <value of string>
allow-routing: <value in [disable, enable]>
associated-interface: <value of string>
cache-ttl: <value of integer>
color: <value of integer>
comment: <value of string>
country: <value of string>
end-ip: <value of string>
end-mac: <value of string>
epg-name: <value of string>
filter: <value of string>
fqdn: <value of string>
interface: <value of string>
obj-id: <value of string>
organization: <value of string>
policy-group: <value of string>
sdn: <value in [aci, aws, nsx, ...]>
sdn-addr-type: <value in [private, public, all]>
sdn-tag: <value of string>
start-ip: <value of string>
start-mac: <value of string>
subnet: <value of string>
subnet-name: <value of string>
tags: <value of string>
tenant: <value of string>
type: <value in [ipmask, iprange, fqdn, ...]>
url: <value of string>
uuid: <value of string>
visibility: <value in [disable, enable]>
wildcard: <value of string>
wildcard-fqdn: <value of string>
end-ip: <value of string>
epg-name: <value of string>
filter: <value of string>
fqdn: <value of string>
list:
-
ip: <value of string>
name: <value of string>
obj-id: <value of string>
organization: <value of string>
policy-group: <value of string>
sdn: <value in [aci, aws, nsx, ...]>
sdn-tag: <value of string>
start-ip: <value of string>
subnet: <value of string>
subnet-name: <value of string>
tagging:
-
category: <value of string>
name: <value of string>
tags:
- <value of string>
tenant: <value of string>
type: <value in [ipmask, iprange, fqdn, ...]>
uuid: <value of string>
visibility: <value in [disable, enable]>
wildcard: <value of string>
wildcard-fqdn: <value of string>
- name: REQUESTING /PM/CONFIG/OBJ/FIREWALL/ADDRESS
fmgr_firewall_address:
loose_validation: False
workspace_locking_adom: <value in [global, custom adom]>
workspace_locking_timeout: 300
method: <value in [get]>
url_params:
adom: <value in [none, global, custom dom]>
params:
-
attr: <value of string>
fields:
-
- <value in [allow-routing, associated-interface, cache-ttl, ...]>
filter:
- <value of string>
get used: <value of integer>
loadsub: <value of integer>
option: <value in [count, object member, datasrc, ...]>
range:
- <value of integer>
sortings:
-
varidic.attr_name: <value in [1, -1]>
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:
- return values for method: [add, set, update]
- status
- No description for the parameter type: dict
- code - No description for the parameter type: int
- message - No description for the parameter type: str
- url - No description for the parameter type: str example: /pm/config/adom/{adom}/obj/firewall/address
- return values for method: [get]
- data
- No description for the parameter type: array
- allow-routing - Enable/disable use of this address in the static route configuration. type: str
- associated-interface - Network interface associated with address. type: str
- cache-ttl - Defines the minimal TTL of individual IP addresses in FQDN cache measured in seconds. type: int
- color - Color of icon on the GUI. type: int
- comment - No description for the parameter type: str
- country - IP addresses associated to a specific country. type: str
- dynamic_mapping - No description for the parameter type: array
- _scope - No description for the parameter type: array
- name - No description for the parameter type: str
- vdom - No description for the parameter type: str
- allow-routing - No description for the parameter type: str
- associated-interface - No description for the parameter type: str
- cache-ttl - No description for the parameter type: int
- color - No description for the parameter type: int
- comment - No description for the parameter type: str
- country - No description for the parameter type: str
- end-ip - No description for the parameter type: str
- end-mac - No description for the parameter type: str
- epg-name - No description for the parameter type: str
- filter - No description for the parameter type: str
- fqdn - No description for the parameter type: str
- interface - No description for the parameter type: str
- obj-id - No description for the parameter type: str
- organization - No description for the parameter type: str
- policy-group - No description for the parameter type: str
- sdn - No description for the parameter type: str
- sdn-addr-type - No description for the parameter type: str
- sdn-tag - No description for the parameter type: str
- start-ip - No description for the parameter type: str
- start-mac - No description for the parameter type: str
- subnet - No description for the parameter type: str
- subnet-name - No description for the parameter type: str
- tags - No description for the parameter type: str
- tenant - No description for the parameter type: str
- type - No description for the parameter type: str
- url - No description for the parameter type: str
- uuid - No description for the parameter type: str
- visibility - No description for the parameter type: str
- wildcard - No description for the parameter type: str
- wildcard-fqdn - No description for the parameter type: str
- _scope - No description for the parameter type: array
- end-ip - Final IP address (inclusive) in the range for the address. type: str
- epg-name - Endpoint group name. type: str
- filter - Match criteria filter. type: str
- fqdn - Fully Qualified Domain Name address. type: str
- list - No description for the parameter type: array
- ip - IP. type: str
- name - Address name. type: str
- obj-id - Object ID for NSX. type: str
- organization - Organization domain name (Syntax: organization/domain). type: str
- policy-group - Policy group name. type: str
- sdn - SDN. type: str
- sdn-tag - SDN Tag. type: str
- start-ip - First IP address (inclusive) in the range for the address. type: str
- subnet - IP address and subnet mask of address. type: str
- subnet-name - Subnet name. type: str
- tagging - No description for the parameter type: array
- category - Tag category. type: str
- name - Tagging entry name. type: str
- tags - No description for the parameter type: array
- {no-name} - No description for the parameter type: str
- tenant - Tenant. type: str
- type - Type of address. type: str
- uuid - Universally Unique Identifier (UUID; automatically assigned but can be manually reset). type: str
- visibility - Enable/disable address visibility in the GUI. type: str
- wildcard - IP address and wildcard netmask. type: str
- wildcard-fqdn - Fully Qualified Domain Name with wildcard characters. type: str
- status
- No description for the parameter type: dict
- code - No description for the parameter type: int
- message - No description for the parameter type: str
- url - No description for the parameter type: str example: /pm/config/adom/{adom}/obj/firewall/address