�
�Udac @` s� d d l m Z m Z m Z e Z i d d 6d g d 6d d 6Z d Z d Z d
Z d d l
m Z d d l m
Z
d d
l m Z d d l Z d � Z d � Z e d k r� e � n d S( i ( t absolute_importt divisiont print_functions 1.1t metadata_versiont previewt statust networkt supported_bys�
---
module: checkpoint_object_facts
short_description: Get object facts on Check Point over Web Services API
description:
- Get object facts on Check Point devices.
All operations are performed over Web Services API.
version_added: "2.8"
author: "Ansible by Red Hat (@rcarrillocruz)"
options:
uid:
description:
- UID of the object. If UID is not provided, it will do a full search
which can be filtered with the filter argument.
object_filter:
description:
- Filter expression for search. It accepts AND/OR logical operators and performs a textual
and IP address search. To search only by IP address, set ip_only argument to True.
which can be filtered with the filter argument.
ip_only:
description:
- Filter only by IP address.
type: bool
default: false
object_type:
description:
- Type of the object to search. Must be a valid API resource name
type: str
sg
- name: Get object facts
checkpoint_object_facts:
object_filter: 192.168.30.30
ip_only: yes
s]
ansible_hosts:
description: The checkpoint object facts.
returned: always.
type: list
( t
AnsibleModule( t
Connection( t HTTPErrorNc C` s� | j d } | j d } | j d } | j d } | rb i | d 6} | j d | � \ } } n3 i | d 6| d 6| d 6} | j d | � \ } } | | f S(
Nt uidt
object_filtert ip_onlyt object_types /web_api/show-objectt filters ip-onlyt types /web_api/show-objects( t paramst send_request( t modulet
connectionR R R
R t payloadt codet result( ( s_ /usr/lib/python2.7/site-packages/ansible/modules/network/check_point/checkpoint_object_facts.pyt
get_objectP s
c
C` s� t d t d d d d � d t d d d d � d t d d d t � d t d d d d � � } t d | � } t | j � } t | | � \ } } | d
k r� | j d t d | � � n | j d
d j | | � � d S( NR R t strt defaultR R
t boolR t
argument_speci� t
ansible_factst checkpoint_objectst msgs6 Check Point device returned error {0} with message {1}(
t dictt Nonet FalseR R t _socket_pathR t exit_jsont fail_jsont format( R R R R t response( ( s_ /usr/lib/python2.7/site-packages/ansible/modules/network/check_point/checkpoint_object_facts.pyt main` s t __main__( t
__future__R R R R t
__metaclass__t ANSIBLE_METADATAt
DOCUMENTATIONt EXAMPLESt RETURNt ansible.module_utils.basicR t ansible.module_utils.connectionR t+ ansible.module_utils.six.moves.urllib.errorR
t jsonR R( t __name__( ( ( s_ /usr/lib/python2.7/site-packages/ansible/modules/network/check_point/checkpoint_object_facts.pyt <module> s
Anons79 File Manager Version 1.0, Coded By Anons79
Email: [email protected]