Graybyt3 Was Here
Linux cloud.locucionar.com 3.10.0-1160.81.1.el7.x86_64 #1 SMP Fri Dec 16 17:29:43 UTC 2022 x86_64
Apache
91.191.211.241
/
opt
/
imunify360
/
venv
/
lib64
/
python3.11
/
site-packages
/
defence360agent
/
plugins
/
__pycache__
[ HOME ]
Exec
Submit
config_watcher.cpython-311.pyc
� k�nh� � � � d dl Z d dlmZ d dlmZ d dlmZmZmZ d dl m Z mZ ej dd� � Z G d� d ee� � ZdS ) � N)�config)�MessageType)�MessageSink� MessageSource�expect)�recurring_check�Scope�READ_CONFIG_POLLING_INTERVAL� c � � e Zd ZdZej Zd� Zd� Z e e j � � d� � � Zd� Z d� Z ee� � d� � � ZdS ) � ConfigWatcherz�Send ConfigUpdate message on [root's] config update. The config update is detected by polling config file's modification time. c �` � t j � � | _ d| _ d | _ d | _ d S )Nr )r � ConfigFile�_config�_last_notify_time�_sink�_task)�selfs �[/opt/imunify360/venv/lib/python3.11/site-packages/defence360agent/plugins/config_watcher.py�__init__zConfigWatcher.__init__ s, � ��(�*�*���!"����� ��� � � � c � � K � dS )zplugins.MessageSink methodN� )r �loops r �create_sinkzConfigWatcher.create_sink s � � � � � r c � �$ K � |d | _ d S )N� timestamp)r �r �messages r �on_config_update_messagez&ConfigWatcher.on_config_update_message! s � � � � ")��!5����r c � �p K � || _ |� | � � � � � | _ d S �N)r �create_task� _check_configr )r r �sinks r � create_sourcezConfigWatcher.create_source'