https://t.me/AnonymousX5
Server : Apache
System : Linux cvar2.toservers.com 3.10.0-962.3.2.lve1.5.73.el7.x86_64 #1 SMP Wed Aug 24 21:31:23 UTC 2022 x86_64
User : njnconst ( 1116)
PHP Version : 8.4.18
Disable Function : NONE
Directory :  /opt/alt/python37/lib/python3.7/site-packages/ssa/modules/__pycache__/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Current File : //opt/alt/python37/lib/python3.7/site-packages/ssa/modules/__pycache__/common.cpython-37.pyc
B

��c_�@s:dZddlmZddlmZddlmZGdd�d�ZdS)	zn
This module contains a base class including methods, common for
SSA Request Processor and SSA Decision Maker
�)�Tuple)�date�)�load_configurationc@sfeZdZdZdd�Zdd�Zeed�dd��Zee	d�d	d
��Z
eed�dd
�Z
eed�dd��ZdS)�Commonz
    Base SSA module class
    cCs|��|_dS)N)�	load_conf�config)�self�r
�C/opt/alt/python37/lib/python3.7/site-packages/ssa/modules/common.py�__init__szCommon.__init__cCst|d�}|�|d�S)a
        All undefined attributes, e.g.
            - domains_number
            - urls_number
            - correlation_coefficient
            - correlation
            - request_number
            - time
        are queried in config.
        Others would be empty
        r�)�getattr�get)r	�item�confr
r
r�__getattr__s
zCommon.__getattr__)�returncCsddhS)N�domain_total_reqs�is_a_wordpress_domainr
)r	r
r
r�non_url_fields)szCommon.non_url_fieldscCs|j�d�}dd�|D�S)z/
        Render configured ignore list
        �,cSsg|]}|��r|���qSr
)�strip)�.0�ir
r
r�
<listcomp>3sz-Common.configured_ignores.<locals>.<listcomp>)Zignore_list�split)r	�elementsr
r
r�configured_ignores-szCommon.configured_ignores)�_urlrcs�fdd�|jD�}t|�S)z8
        Check if given URL matches ignore list
        c3s|]}|�kVqdS)Nr
)rZign)rr
r�	<genexpr>9sz$Common.is_ignored.<locals>.<genexpr>)r�any)r	rZ	gen_checkr
)rr�
is_ignored5szCommon.is_ignoredcCst�S)z$
        Load configuration
        )rr
r
r
rr<szCommon.load_confN)�__name__�
__module__�__qualname__�__doc__rr�property�setr�listr�str�boolr"�staticmethod�dictrr
r
r
rrsrN)r&�typingr�datetimer�
configurationrrr
r
r
r�<module>s

https://t.me/AnonymousX5 - 2025