← Back
Editing: objectmodel.cpython-312.opt-1.pyc
� �jw � �p � d Z g d�ZdZdZdZeez Zeeeed�Zedededed iZ G d � d� Z G d� d � Z y)z� This module provides knowledge object classes and permissions. It should be used to keep this knowledge from leaking into the more generic parts of the policy generation. ) �socket�fd�process�file�lnk_file� fifo_file�dbus� capability�unix_stream_socket� � � )�n�r�w�br r r r c � � e Zd ZdZd� Zd� Zy)�PermMapa A mapping between a permission and its information flow properties. PermMap represents the information flow properties of a single permission including the direction (read, write, etc.) and an abstract representation of the bandwidth of the flow (weight). c �. � || _ || _ || _ y �N)�perm�dir�weight)�selfr r r s �9/usr/lib/python3.12/site-packages/sepolgen/objectmodel.py�__init__zPermMap.__init__T s � ��� ������� c �\ � d| j t | j | j fz S )Nz'<sepolgen.objectmodel.PermMap %s %s %d>)r � dir_to_strr r �r s r �__repr__zPermMap.__repr__Y s0 � �8�D�I�I�;E�d�h�h�;O�;?�;�;�<H� H� Hr N)�__name__� __module__�__qualname__�__doc__r r � r r r r M s � ��� Hr r c �4 � e Zd ZdZd� Zd� Zd� Zd� Zd� Zd� Z y) �PermMappingsz�The information flow properties of a set of object classes and permissions. PermMappings maps one or more classes and permissions to their PermMap objects describing their information flow characteristics. c �6 � i | _ d| _ t | _ y )N� )�classes�default_weight� FLOW_BOTH�default_dirr s r r zPermMappings.__init__d s � �������$��r c � � d}|D ]� }|j � }t |� dk( st |� dk( s|d dk( r�8|d dk( r=|d }|| j v rt d� �i | j |<