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_firewall_address_list.pyo

�
�Udac@`s�ddlmZmZmZeZidd6dgd6dd6ZdZd	Zd
Z	ddl
Z
ddlmZdd
lm
Z
y�ddlmZddlmZddlmZddlmZddlmZddlmZddlmZddlmZddlmZddlmZWn�ek
r�ddlmZddlmZddlmZddlmZddlmZddlmZddlmZddlmZddl mZddl mZnXdefd��YZ!de!fd��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*�Z+e,d+kr�e+�ndS(,i(tabsolute_importtdivisiontprint_functions1.1tmetadata_versiontpreviewtstatust	certifiedtsupported_bys�
---
module: bigip_firewall_address_list
short_description: Manage address lists on BIG-IP AFM
description:
  - Manages the AFM address lists on a BIG-IP. This module can be used to add
    and remove address list entries.
version_added: 2.5
options:
  name:
    description:
      - Specifies the name of the address list.
    type: str
    required: True
  partition:
    description:
      - Device partition to manage resources on.
    type: str
    default: Common
  description:
    description:
      - Description of the address list
    type: str
  geo_locations:
    description:
      - List of geolocations specified by their C(country) and C(region).
    suboptions:
      country:
        description:
          - The country name, or code, of the geolocation to use.
          - In addition to the country full names, you may also specify their abbreviated
            form, such as C(US) instead of C(United States).
          - Valid country codes can be found here https://countrycode.org/.
        type: str
        required: True
        choices:
          - Any valid 2 character ISO country code.
          - Any valid country name.
      region:
        description:
          - Region name of the country to use.
        type: str
    type: list
  addresses:
    description:
      - Individual addresses that you want to add to the list. These addresses differ
        from ranges, and lists of lists such as what can be used in C(address_ranges)
        and C(address_lists) respectively.
      - This list can also include networks that have CIDR notation.
    type: list
  address_ranges:
    description:
      - A list of address ranges where the range starts with a port number, is followed
        by a dash (-) and then a second number.
      - If the first address is greater than the second number, the numbers will be
        reversed so-as to be properly formatted. ie, C(2.2.2.2-1.1.1). would become
        C(1.1.1.1-2.2.2.2).
    type: list
  address_lists:
    description:
      - Simple list of existing address lists to add to this list. Address lists can be
        specified in either their fully qualified name (/Common/foo) or their short
        name (foo). If a short name is used, the C(partition) argument will automatically
        be prepended to the short name.
    type: list
  fqdns:
    description:
      - A list of fully qualified domain names (FQDNs).
      - An FQDN has at least one decimal point in it, separating the host from the domain.
      - To add FQDNs to a list requires that a global FQDN resolver be configured.
        At the moment, this must either be done via C(bigip_command), or, in the GUI
        of BIG-IP. If using C(bigip_command), this can be done with C(tmsh modify security
        firewall global-fqdn-policy FOO) where C(FOO) is a DNS resolver configured
        at C(tmsh create net dns-resolver FOO).
    type: list
  state:
    description:
      - When C(present), ensures that the address list and entries exists.
      - When C(absent), ensures the address list is removed.
    type: str
    choices:
      - present
      - absent
    default: present
extends_documentation_fragment: f5
author:
  - Tim Rupp (@caphrim007)
  - Wojciech Wypior (@wojtek0806)
s�
- name: Create an address list
  bigip_firewall_address_list:
    name: foo
    addresses:
      - 3.3.3.3
      - 4.4.4.4
      - 5.5.5.5
    provider:
      password: secret
      server: lb.mydomain.com
      user: admin
  delegate_to: localhost
sj
description:
  description: The new description of the address list.
  returned: changed
  type: str
  sample: My address list
addresses:
  description: The new list of addresses applied to the address list.
  returned: changed
  type: list
  sample: [1.1.1.1, 2.2.2.2]
address_ranges:
  description: The new list of address ranges applied to the address list.
  returned: changed
  type: list
  sample: [1.1.1.1-2.2.2.2, 3.3.3.3-4.4.4.4]
address_lists:
  description: The new list of address list names applied to the address list.
  returned: changed
  type: list
  sample: [/Common/list1, /Common/list2]
fqdns:
  description: The new list of FQDN names applied to the address list.
  returned: changed
  type: list
  sample: [google.com, mit.edu]
geo_locations:
  description: The new list of geo locations applied to the address list.
  returned: changed
  type: complex
  contains:
    country:
      description: Country of the geo location.
      returned: changed
      type: str
      sample: US
    region:
      description: Region of the geo location.
      returned: changed
      type: str
      sample: California
N(t
AnsibleModule(tenv_fallback(tF5RestClient(t
F5ModuleError(tAnsibleF5Parameters(tfq_name(tf5_argument_spec(ttransform_name(t
ip_address(tip_interface(tis_valid_ip(tis_valid_ip_interfacet
ParameterscB`saeZidd6dd6ZdddddgZddddddgZddddddgZRS(t
address_liststaddressListst
geo_locationstgeot	addressestdescriptiontfqdnstaddress_ranges(t__name__t
__module__tapi_maptapi_attributestreturnablest
updatables(((sZ/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_firewall_address_list.pyR�s(
		t
ApiParameterscB`sSeZed��Zed��Zed��Zed��Zed��ZRS(cC`sr|jddkrdSg}xB|jdD]3}d|dkrGq+n|j|dj��q+Wt|�}|S(NRt-tname(t_valuestNonetappendtstriptsorted(tselftresultt
address_range((sZ/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_firewall_address_list.pyR�scC`sl|jddkrdSg}x<|jdD]-}dj|d|d�}|j|�q+Wt|�}|S(NRs/{0}/{1}t	partitionR%(R&R'tformatR(R*(R+R,txtitem((sZ/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_firewall_address_list.pyR�scC`s[|jddkrdSg|jdD] }d|dkr%|d^q%}t|�}|S(NRR$R%(R&R'R*(R+R0R,((sZ/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_firewall_address_list.pyR�s
4cC`sQ|jddkrdSg|jdD]}t|d�^q%}t|�}|S(NRR%(R&R'tstrR*(R+R0R,((sZ/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_firewall_address_list.pyRs
*cC`sQ|jddkrdSg|jdD]}t|d�^q%}t|�}|S(NRR%(R&R'R2R*(R+R0R,((sZ/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_firewall_address_list.pyR	s
*(RRtpropertyRRRRR(((sZ/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_firewall_address_list.pyR#�s
tModuleParameterscB`sheZdd�Zd�Zed��Zed��Zed��Zed��Z	ed��Z
RS(cC`s_tt|�jd|�i�dd6dd6dd6dd	6d
d6dd
6dd6dd6dd6dd6dd6dd6dd6dd6dd6d d!6d"d#6d$d%6d&d'6d(d)6d*d+6d,d-6d.d/6d0d16d2d36d4d56d6d76d8d96d:d;6d<d=6d>d?6d@dA6dBdC6dDdE6dFdG6dHdI6dJdK6dLdM6dNdO6dPdQ6dRdS6dTdU6dVdW6dXdY6dZd[6d\d]6d^d_6d`da6dbdc6ddde6dfdg6dhdi6djdk6dldm6dndo6dpdq6drds6dtdu6dvdw6dxdy6dzd{6d|d}6d~d6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6dd6dd6dd6dd6dd	6d
d6dd
6dd6dd6dd6dd6dd6dd6dd6dd6dd6d d!6d"d#6d$d%6d&d'6d(d)6d*d+6d,d-6d.d/6d0d16d2d36d4d56d6d76d8d96d:d;6d<d=6d>d?6d@dA6dBdC6dDdE6dFdG6dHdI6dJdK6dLdM6dNdO6dPdQ6dRdS6dTdU6dVdW6dXdY6dZd[6d\d]6d^d_6d`da6dbdc6ddde6dfdg6dhdi6djdk6dldm6dndo6dpdq6drds6dtdu6dvdw6dxdy6dzd{6d|d}6d~d6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6d�d�6|_|jj�|_dS(�NtparamstAFtAfghanistantALtAlbaniatDZtAlgeriatASsAmerican SamoatADtAndorratAOtAngolatAItAnguillatAQt
AntarcticatAGsAntigua and BarbudatARt	ArgentinatAMtArmeniatAWtArubatAUt	AustraliatATtAustriatAZt
AzerbaijantBStBahamastBHtBahraintBDt
BangladeshtBBtBarbadostBYtBelarustBEtBelgiumtBZtBelizetBJtBenintBMtBermudatBTtBhutantBOtBoliviatBAsBosnia and HerzegovinatBWtBotswanatBRtBraziltBNtBruneitBGtBulgariatBFsBurkina FasotBItBurunditCMtCameroontCAtCanadatCVs
Cape VerdetCFsCentral African RepublictCLtChiletCNtChinatCXsChristmas IslandtCCs
Cocos IslandstCOtColombiatCKsCook IslandstCRs
Costa RicatCUtCubatCWtCuracaotCYtCyprustCZsCzech RepublictCDs Democratic Republic of the CongotDKtDenmarktDJtDjiboutitDMtDominicatDOsDominican RepublictECtEcuadortEGtEgypttERtEritreatEEtEstoniatETtEthiopiatFKsFalkland IslandstFOs
Faroe IslandstFJtFijitFItFinlandtFRtFrancetPFsFrench PolynesiatGAtGabontGMtGambiatGEtGeorgiatDEtGermanytGHtGhanatGIt
GilbraltartGRtGreecetGLt	GreenlandtGDtGrenadatGUtGuamtGTt	GuatemalatGGtGuernseytGNtGuineatGWs
Guinea-BissautGYtGuyanatHTtHaititHNtHondurastHKs	Hong KongtHUtHungarytIStIcelandtINtIndiatIDt	IndonesiatIRtIrantIQtIraqtIEtIrelandtIMsIsle of MantILtIsraeltITtItalytCIsIvory CoasttJMtJamaicatJPtJapantJEtJerseytJOtJordantKZt
KazakhstantLAtLaostLVtLatviatLBtLebanontLStLesothotLRtLiberiatLYtLibyatLIt
LiechtensteintLTt	LithuaniatLUt
LuxembourgtMOtMacautMKt	MacedoniatMGt
MadagascartMWtMalawitMYtMalaysiatMVtMaldivestMLtMalitMTtMaltatMHsMarshall IslandstMRt
MauritaniatMUt	MauritiustYTtMayottetMXtMexicotFMt
MicronesiatMDtMoldovatMCtMonacotMNtMongoliatMEt
MontenegrotMSt
MontserrattMAtMoroccotMZt
MozambiquetMMtMyanmartNAtNamibiatNRtNaurutNPtNepaltNLtNetherlandstANsNetherlands AntillestNCs
New CaledoniatNZsNew ZealandtNIt	NicaraguatNEtNigertNGtNigeriatNUtNiuetKPsNorth KoreatMPsNorthern Mariana IslandstNOtNorwaytOMtOmantPKtPakistantPWtPalautPSt	PalestinetPAtPanamatPGsPapua New GuineatPYtParaguaytPEtPerutPHtPhilippinestPNtPitcairntPLtPolandtPTtPortugaltPRsPuerto RicotQAtQatartCGsRepublic of the CongotREtReuniontROtRomaniatRUtRussiatRWtRwandatBLsSaint BarthelemytSHsSaint HelenatKNsSaint Kitts and NevistLCsSaint LuciatMFsSaint MartintPMsSaint Pierre and MiquelontVCs Saint Vincent and the GrenadinestWStSamoatSMs
San MarinotSTsSao Tome and PrincipetSAsSaudi ArabiatSNtSenegaltRStSerbiatSCt
SeychellestSLsSierra LeonetSGt	SingaporetSXsSint MaartentSKtSlovakiatSItSloveniatSBsSolomon IslandstSOtSomaliatZAsSouth AfricatKRsSouth KoreatSSsSouth SudantEStSpaintLKs	Sri LankatSDtSudantSRtSurinametSJsSvalbard and Jan MayentSZt	SwazilandtSEtSwedentCHtSwitzerlandtSYtSyriatTWtTaiwantTJt	TajikstantTZtTanzaniatTHtThailandtTGtTogotTKtTokelautTOtTongatTTsTrinidad and TobagotTNtTunisiatTRtTurkeytTMtTurkmenistantTCsTurks and Caicos IslandstTVtTuvalutVIsU.S. Virgin IslandstUGtUgandatUAtUkrainetAEsUnited Arab EmiratestGBsUnited KingdomtUSs
United StatestUYtUruguaytUZt
UzbekistantVUtVanuatutVAtVaticantVEt	VenezuelatVNtVietnamtWFsWallis and FutunatEHsWestern SaharatYEtYementZMtZambiatZWtZimbabwe(tsuperR4t__init__tcountry_iso_maptvaluestchoices_iso_codes(R+R5((sZ/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_firewall_address_list.pyR�s�
c`s]t|�dkrtS|jd�}tjdtj��t�fd�|jd�D��S(sZReasonable attempt at validating a hostname

        Compiled from various paragraphs outlined here
        https://tools.ietf.org/html/rfc3696#section-2
        https://tools.ietf.org/html/rfc1123

        Notably,
        * Host software MUST handle host names of up to 63 characters and
          SHOULD handle host names of up to 255 characters.
        * The "LDH rule", after the characters that it permits. (letters, digits, hyphen)
        * If the hyphen is used, it is not permitted to appear at
          either the beginning or end of a label

        :param host:
        :return:
        i�t.s(?!-)[A-Z0-9-]{1,63}(?<!-)$c3`s|]}�j|�VqdS(N(tmatch(t.0R0(tallowed(sZ/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_firewall_address_list.pys	<genexpr>s(tlentFalsetrstriptretcompilet
IGNORECASEtalltsplit(R+thost((R�sZ/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_firewall_address_list.pytis_valid_hostname�s
cC`s�|jddkrdSg}x�|jdD]}}t|�rb|jttdj|����q+t|�r�|jttdj|����q+t	dj|���q+Wt
|�}|S(NRu{0}s>Address {0} must be either an IPv4 or IPv6 address or network.(R&R'RR(R2RR/RRRR*(R+R,R0((sZ/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_firewall_address_list.pyRs%%cC`s|jddkrdSg}x�|jdD]�}|jd�\}}|j�}|j�}tdj|��}tdj|��}|j|jkr�td��nt|�t|�kr�||}}ndjt	|�t	|��}|j
|�q+Wt|�}|S(NRR$u{0}sMWhen specifying a range, IP addresses must be of the same type; IPv4 or IPv6.s{0}-{1}(R&R'R�R)RR/tversionRtintR2R(R*(R+R,R-tstarttstopR1((sZ/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_firewall_address_list.pyR"s$cC`sd|jddkrdSg}x4|jdD]%}t|j|�}|j|�q+Wt|�}|S(NR(R&R'R
R.R(R*(R+R,R0R1((sZ/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_firewall_address_list.pyR9scC`sy|jddkrdSg}xI|jdD]:}|j|�rP|j|�q+tdj|���q+Wt|�}|S(NRs!The hostname '{0}' looks invalid.(R&R'R�R(RR/R*(R+R,R0((sZ/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_firewall_address_list.pyRDscC`s�|jddkrdSg}xo|jdD]`}|ddk	rt|dj�dkrtdj|d|d�}n
|d}|j|�q+Wt|�}|S(NRtregionts{0}:{1}tcountry(R&R'R)R/R(R*(R+R,R0ttmp((sZ/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_firewall_address_list.pyRSs&
N(RRR'R�R�R3RRRRR(((sZ/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_firewall_address_list.pyR4s�	tChangescB`seZd�ZRS(cC`sXi}y:x$|jD]}t||�||<qW|j|�}Wntk
rSnX|S(N(R!tgetattrt_filter_paramst	Exception(R+R,t
returnable((sZ/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_firewall_address_list.pyt	to_returncs
(RRR�(((sZ/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_firewall_address_list.pyR�bstReportableChangescB`s5eZed��Zed��Zed��ZRS(cC`sIg}x<|jdD]-}d|dkr0qn|j|d�qW|S(NRR$R%(R&R((R+R,R1((sZ/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_firewall_address_list.pyRoscC`sg}x�|jdD]�}d|dkr0qn|djd�\}}|j�}|j�}tdj|��}tdj|��}|j|jkr�td��nt|�t|�kr�||}}ndjt|�t|��}|j	|�qWt
|�}|S(NRR$R%u{0}sMWhen specifying a range, IP addresses must be of the same type; IPv4 or IPv6.s{0}-{1}(R&R�R)RR/R�RR�R2R(R*(R+R,R1R�R�((sZ/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_firewall_address_list.pyRxs$cC`sUg}x<|jdD]-}dj|d|d�}|j|�qWt|�}|S(NRs/{0}/{1}R.R%(R&R/R(R*(R+R,R0R1((sZ/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_firewall_address_list.pyR�s(RRR3RRR(((sZ/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_firewall_address_list.pyR�ns	t
UsableChangescB`s&eZed��Zed��ZRS(cC`s�|jddkr*|jddkr*dSg}|jdrs|g|jdD]}tdt|��^qN7}n|jdr�|g|jdD]}tdt|��^q�7}n|S(NRRR%(R&R'tdictR2(R+R,R0((sZ/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_firewall_address_list.pyR�s&
6
6cC`sn|jddkrdSg}xJ|jdD];}|jd�d\}}|jtd|d|��q+W|S(NRt/iR%R.(R&R'R�R(R�(R+R,R0R.R%((sZ/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_firewall_address_list.pyR�s(RRR3RR(((sZ/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_firewall_address_list.pyR��st
DifferencecB`sbeZdd�Zd�Zd�Zed��Zed��Zed��Z	ed��Z
RS(cC`s||_||_dS(N(twantthave(R+R�R�((sZ/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_firewall_address_list.pyR��s	cC`s9yt||�}|SWntk
r4|j|�SXdS(N(R�tAttributeErrort_Difference__default(R+tparamR,((sZ/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_firewall_address_list.pytcompare�s

cC`sQt|j|�}y&t|j|�}||kr7|SWntk
rL|SXdS(N(R�R�R�R�(R+R�tattr1tattr2((sZ/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_firewall_address_list.pyt	__default�s
cC`sd|jjdkrdS|jjdkr2|jjSt|jj�t|jj�kr`|jjSdS(N(R�RR'R�R*(R+((sZ/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_firewall_address_list.pyR�s
$cC`sd|jjdkrdS|jjdkr2|jjSt|jj�t|jj�kr`|jjSdS(N(R�RR'R�R*(R+((sZ/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_firewall_address_list.pyR�s
$cC`sd|jjdkrdS|jjdkr2|jjSt|jj�t|jj�kr`|jjSdS(N(R�RR'R�R*(R+((sZ/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_firewall_address_list.pyR�s
$cC`sd|jjdkrdS|jjdkr2|jjSt|jj�t|jj�kr`|jjSdS(N(R�RR'R�R*(R+((sZ/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_firewall_address_list.pyR�s
$N(RRR'R�R�R�R3RRRR(((sZ/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_firewall_address_list.pyR��s						t
ModuleManagercB`s�eZd�Zd�Zd�Zd�Zd�Zd�Zd�Zd�Z	d�Z
d	�Zd
�Zd�Z
d�Zd
�Zd�ZRS(cO`s^|jdd�|_t|jj�|_td|jj�|_t�|_	t
�|_dS(NtmoduleR5(tgetR'R�R
R5tclientR4R�R#R�R�tchanges(R+targstkwargs((sZ/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_firewall_address_list.pyR��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(NR5(R�R�R�RR"R�R�R't
isinstancetupdateR�R�tTrueR�(R+tdiffR"tchangedtktchange((sZ/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_firewall_address_list.pyt_update_changed_options�s		
cC`s|j�}|rtStS(N(R�R�R�(R+R,((sZ/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_firewall_address_list.pyt
should_updatescC`s�t}t�}|jj}|dkr6|j�}n|dkrQ|j�}ntd|jj��}|j�}|j	|�|j	td|��|j
|�|S(NtpresenttabsentR5R�(R�R�R�tstateRRR�R�R�R�t_announce_deprecations(R+R�R,Rt
reportableR�((sZ/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_firewall_address_list.pytexec_module
s	

cC`sH|jdg�}x/|D]'}|jjd|dd|d�qWdS(Nt
__warningstmsgR�(tpopR�t	deprecate(R+R,twarningstwarning((sZ/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_firewall_address_list.pyRs


cC`s$|j�r|j�S|j�SdS(N(texistsR�tcreate(R+((sZ/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_firewall_address_list.pyR&s
cC`s|j�r|j�StS(N(RtremoveR�(R+((sZ/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_firewall_address_list.pyR,s
cC`s=|j�|_|j�stS|jjr/tS|j�tS(N(tread_current_from_deviceR�R�R�R�t
check_modeR�tupdate_on_device(R+((sZ/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_firewall_address_list.pyR�1s
cC`s9|jjrtS|j�|j�r5td��ntS(NsFailed to delete the resource.(R�RR�tremove_from_deviceRR(R+((sZ/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_firewall_address_list.pyR:s
cC`s4t�|_|j�|jjr&tS|j�tS(N(R#R�R�R�RR�tcreate_on_device(R+((sZ/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_firewall_address_list.pyR
Bs

cC`s�dj|jjd|jjdt|jj|jj��}|jjj|�}y|j	�}Wnt
k
rwtSX|jdks�d|kr�|ddkr�tSt
S(Ns:https://{0}:{1}/mgmt/tm/security/firewall/address-list/{2}tservertserver_porti�tcode(R/R�tproviderRR�R.R%tapiR�tjsont
ValueErrorR�RR�(R+turitresptresponse((sZ/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_firewall_address_list.pyRJs


+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��ndS(NR%R.s7https://{0}:{1}/mgmt/tm/security/firewall/address-list/RRRRi�i�tmessage(i�i�(R�t
api_paramsR�R%R.R/R�RRtpostRRRR2tcontent(R+R5RRRtex((sZ/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_firewall_address_list.pyRYs
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(Ns:https://{0}:{1}/mgmt/tm/security/firewall/address-list/{2}RRRRi�R(R�RR/R�RRR�R.R%RtpatchRRRR2R!(R+R5RRRR"((sZ/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_firewall_address_list.pyRms

cC`sydj|jjd|jjdt|jj|jj��}|jjj|�}|j	dkrft
St|j��dS(Ns:https://{0}:{1}/mgmt/tm/security/firewall/address-list/{2}RRi�(
R/R�RRR�R.R%RtdeleteRR�RR!(R+RR((sZ/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_firewall_address_list.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(Ns:https://{0}:{1}/mgmt/tm/security/firewall/address-list/{2}RRRi�RR5(R/R�RRR�R.R%RR�RRRR2R!R#(R+RRRR"((sZ/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_firewall_address_list.pyR�s

(RRR�R�R�RRRRR�RR
RRRRR(((sZ/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_firewall_address_list.pyR��s															tArgumentSpeccB`seZd�ZRS(cC`st|_tdt�dtdt�dtdd�dtdd�dtdd�d	tddd
ddtd
tdt�dt���dtdd�dtdddtdgf�dtdddddg��	}i|_|jjt�|jj|�dS(NRR%trequiredRttypetlistRRRtelementsR�toptionsR�R�RR.tdefaulttCommontfallbacktF5_PARTITIONRRtchoicesR(R�tsupports_check_modeR�R	t
argument_specR�R(R+R1((sZ/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_firewall_address_list.pyR��s0				(RRR�(((sZ/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_firewall_address_list.pyR%�scC`s�t�}td|jd|j�}y,td|�}|j�}|j|�Wn)tk
r{}|jdt	|��nXdS(NR1R0R�R(
R%RR1R0R�Rt	exit_jsonRt	fail_jsonR2(tspecR�tmmtresultsR"((sZ/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_firewall_address_list.pytmain�s		t__main__(-t
__future__RRRR't
__metaclass__tANSIBLE_METADATAt
DOCUMENTATIONtEXAMPLEStRETURNR�tansible.module_utils.basicRR	t%library.module_utils.network.f5.bigipR
t&library.module_utils.network.f5.commonRRR
RRt%library.module_utils.compat.ipaddressRRt)library.module_utils.network.f5.ipaddressRRtImportErrort%ansible.module_utils.network.f5.bigipt&ansible.module_utils.network.f5.commont%ansible.module_utils.compat.ipaddresst)ansible.module_utils.network.f5.ipaddressRR#R4R�R�R�tobjectR�R�R%R7R(((sZ/usr/lib/python2.7/site-packages/ansible/modules/network/f5/bigip_firewall_address_list.pyt<module>sZ


Z+
!1�Q+:�"	

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