✘✘ GRAYBYTE WORDPRESS FILE MANAGER ✘✘

​🇳​​🇦​​🇲​​🇪♯➤ server.blackpussy.asia ​🇻​♯➤ 5.14.0-611.20.1.el9_7.x86_64 #1 SMP 🇾​♯➤ 2026

𝗛𝗢𝗠𝗘 𝗜𝗗 ♯➤ 163.245.207.76 ♯➤ 𝗔𝗗𝗠𝗜𝗡 𝗜𝗗 216.73.216.243
𝗢𝗣𝗧𝗜𝗢𝗡𝗦 ♯ CRL ♯➤ 𝗢𝗞 ┃ WGT ♯➤ 𝗢𝗞 ┃ SDO ♯➤ 𝗢𝗞 ┃ PKEX ♯➤ 𝗢𝗙𝗙
𝗗𝗘𝗔𝗖𝗧𝗜𝗩𝗔𝗧𝗘𝗗 ♯➤ mail,mb_send_mail
𝗖𝗨𝗥𝗥𝗘𝗡𝗧 𝗙𝗜𝗟𝗘 : /usr/lib/python3.9/site-packages/sepolgen/__pycache__//matching.cpython-39.opt-1.pyc
a

B�i�!�@sbdZddlZddlmZddlmZddlmZGdd�dej�ZGd	d
�d
�ZGdd�d�Z	dS)
zI
Classes and algorithms for matching requested access to access vectors.
�N�)�access)�objectmodel)�utilc@seZdZddd�Zdd�ZdS)�MatchNrcCs||_||_d|_d|_dS�NF)�	interface�dist�info_dir_change�__hash__)�selfrr	�r
�5/usr/lib/python3.9/site-packages/sepolgen/matching.py�__init__ szMatch.__init__c	CsDz$|j|jf}|j|jf}|||�WSttfy>tYS0dS�N)r	r
�AttributeError�	TypeError�NotImplemented)r�other�method�a�br
r
r�_compare(szMatch._compare)Nr)�__name__�
__module__�__qualname__rrr
r
r
rrs
rc@sHeZdZdZdd�Zdd�Zdd�Zdd	�Zd
d�Zdd
�Z	dd�Z
dS)�	MatchList�cCs$g|_g|_|j|_d|_d|_dSr)�children�bastards�DEFAULT_THRESHOLD�	threshold�allow_info_dir_change�av�rr
r
rr3s
zMatchList.__init__cCs,t|j�r|jdSt|j�r(|jdSdS�Nr��lenrrr$r
r
r�best<s




zMatchList.bestcCst|j�t|j�Srr&r$r
r
r�__len__CszMatchList.__len__cCs
t|j�Sr)�iterrr$r
r
r�__iter__IszMatchList.__iter__cCst�|j|j�Sr)�	itertools�chainrrr$r
r
r�allLsz
MatchList.allcCsD|j|jkr4|jr|jr&|j�|�q@|j�|�n|j�|�dSr)r	r!r
r"r�appendr)r�matchr
r
rr/Os
zMatchList.appendcCs|j��|j��dSr)r�sortrr$r
r
rr1Xs
zMatchList.sortN)rrrr rr(r)r+r.r/r1r
r
r
rr1s		rc@s>eZdZddd�Zdd�Zdd�Zdd	�Zd
d�Zdd
�ZdS)�
AccessMatcherNcCs,d|_d|_|r||_n
t��|_d|_dS)N�
�d)�type_penalty�obj_penalty�	perm_mapsrZPermMappings�info_dir_penalty)rr7r
r
rr^s
zAccessMatcher.__init__cCs"||kst�|�rdS|jSdSr%)r�
is_idparamr5)rrrr
r
r�
type_distancejszAccessMatcher.type_distancecCsR|j�|j�}t|�dkr0|j�|j|�}|S|j�|j�}|j�|j|�SdSr%)�perms�
differencer'r7�getdefault_distance�	obj_class)rZav_reqZav_prov�diff�totalr
r
r�
perm_distanceqszAccessMatcher.perm_distancecCs�d}||�|j|j�7}||�|j|j�7}|j|jkrNt�|j�sN||j8}|dkrj|j�|j|j	�}n|�
||�}|dkr�|dkr�||S||Sn |dkr�|dkr�||S||SdS)a,Determine the 'distance' between 2 access vectors.

        This function is used to find an access vector that matches
        a 'required' access. To do this we comput a signed numeric
        value that indicates how close the req access is to the
        'provided' access vector. The closer the value is to 0
        the closer the match, with 0 being an exact match.

        A value over 0 indicates that the prov access vector provides more
        access than the req (in practice, this means that the source type,
        target type, and object class is the same and the perms in prov is
        a superset of those in req.

        A value under 0 indicates that the prov access less - or unrelated
        - access to the req access. A different type or object class will
        result in a very low value.

        The values other than 0 should only be interpreted relative to
        one another - they have no exact meaning and are likely to
        change.

        Params:
          req - [AccessVector] The access that is required. This is the
                access being matched.
          prov - [AccessVector] The access provided. This is the potential
                 match that is being evaluated for req.
        Returns:
          0   : Exact match between the access vectors.

          < 0 : The prov av does not provide all of the access in req.
                A smaller value indicates that the access is further.

          > 0 : The prov av provides more access than req. The larger
                the value the more access over req.
        rN)r:Zsrc_type�tgt_typer>rr9r6r7r=r;rA)rZreqZprovr	Zpdistr
r
r�av_distance|s '

zAccessMatcher.av_distancecCs�d}|D]^}|�||�}|dur&|}q|dkrL|dkr@||7}qf||}q|dkr^||7}q||8}q|j�|j|j�}|jdur�tj|_|D]}|j|j�|j|j�B|_q�|tj@dkr�|jtj@r�|dkr�||j	8}n
||j	7}|S)z


        Nr)
rCr7Zgetdefault_directionr>r;Zinfo_dirrZ	FLOW_NONEZ
FLOW_WRITEr8)rZav_setr#r	�x�tmpZav_dirr
r
r�av_set_match�s0



�
zAccessMatcher.av_set_matchcCsd||_t�|j|j�|jg��D]6}|js,q |�|j	|�}|dkr t
||�}|�|�q |��dSr%)
r#r,r-Ztgt_type_allZtgt_type_map�getrBZenabledrFrrr/r1)rZifsetr#Z
match_listZivr	�mr
r
r�
search_ifs�s�
zAccessMatcher.search_ifs)N)	rrrrr:rArCrFrIr
r
r
rr2]s
H(r2)
�__doc__r,�rrrZ
Comparisonrrr2r
r
r
r�<module>s,

Current_dir [ 𝗡𝗢𝗧 𝗪𝗥𝗜𝗧𝗘𝗔𝗕𝗟𝗘 ] Document_root [ 𝗪𝗥𝗜𝗧𝗘𝗔𝗕𝗟𝗘 ]

Current_dir [ 𝗡𝗢𝗧 𝗪𝗥𝗜𝗧𝗘𝗔𝗕𝗟𝗘 ] Document_root [ 𝗪𝗥𝗜𝗧𝗘𝗔𝗕𝗟𝗘 ]


[ Back ]
𝗡𝗔𝗠𝗘
𝗦𝗜𝗭𝗘
𝗟𝗔𝗦𝗧 𝗧𝗢𝗨𝗖𝗛
𝗨𝗦𝗘𝗥
𝗦𝗧𝗔𝗧𝗨𝗦
𝗙𝗨𝗡𝗖𝗧𝗜𝗢𝗡𝗦
..
--
27 May 2026 4.58 AM
root / root
0755
__init__.cpython-39.opt-1.pyc
0.141 KB
5 Apr 2026 11.05 AM
root / root
0644
__init__.cpython-39.pyc
0.141 KB
5 Apr 2026 11.05 AM
root / root
0644
access.cpython-39.opt-1.pyc
11.095 KB
5 Apr 2026 11.05 AM
root / root
0644
access.cpython-39.pyc
11.095 KB
5 Apr 2026 11.05 AM
root / root
0644
audit.cpython-39.opt-1.pyc
16.855 KB
5 Apr 2026 11.05 AM
root / root
0644
audit.cpython-39.pyc
16.855 KB
5 Apr 2026 11.05 AM
root / root
0644
classperms.cpython-39.opt-1.pyc
2.413 KB
5 Apr 2026 11.05 AM
root / root
0644
classperms.cpython-39.pyc
2.413 KB
5 Apr 2026 11.05 AM
root / root
0644
defaults.cpython-39.opt-1.pyc
2.244 KB
5 Apr 2026 11.05 AM
root / root
0644
defaults.cpython-39.pyc
2.244 KB
5 Apr 2026 11.05 AM
root / root
0644
interfaces.cpython-39.opt-1.pyc
12.297 KB
5 Apr 2026 11.05 AM
root / root
0644
interfaces.cpython-39.pyc
12.297 KB
5 Apr 2026 11.05 AM
root / root
0644
lex.cpython-39.opt-1.pyc
20.876 KB
5 Apr 2026 11.05 AM
root / root
0644
lex.cpython-39.pyc
20.876 KB
5 Apr 2026 11.05 AM
root / root
0644
matching.cpython-39.opt-1.pyc
6.024 KB
5 Apr 2026 11.05 AM
root / root
0644
matching.cpython-39.pyc
6.024 KB
5 Apr 2026 11.05 AM
root / root
0644
module.cpython-39.opt-1.pyc
7.002 KB
5 Apr 2026 11.05 AM
root / root
0644
module.cpython-39.pyc
7.002 KB
5 Apr 2026 11.05 AM
root / root
0644
objectmodel.cpython-39.opt-1.pyc
3.878 KB
5 Apr 2026 11.05 AM
root / root
0644
objectmodel.cpython-39.pyc
3.878 KB
5 Apr 2026 11.05 AM
root / root
0644
output.cpython-39.opt-1.pyc
3.462 KB
5 Apr 2026 11.05 AM
root / root
0644
output.cpython-39.pyc
3.462 KB
5 Apr 2026 11.05 AM
root / root
0644
policygen.cpython-39.opt-1.pyc
12.585 KB
5 Apr 2026 11.05 AM
root / root
0644
policygen.cpython-39.pyc
12.617 KB
5 Apr 2026 11.05 AM
root / root
0644
refparser.cpython-39.opt-1.pyc
28.573 KB
5 Apr 2026 11.05 AM
root / root
0644
refparser.cpython-39.pyc
28.573 KB
5 Apr 2026 11.05 AM
root / root
0644
refpolicy.cpython-39.opt-1.pyc
39.231 KB
5 Apr 2026 11.05 AM
root / root
0644
refpolicy.cpython-39.pyc
39.231 KB
5 Apr 2026 11.05 AM
root / root
0644
sepolgeni18n.cpython-39.opt-1.pyc
0.385 KB
5 Apr 2026 11.05 AM
root / root
0644
sepolgeni18n.cpython-39.pyc
0.385 KB
5 Apr 2026 11.05 AM
root / root
0644
util.cpython-39.opt-1.pyc
6.215 KB
5 Apr 2026 11.05 AM
root / root
0644
util.cpython-39.pyc
6.215 KB
5 Apr 2026 11.05 AM
root / root
0644
yacc.cpython-39.opt-1.pyc
51.888 KB
5 Apr 2026 11.05 AM
root / root
0644
yacc.cpython-39.pyc
51.965 KB
5 Apr 2026 11.05 AM
root / root
0644

✘✘ GRAYBYTE WORDPRESS FILE MANAGER @ 2026 CONTACT ME ✘✘
Static GIF Static GIF