Anons79 Mini Shell

Directory : /lib/python2.7/site-packages/ansible/modules/network/f5/
Upload File :
Current File : //lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyo

�
�Udac@`s3ddlmZmZmZeZidd6dgd6dd6ZdZd	Zd
Z	ddl
mZddl
mZy�dd
l
mZddlmZddlmZddlmZddlmZddlmZddlmZddlmZddlmZddlmZddlmZddlmZddlmZddlmZWn�ek
rIdd
l mZddl!mZddl!mZddl!mZddl!mZddl!mZddl!mZddl!mZddl"mZddl"mZddl"mZddl#mZddl#mZddl#mZnXdefd��YZ$de$fd��YZ%de$fd ��YZ&d!e$fd"��YZ'd#e'fd$��YZ(d%e'fd&��YZ)d'e*fd(��YZ+d)e*fd*��YZ,d+e*fd,��YZ-d-�Z.e/d.kr/e.�nd/S(0i(tabsolute_importtdivisiontprint_functions1.1tmetadata_versiontpreviewtstatust	certifiedtsupported_bys

---
module: bigip_apm_network_access
short_description: Manage APM Network Access resource
description:
  - Manage APM Network Access resource.
version_added: 2.9
options:
  name:
    description:
      - Specifies the name of the APM network access to manage/create.
    type: str
    required: True
  description:
    description:
      - User created network access description.
    type: str
  ip_version:
    description:
      - Supported IP version on the network access resource.
    type: str
    choices:
      - ipv4
      - ipv4-ipv6
  allow_local_subnet:
    description:
      - Enables local subnet access and local access to any host or subnet in routes specified in the client routing
        table.
      - When C(yes) the system does not support integrated IP filtering.
    type: bool
  allow_local_dns:
    description:
      - Enables local access to DNS servers configured on client prior to establishing network access connection.
    type: bool
  split_tunnel:
    description:
      - Specifies that only the traffic targeted to a specified address space is sent over the network access tunnel.
    type: bool
  snat_pool:
    description:
      - Specifies the name of a SNAT pool used for implementing selective and intelligent SNATs.
      - When C(none) the system uses no SNAT pool for this network resource.
      - When C(automap) the system uses all of the self IP addresses as the translation addresses for the pool.
    type: str
  dtls:
    description:
      - When C(yes) the network access connection uses Datagram Transport Level Security instead of TCP,
        to provide better throughput for high demand applications like VoIP or streaming video.
    type: bool
  dtls_port:
    description:
      - Specifies the port number that the network access resource uses for secure UDP traffic with DTLS.
    type: int
  ipv4_lease_pool:
    description:
      - Specifies IPV4 lease pool resource to use with network access.
      - Referencing lease pool can be done in the full path format for example, C(/Common/pool_name).
      - When lease pool is referenced in full path format, the C(partition) parameter is ignored.
    type: str
  ipv6_lease_pool:
    description:
      - Specifies IPV6 lease pool resource to use with network access.
      - Referencing lease pool can be done in the full path format for example, C(/Common/pool_name).
      - When lease pool is referenced in full path format, the C(partition) parameter is ignored.
    type: str
  excluded_ipv6_adresses:
    description:
      - Specifies IPV6 address spaces for which traffic is not forced through the tunnel.
    type: list
    suboptions:
      subnet:
        description:
          - "The address of subnet in CIDR format, e.g. C(2001:db8:abcd:8000::/52)"
          - Host addresses can be specified without the CIDR mask notation.
        type: str
  excluded_ipv4_adresses:
    description:
      - Specifies IPV4 address spaces for which traffic is not forced through the tunnel.
    type: list
    suboptions:
      subnet:
        description:
          - "The address of subnet in CIDR format, e.g. C(192.168.1.0/24)"
          - Host addresses can be specified without the CIDR mask notation.
        type: str
  excluded_dns_addresses:
    description:
      - Specifies the DNS address spaces for which traffic is not forced through the tunnel.
    type: list
  dns_address_space:
    description:
      - Specifies a list of domain names describing the target LAN DNS addresses.
    type: list
  ipv4_address_space:
    description:
      - Specifies a list of IPv4 hosts or networks describing the target LAN.
      - This option is mandatory when creating a new resource and C(split_tunnel) is set to C(yes).
    type: list
    suboptions:
      subnet:
        description:
          - "The address of subnet in CIDR format, e.g. C(192.168.1.0/24)"
          - Host addresses can be specified without the CIDR mask notation.
        type: str
  ipv6_address_space:
    description:
      - Specifies a list of IPv6 hosts or networks describing the target LAN.
      - This option is mandatory when creating a new resource and C(split_tunnel) is set to C(yes).
    type: list
    suboptions:
      subnet:
        description:
          - "The address of subnet in CIDR format, e.g. C(2001:db8:abcd:8000::/52)"
          - Host addresses can be specified without the CIDR mask notation.
        type: str
  partition:
    description:
      - Device partition to manage resources on.
    type: str
    default: Common
  state:
    description:
      - When C(state) is C(present), ensures that the ACL exists.
      - When C(state) is C(absent), ensures that the ACL is removed.
    type: str
    choices:
      - present
      - absent
    default: present
extends_documentation_fragment: f5
author:
  - Wojciech Wypior (@wojtek0806)
s
- name: Create a split tunnel IPV4 Network Access
  bigip_apm_network_access:
    name: foobar
    ip_version: ipv4
    split_tunnel: yes
    snat_pool: "none"
    ipv4_lease_pool: leasefoo
    ipv4_address_space:
      - subnet: 10.10.1.1
      - subnet: 10.10.2.0/24
    excluded_ipv4_adresses:
      - subnet: 192.168.1.0/24
    provider:
      password: secret
      server: lb.mydomain.com
      user: admin
  delegate_to: localhost

- name: Modify a split tunnel IPV4 Network Access
  bigip_apm_network_access:
    name: foobar
    snat_pool: /Common/poolsnat
    ipv4_address_space:
      - subnet: 172.16.23.0/24
    excluded_ipv4_adresses:
      - subnet: 10.10.2.0/24
    allow_local_subnet: yes
    allow_local_dns: yes
    provider:
      password: secret
      server: lb.mydomain.com
      user: admin
  delegate_to: localhost

- name: Remove Network Access
  bigip_apm_network_access:
    name: foobar
    state: absent
    provider:
      password: secret
      server: lb.mydomain.com
      user: admin
  delegate_to: localhost
s�
description:
  description: The new description of Network Access.
  returned: changed
  type: str
  sample: My Access
ip_version:
  description: Supported IP version on the network access resource.
  returned: changed
  type: str
  sample: ipv4-ipv6
allow_local_subnet:
  description: Enables local subnet access.
  returned: changed
  type: bool
  sample: yes
allow_local_dns:
  description: Enables local access to DNS servers configured on client.
  returned: changed
  type: bool
  sample: yes
split_tunnel:
  description: Enables split tunnel on network access resource.
  returned: changed
  type: bool
  sample: yes
snat_pool:
  description: The name of a SNAT pool used by network access resource.
  returned: changed
  type: str
  sample: /Common/my-pool
dtls:
  description: Enables use of DTLS by network access.
  returned: changed
  type: bool
  sample: no
dtls_port:
  description: Specifies the port number that the network access resource uses for DTLS.
  returned: changed
  type: int
  sample: 4433
ipv4_lease_pool:
  description: Specifies IPV4 lease pool resource to use with network access.
  returned: changed
  type: str
  sample: /Common/leasepoolv4
ipv6_lease_pool:
  description: Specifies IPV6 lease pool resource to use with network access.
  returned: changed
  type: str
  sample: /Common/leasepoolv6
excluded_ipv6_adresses:
  description: Specifies IPV6 address spaces for which traffic is not forced through the tunnel.
  type: complex
  returned: changed
  contains:
    subnet:
      description: The host or network address.
      returned: changed
      type: str
      sample: "2001:DB8:ABCD:0012::0"
  sample: hash/dictionary of values
excluded_ipv4_adresses:
  description: Specifies IPV4 address spaces for which traffic is not forced through the tunnel.
  type: complex
  returned: changed
  contains:
    subnet:
      description: The host or network address.
      returned: changed
      type: str
      sample: 192.168.10.1
  sample: hash/dictionary of values
excluded_dns_addresses:
  description: Specifies the DNS address spaces for which traffic is not forced through the tunnel.
  returned: changed
  type: list
  sample: ['foobar.com', 'bazbar.org']
dns_address_space:
  description: Specifies a list of domain names describing the target LAN DNS addresses.
  returned: changed
  type: list
  sample: ['internal.net', '*.engnet.org']
ipv6_address_space:
  description: Specifies a list of IPv6 hosts or networks describing the target LAN.
  type: complex
  returned: changed
  contains:
    subnet:
      description: The host or network address.
      returned: changed
      type: str
      sample: "2001:DB8:ABCD:0012::0"
  sample: hash/dictionary of values
ipv4_address_space:
  description: Specifies a list of IPv4 hosts or networks describing the target LAN.
  type: complex
  returned: changed
  contains:
    subnet:
      description: The host or network address.
      returned: changed
      type: str
      sample: 192.168.10.1
  sample: hash/dictionary of values
(t
AnsibleModule(tenv_fallback(tF5RestClient(t
F5ModuleError(tAnsibleF5Parameters(tfq_name(ttransform_name(tf5_argument_spec(tflatten_boolean(t
is_empty_list(tcmp_str_with_none(tcmp_simple_list(tcompare_complex_list(t
ip_network(tis_valid_ip(tis_valid_ip_networkt
ParameterscB`seZidd6dd6dd6dd6dd	6d
d6dd
6dd6dd6dd6dd6dd6dd6dd6Zddddd	dd
ddddddddddgZddddddddd
dddddddgZddddddddd
dddddddgZRS(t
ip_versiontsupportedIpVersiontsplit_tunneltsplitTunnelingtallow_local_subnett addressSpaceLocalSubnetsExcludedtallow_local_dnst!addressSpaceLocDnsServersExcludedt	dtls_porttdtlsPorttipv4_lease_poolt
leasepoolNametipv6_lease_pooltipv6LeasepoolNametexcluded_ipv6_adressestipv6AddressSpaceExcludeSubnettexcluded_ipv4_adressestaddressSpaceExcludeSubnettexcluded_dns_addressestaddressSpaceExcludeDnsNametdns_address_spacetaddressSpaceIncludeDnsNametipv4_address_spacetaddressSpaceIncludeSubnettipv6_address_spacetipv6AddressSpaceIncludeSubnett	snat_pooltsnatpooltsnattdtlstdescription(t__name__t
__module__tapi_maptapi_attributestreturnablest
updatables(((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyRQs�
		t
ApiParameterscB`seZed��ZRS(cC`sS|jddkr*|jddkr*dS|jddkrH|jdS|jdS(NR5R3tautomaptnone(R?R@(t_valuestNone(tself((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyR3�s
&(R8R9tpropertyR3(((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyR>�stModuleParameterscB`seZd�Zd�Zd�Zed��Zed��Zed��Zed��Z	ed��Z
ed��Zed	��Zed
��Z
ed��Zed��Zed
��Zed��Zed��Zed��Zed��ZRS(cC`s0t|�}|dkrdS|dkr,dSdS(Ntyesttruetnotfalse(RRB(RCtitemtresult((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyt_handle_booleans�scC`stdj|��}|jS(Nu{0}(Rtformattwith_prefixlen(RCRJtip((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyt_convert_address�scC`sHg}x;|D]3}t�}|j|d�|d<|j|�q
W|S(Ntsubnet(tdictRPtappend(RCtitemsRKtxt	to_change((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyt_format_subnets�s
	cC`s9|jddkrdS|jddkr.dS|jdS(NR7R@t(snoneRX(RARB(RC((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyR7�s
cC`s|j|jd�S(NR(RLRA(RC((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyR�scC`s|j|jd�S(NR(RLRA(RC((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyR�scC`s|j|jd�S(NR(RLRA(RC((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyR�scC`s|j|jd�S(NR6(RLRA(RC((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyR6�scC`sT|jddkrdSd|jdko5dknrItd��n|jdS(NR!ii��sRSpecified port number is out of valid range, correct range is between 0 and 65535.(RARBR(RC((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyR!�s#cC`sE|jddkrdS|jddkr.dSt|j|jd�S(NR#R@RX(snoneRX(RARBR
t	partition(RC((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyR#�s
cC`sE|jddkrdS|jddkr.dSt|j|jd�S(NR%R@RX(snoneRX(RARBR
RY(RC((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyR%�s
cC`sH|jddkrdSt|jd�r.gS|j|jd�}|S(NR'(RARBRRW(RCRK((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyR'�scC`sH|jddkrdSt|jd�r.gS|j|jd�}|S(NR)(RARBRRW(RCRK((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyR)�scC`sH|jddkrdSt|jd�r.gS|j|jd�}|S(NR/(RARBRRW(RCRK((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyR/scC`sH|jddkrdSt|jd�r.gS|j|jd�}|S(NR1(RARBRRW(RCRK((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyR1
scC`s9|jddkrdSt|jd�r.gS|jdS(NR-(RARBR(RC((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyR-s
cC`s9|jddkrdSt|jd�r.gS|jdS(NR+(RARBR(RC((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyR+s
cC`sR|jddkrdS|jddkr5|jdSt|j|jd�}|S(NR3R?R@(sautomapsnone(RARBR
RY(RCRK((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyR3#s(R8R9RLRPRWRDR7RRRR6R!R#R%R'R)R/R1R-R+R3(((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyRE�s$			
				tChangescB`seZd�ZRS(cC`sXi}y:x$|jD]}t||�||<qW|j|�}Wntk
rSnX|S(N(R<tgetattrt_filter_paramst	Exception(RCRKt
returnable((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyt	to_return.s
(R8R9R_(((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyRZ-st
UsableChangescB`s&eZed��Zed��ZRS(cC`s9|jddkrdS|jddkr5|jdSdS(NR3R?R@(sautomapsnone(RARB(RC((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyR5:scC`s"|jddkrdS|jdS(NR3R?R@(Nsautomapsnone(RARB(RC((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyR3As(R8R9RDR5R3(((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyR`9stReportableChangescB`s�eZd�Zd�Zed��Zed��Zed��Zed��Zed��Z	ed��Z
ed��Zed	��ZRS(
cC`s?tdj|��}|jdkr;|jd�d}|S|S(Nu{0}i i�t/i(i i�(RRMt	prefixlentsplit(RCRJRORK((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyt_parse_hostsIs
cC`sHg}x;|D]3}t�}|j|d�|d<|j|�q
W|S(NRQ(RRReRS(RCRTRKRURV((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyRWPs
	cC`st|jd�S(NR(RRA(RC((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyRXscC`st|jd�S(NR(RRA(RC((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyR\scC`st|jd�S(NR(RRA(RC((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyR`scC`st|jd�S(NR6(RRA(RC((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyR6dscC`sB|jddkrdS|jds(gS|j|jd�}|S(NR)(RARBRW(RCRK((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyR)hs
cC`sB|jddkrdS|jds(gS|j|jd�}|S(NR'(RARBRW(RCRK((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyR'qs
cC`sB|jddkrdS|jds(gS|j|jd�}|S(NR/(RARBRW(RCRK((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyR/zs
cC`sB|jddkrdS|jds(gS|j|jd�}|S(NR1(RARBRW(RCRK((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyR1�s
(
R8R9ReRWRDRRRR6R)R'R/R1(((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyRaHs					t
DifferencecB`s�eZdd�Zd�Zd�Zed��Zed��Zed��Z	ed��Z
ed��Zed��Zed	��Z
ed
��Zed��ZRS(
cC`s||_||_dS(N(twantthave(RCRgRh((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyt__init__�s	cC`s9yt||�}|SWntk
r4|j|�SXdS(N(R[tAttributeErrort_Difference__default(RCtparamRK((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pytcompare�s

cC`sQt|j|�}y&t|j|�}||kr7|SWntk
rL|SXdS(N(R[RgRhRj(RCRltattr1tattr2((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyt	__default�s
cC`st|jj|jj�}|S(N(RRgR7Rh(RCRK((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyR7�scC`st|jj|jj�}|S(N(RRgR#Rh(RCRK((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyR#�scC`st|jj|jj�}|S(N(RRgR%Rh(RCRK((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyR%�scC`st|jj|jj�}|S(N(RRgR+Rh(RCRK((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyR+�scC`st|jj|jj�}|S(N(RRgR-Rh(RCRK((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyR-�scC`st|jj|jj�}|S(N(RRgR)Rh(RCRK((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyR)�scC`st|jj|jj�}|S(N(RRgR'Rh(RCRK((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyR'�scC`st|jj|jj�}|S(N(RRgR/Rh(RCRK((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyR/�scC`st|jj|jj�}|S(N(RRgR1Rh(RCRK((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyR1�sN(R8R9RBRiRmRkRDR7R#R%R+R-R)R'R/R1(((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyRf�s			t
ModuleManagercB`s�eZd�Zd�Zd�Zd�Zd�Zd�Zd�Zd�Z	d�Z
d	�Zd
�Zd�Z
d�Zd
�Zd�Zd�Zd�ZRS(cO`s^|jdd�|_t|jj�|_td|jj�|_t�|_	t
�|_dS(Ntmoduletparams(tgetRBRrR
RstclientRERgR>RhR`tchanges(RCtargstkwargs((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyRi�s
cC`sji}xBtjD]7}t|j|�dk	rt|j|�||<qqW|rftd|�|_ndS(NRs(RR<R[RgRBR`Rv(RCtchangedtkey((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyt_set_changed_options�scC`s�t|j|j�}tj}t�}xX|D]P}|j|�}|dkrUq.q.t|t�rt|j	|�q.|||<q.W|r�t
d|�|_tSt
S(NRs(RfRgRhRR=RRRmRBt
isinstancetupdateR`RvtTruetFalse(RCtdiffR=Rytktchange((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyt_update_changed_options�s		
cC`sK|jdg�}x2|D]*}|jjjd|dd|d�qWdS(Nt
__warningstmsgtversion(tpopRuRrt	deprecate(RCRKtwarningstwarning((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyt_announce_deprecations�s


cC`s�t}t�}|jj}|dkr6|j�}n|dkrQ|j�}ntd|jj��}|j�}|j	|�|j	td|��|j
|�|S(NtpresenttabsentRsRy(RRRRgtstateR�R�RaRvR_R}R�(RCRyRKR�t
reportableRv((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pytexec_module�s	

cC`s$|j�r|j�S|j�SdS(N(texistsR}tcreate(RC((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyR�s
cC`s|j�r|j�StS(N(R�tremoveR(RC((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyR�s
cC`s|j�}|rtStS(N(R�R~R(RCRK((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyt
should_updatescC`sG|j�|_|j�|j�s)tS|jjr9tS|j�tS(N(	tread_current_from_deviceRhtcheck_required_paramsR�RRrt
check_modeR~tupdate_on_device(RC((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyR}s

cC`s9|jjrtS|j�|j�r5td��ntS(NsFailed to delete the resource.(RrR�R~tremove_from_deviceR�R(RC((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyR�&s
cC`s2|j�|j�|jjr$tS|j�tS(N(R{R�RrR�R~tcreate_on_device(RC((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyR�.s


cC`s�|jjdkr�|jjdkr]|jjdggkr]tdj|jj���q]n|jjdkr�|jjdggkr�tdj|jj���n|jjdggkr�tdj|jj���q�q�n|jjdkr�|jjdkrE|jjdk	rE|jjrEtdj|jj���qEn|jjdkr�|jjdk	r�|jjr�tdj|jj���n|jjdk	r�|jjr�tdj|jj���q�q�ndS(NRGtipv4sGThe ipv4_address_space cannot be empty, when split_tunnel is set to {0}s	ipv4-ipv6sGThe ipv6_address_space cannot be empty, when split_tunnel is set to {0}sDCannot remove ipv4_address_space when split_tunnel on device is: {0}sDCannot remove ipv6_address_space when split_tunnel on device is: {0}(	RgRRR/RBRRMR1Rh(RC((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyR�6s<cC`s�dj|jjd|jjdt|jj|jj��}|jjj|�}y|j	�}Wnt
k
rwtSX|jdks�d|kr�|ddkr�tSt
S(Ns7https://{0}:{1}/mgmt/tm/apm/resource/network-access/{2}tservertserver_porti�tcode(RMRutproviderRRgRYtnametapiRttjsont
ValueErrorRRR~(RCturitresptresponse((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyR�bs


+cC`s�|jj�}|jj|d<|jj|d<dj|jjd|jjd�}|jjj	|d|�}y|j
�}Wn%tk
r�}tt
|���nXd|kr�|ddkr�d
|kr�t|d
��q�t|j��ntS(NR�RYs4https://{0}:{1}/mgmt/tm/apm/resource/network-access/R�R�R�R�i�i�tmessage(i�i�(Rvt
api_paramsRgR�RYRMRuR�R�tpostR�R�RtstrtcontentR~(RCRsR�R�R�tex((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyR�qs 
cC`s�|jj�}dj|jjd|jjdt|jj|jj��}|jj	j
|d|�}y|j�}Wn%tk
r�}t
t|���nXd|kr�|ddkr�d|kr�t
|d��q�t
|j��ndS(Ns7https://{0}:{1}/mgmt/tm/apm/resource/network-access/{2}R�R�R�R�i�R�(RvR�RMRuR�RRgRYR�R�tpatchR�R�RR�R�(RCRsR�R�R�R�((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyR��s

cC`sydj|jjd|jjdt|jj|jj��}|jjj|�}|j	dkrft
St|j��dS(Ns7https://{0}:{1}/mgmt/tm/apm/resource/network-access/{2}R�R�i�(
RMRuR�RRgRYR�R�tdeleteRR~RR�(RCR�R�((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyR��s

cC`s�dj|jjd|jjdt|jj|jj��}|jjj|�}y|j	�}Wn%t
k
r�}tt|���nXd|kr�|ddkr�d|kr�t|d��q�t|j
��ntd|�S(Ns7https://{0}:{1}/mgmt/tm/apm/resource/network-access/{2}R�R�R�i�R�Rs(RMRuR�RRgRYR�R�RtR�R�RR�R�R>(RCR�R�R�R�((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyR��s

(R8R9RiR{R�R�R�R�R�R�R}R�R�R�R�R�R�R�R�(((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyRq�s"									
			,				tArgumentSpeccB`seZd�ZRS(c,C`s�t|_tdtdt�dtdddg�dtdd	�d
tdd	�dtdd	�dt�d
t�dtdd	�dtdd�dt�dt�dtdddtdt���dtdddtdt���dtdd�dtdd�dtdddtdt���dtdddtdt���dtdddtd gf�d!tdd"dd"d#g��}i|_|jjt�|jj|�dS($NR�trequiredRtchoicesR�s	ipv4-ipv6RttypetboolRRR3R7R6R!tintR#R%R'tlisttoptionsRQR)R+R-R/R1RYtdefaulttCommontfallbacktF5_PARTITIONR�R�R�(R~tsupports_check_modeRRR	t
argument_specR}R(RCR�((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyRi�sX									(R8R9Ri(((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyR��scC`s�t�}td|jd|j�}y,td|�}|j�}|j|�Wn)tk
r{}|jdt	|��nXdS(NR�R�RrR�(
R�RR�R�RqR�t	exit_jsonRt	fail_jsonR�(tspecRrtmmtresultsR�((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pytmain�s		t__main__N(0t
__future__RRRR�t
__metaclass__tANSIBLE_METADATAt
DOCUMENTATIONtEXAMPLEStRETURNtansible.module_utils.basicRR	t%library.module_utils.network.f5.bigipR
t&library.module_utils.network.f5.commonRRR
RRRRt'library.module_utils.network.f5.compareRRRt)library.module_utils.network.f5.ipaddressRRRtImportErrort%ansible.module_utils.network.f5.bigipt&ansible.module_utils.network.f5.commont'ansible.module_utils.network.f5.comparet)ansible.module_utils.network.f5.ipaddressRR>RERZR`RatobjectRfRqR�R�R8(((sW/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_apm_network_access.pyt<module>sf


�.k
M
�EC�?	

Anons79 File Manager Version 1.0, Coded By Anons79
Email: [email protected]