+
        c                     (   ^ RI t ^ RIHt ^ RIHtHt ^ RIHt ^ RIH	t	 ^ RI
Ht ^ RIt^RIHtHt ^RIHt ^R	IHt ^R
IHtHtHt ^RIHtHt ^RIHt ^RIHt ]	! R4      t]	! R4      t]! RRR7       ! R R]4      4       t ]! RRR7       ! R R]4      4       t!]! RRR7       ! R R]4      4       t" ! R R]4      t#] ! R R4      4       t$] ! R R4      4       t%] ! R R4      4       t&]PN                  ](,          t)]*](,          t+],])],]+],](],](],](]%3,          3,          3,          3,          3,          t-R  R! lt.R" R# lt/R$ R% lt0R& R' lt1R( R) lt2R* R+ lt3R, R- lt4 ! R. R/]4      t5 ! R0 R1]]Pl                  ,          4      t7 ! R2 R3]4      t8R# )4    N)defaultdict)CallableIterable)	dataclass)intern)Enum)	exception	policyrep)conditional_wrapper_factory)DiffResultDescriptor)
DifferenceDifferenceResultWrapper)type_wrapper_factorytype_or_attr_wrapper_factory)RuleList)class_wrapper_factoryz<<unconditional>>TrueT)frozenorderc                   0   a  ] tR t^t o RtV 3R ltRtV tR# )ModifiedAVRule5Difference details for a modified access vector rule.c                   < V ^8  d   Qh/ S[ P                  ;R&   S[S[,          ;R&   S[S[,          ;R&   S[S[,          ;R&   #    ruleadded_permsremoved_permsmatched_perms)r
   AVRulesetstr)format__classdict__s   ";/usr/lib64/python3.14/site-packages/setools/diff/terules.py__annotate__ModifiedAVRule.__annotate__   sK     
 

  S  s8  s8      N__name__
__module____qualname____firstlineno____doc____annotate_func____static_attributes____classdictcell__r%   s   @r&   r   r            @  r)   r   c                   0   a  ] tR t^&t o RtV 3R ltRtV tR# )ModifiedAVRuleXpermr   c                   < V ^8  d   Qh/ S[ P                  ;R&   S[ P                  ;R&   S[ P                  ;R&   S[ P                  ;R&   # r   )r
   AVRuleXpermXpermSet)r$   r%   s   "r&   r'    ModifiedAVRuleXperm.__annotate__&   sQ     
 

  ###  %%%  %%% r)   r*   Nr+   r4   s   @r&   r7   r7   &   r5   r)   r7   c                   0   a  ] tR t^1t o RtV 3R ltRtV tR# )ModifiedTERulez.Difference details for a modified type_* rule.c                z   < V ^8  d   Qh/ S[ P                  ;R&   S[ P                  ;R&   S[ P                  ;R&   # )r   r   added_defaultremoved_default)r
   r!   Type)r$   r%   s   "r&   r'   ModifiedTERule.__annotate__1   s:     
 

  >>!  ^^# r)   r*   Nr+   r4   s   @r&   r=   r=   1   s      9  r)   r=   c                       ] tR t^>t^ t^tRtR# )Sider*   N)r,   r-   r.   r/   leftrightr2   r*   r)   r&   rD   rD   >   s    DEr)   rD   c                   ,   a  ] tR t^Ct o V 3R ltRtV tR# )RuleDBSideDataRecordc                V   < V ^8  d   Qh/ S[ S[,          ;R&   S[P                  ;R&   # )r   perms	orig_rule)r"   r#   r
   r!   )r$   r%   s   "r&   r'   !RuleDBSideDataRecord.__annotate__C   s&     s8O   r)   r*   Nr,   r-   r.   r/   r1   r2   r3   r4   s   @r&   rH   rH   C         r)   rH   c                   ,   a  ] tR t^It o V 3R ltRtV tR# )RuleDBSidesRecordc                N   < V ^8  d   Qh/ S[ R,          ;R&   S[ R,          ;R&   # )r   NrE   rF   )rH   )r$   r%   s   "r&   r'   RuleDBSidesRecord.__annotate__I   s'     

%%   $&& r)   r*   NrM   r4   s   @r&   rP   rP   I   rN   r)   rP   c                   ,   a  ] tR t^Ot o V 3R ltRtV tR# )TypeDBRecordc                   < V ^8  d   Qh/ S[ S[S[P                  3,          ;R&   S[ S[S[P                  3,          ;R&   # )r   rE   rF   )dictr#   r
   rA   )r$   r%   s   "r&   r'   TypeDBRecord.__annotate__O   s9     
sINN"
##  Y^^#$$ r)   r*   NrM   r4   s   @r&   rT   rT   O   rN   r)   rT   c          
      v    V ^8  d   QhR\         \        P                  ,          R\        R\        R\
        RR/# )r   	rule_listrule_dbtype_dbsidereturnN)listr
   r!   RuleDBrT   rD   )r$   s   "r&   r'   r'   [   sK     X[ X[Y-=-=(> X[ X[&2X[:>X[CGX[r)   c                l   V\         P                  8X  d   VP                  pMVP                  pV  EFV  p \        \	        VP
                  4      4      p\        \	        VP                  4      4      pWa9  d!   \        4       W&   \        4       W,          V&   M WqV,          9  d   \        4       W,          V&   VP                  P                  p\        VP                  4      p	\!        W4      p
W,          V,          pVP"                  P%                  4        EFk  pVP                  pW9  d   WV&   W9  d   \        4       W&   VP&                  P%                  4        EF   pVP                  pW9  d   WV&   WV,          9  d   \        4       W,          V&   RpRpWV,          V,          9   d/   W,          V,          V,          pVP                  pVP                  pV\         P                  8X  d9   V'       g   T
pMd VP                  V	,          pVP(                  p\!        VV4      pM7V'       g   T
pM, VP                  V	,          pVP(                  p\!        VV4      p\+        VV4      W,          V,          V&   EK#  	  EKn  	  EKY  	  R#   \        P                   d    \        p\        p EL@i ; i)a  
Using rule_list, build up rule_db which is a data structure which consists
of nested dicts that store BOTH the left and the right policies. All of the
keys are interned strings. The permissions are stored as a set. The basic
structure is rule_db[cond_exp][block_bool][src][tgt][tclass] = sides
where:
  cond_exp is a boolean expression
  block_bool is either true or false
  src is the source type
  tgt is the target type
  tclass is the target class
  sides is a named tuple with attributes "left" and "right" referring to the
    left or right policy. Each attribute in the sides named tuple refers to a
    named tuple with attributes "perms" and "orig_rule" which refer to a
    permission set and the original unexpanded rule.
    sides = ((left_perms, left_orig_rule),(right_perms, right_orig_rule))
There are a few advantages to this structure. First, it takes up way less
memory. Second, it allows redundant rules to be easily eliminated. And,
third, it makes it easy to create the added, removed, and modified rules.
N)rD   rE   rF   r   r#   conditionalconditional_blockr	   RuleNotConditionalTERULES_UNCONDITIONALTERULES_UNCONDITIONAL_BLOCKrV   tclassnamer"   rJ   rH   sourceexpandtargetrK   rP   )rY   rZ   r[   r\   typesunexpanded_rulecond_exp
block_boolrf   rJ   	side_datablocksrcsrc_strtgttgt_str	left_side
right_sidesidesporigs   &&&&                 r&   _avrule_expand_generatorrz   [   s?   , tyy$	5c/"="=>?HO$E$E FGJ
 " $G,0FGj)x00,0FGj) '',,O))*(@	!*-"))002ChhG#!$g#!%&--446(('%('N.0.2fEN7+ 	!
7^G44!N73F;E %

I!&J499$$$-	 &OOe3(22$8D$A	%%.
 ',,u4)33%9!T%B
2CIz2Zw'/I 7 3' % ++ 	5,H4J	5s   <J!J32J3c                (    V ^8  d   QhR\         RR/# )r   rZ   r]   N)r_   )r$   s   "r&   r'   r'      s     #\ #\ #\4 #\r)   c           	      B   V \         ,          \        ,          pV P                  4        EF  w  r#V\         8X  d   K  VP                  4        EF  pVP                  4        EF  w  rVWQ9  d   K  VP                  4        EF  w  rxWqV,          9  d   K  VP                  4        EFc  w  rWV,          V,          9  d   K  W,          V,          V	,          pV
P                  pV
P
                  pVP                  '       dx   V'       dp   VP                  VP                  P                  ,          pV'       dA   VP                  V,
          pV'       d   \        WP                  4      pMR p\        W4      W&   VP
                  '       g   K  V'       g   K  VP                  VP
                  P                  ,          pV'       g   EK#  VP                  V,
          pV'       d   \        WP                  4      pMR p\        W4      W&   EKf  	  EK  	  EK  	  EK  	  EK  	  R # N)
rd   re   itemsvaluesrE   rF   rJ   rH   rK   rP   )rZ   uncond_blockrm   cond_blocksrp   rq   src_datars   tgt_datarf   ro   uncond_side_dataru   rv   crx   s   &               r&   _av_remove_redundant_rulesr      s   012MNL!(,, '')E!&*%-^^%5MCs"33 -5^^-=)!c):3)??$+7+<S+A&+I($-NN	%.__
+000Y )2B2G2G2M2M MA $-OOa$7#$0DQH[H[0\I04I3DY3[ 0+111jj * 0 03C3I3I3O3O OA q$.$4$4q$8#$1EaI]I]1^J15J3DY3[ 0/ .> &6 "/ * "1r)   c          
          V ^8  d   QhR\         R\        R\        \        \        P
                  ,          \        \        P
                  ,          \        \        ,          3,          /# )r   rZ   r[   r]   )r_   rT   tupler^   r
   r!   r   )r$   s   "r&   r'   r'      sI     $$ $$ $$ $$d9##$d9+;+;&<d>>RRS$$r)   c                 p   . p. p. pV P                  4        EF  pVP                  4        EF  pVP                  4        EFf  w  rxVP                  4        EFK  w  rV
P                  4        EF0  pVP                  '       Ed   VP                  '       d   VP                  P                  VP                  P                  ,          pVP                  P                  V,
          pVP                  P                  V,
          pV'       g	   V'       d   VP                  P
                  pVP                  VP                  V,          VP                  V	,          VP                  P                  4      pVP                  \        VVVV4      4       EK#  EK&  VP                  '       dt   VP                  P
                  pVP                  VP                  V,          VP                  V	,          VP                  P                  4      pVP                  V4       EK  VP                  '       g   EK  VP                  P
                  pVP                  VP                  V,          VP                  V	,          VP                  P                  4      pVP                  V4       EK3  	  EKN  	  EKi  	  EK  	  EK  	  W#V3# r}   )	r   r~   rE   rF   rJ   rK   derive_expandedappendr   )rZ   r[   addedremovedmodifiedr   rp   rq   r   rs   r   ro   common_perms
left_permsright_permsoriginal_ruler   s   &&               r&   _av_generate_diffsr      s    %'E&(G%'H~~' '')E!&%-^^%5MC%-__%6	$>>>iooo+4>>+?+?)//BWBW+WL)2)=)=)LJ*3//*?*?,*NK)[090H0H'4'D'D$+LL$5w||C7H$-NN$8$8(: !)t[?I?K1M !N .9 '^^^,5NN,D,DM#0#@#@ 'S 17<<3D ) 4 4$6D $NN40&___,5OO,E,EM#0#@#@ 'c 2GMM#4F ) 5 5$7D "LL.1 &7 &6 "/ * (< 8##r)   c                X    V ^8  d   QhR\         P                  R\        R.R3,          /# r   ruletyper]   TERulesDifferenceNr
   
TERuletyper   )r$   s   "r&   r'   r'     s/     * *y33 *BUAVX\A\8] *r)   c                   a  R V 3R llpV# )zp
This is a template for the access vector diff functions.

Parameters:
ruletype    The rule type, e.g. "allow".
c                    V ^8  d   QhRR/# r   r]   Nr*   )r$   s   "r&   r'   &av_diff_template.<locals>.__annotate__  s      9  9d  9r)   c                V  < V P                   P                  RS RV P                   RV P                   24       V P                  e   V P
                  f   V P                  4        \        \        4       \        4       4      p\        4       p\        4       V\        &   \        4       V\        ,          \        &   V P                   P                  RV P                   R24       \        V P                  S,          W!\        P                  4       V P                   P                  RV P                   R24       \        V P
                  S,          W!\        P                  4       V P                   P                  R4       \        V4       V P                   P                  R4       \!        W!4      w  r4pVP                  P#                  4        VP                  P#                  4        VP#                  4        \%        V R	S R
2V4       \%        V RS R
2V4       \%        V RS R
2V4       R# )6Generate the difference in rules between the policies.Generating  differences from  to NzExpanding AV rules from .zRemoving redundant AV rules.zGenerating AV rule diff.added_sremoved_	modified_)loginfoleft_policyright_policy_left_te_rules_right_te_rules_create_te_rule_listsrT   rV   rd   re   rz   rD   rE   rF   r   r   clearsetattr)selfr[   rZ   r   r   r   r   s   &     r&   diffav_diff_template.<locals>.diff  s    	(#5d6F6F5GtDL]L]K^_	a &$*>*>*F&&(tvtv.&)-%&FJf%&'BC01A1A0B!DE !4!4X!>RVR[R[\01B1B0C1EF !5!5h!?SWS]S]^45"7+01#5g#G xj*E2
!,g6	(1-x8r)   r*   r   r   s   f r&   av_diff_templater     s     9  9D Kr)   c                h    V ^8  d   QhR\         \        P                  ,          R\         R,          /# )r   rY   r]   AVRuleXpermWrapper)r   r
   r9   )r$   s   "r&   r'   r'   0  s,      )2G2G)H #+,@#Ar)   c                   \        4       pV  FO  pVP                  4        F8  p\        V4      p W,          ;P                  VP                  ,          un        K:  	  KQ  	  V'       d7   \
        P                  ! \        4      P                  R\        V4       R24       VP                  4       #   \         d	    YAT&    K  i ; i)zT
Generator that yields wrapped, expanded, av(x) rules with
unioned permission sets.
z	Expanded z rules)rV   ri   r   rJ   KeyErrorlogging	getLoggerr,   debuglenkeys)rY   r~   rl   expanded_ruleexpanded_wrapped_rules   &    r&   _avxrule_expand_generatorr   0  s     ?CfE$,335M$6}$E!E,226K6Q6QQ2 6 % (#))Ic%j\*HI::<  E/D+,Es   )B..C Cc                X    V ^8  d   QhR\         P                  R\        R.R3,          /# r   r   )r$   s   "r&   r'   r'   K  s/     - -	 4 4 -CVBWY]B]9^ -r)   c                   a  R V 3R llpV# )z
This is a template for the extended permission access vector diff functions.

Parameters:
ruletype    The rule type, e.g. "allowxperm".
c                    V ^8  d   QhRR/# r   r*   )r$   s   "r&   r'   'avx_diff_template.<locals>.__annotate__S  s     #9 #9d #9r)   c                  < V P                   P                  RS
 RV P                   RV P                   24       V P                  '       d   V P
                  '       g   V P                  4        V P                  \        V P                  S
,          4      \        V P
                  S
,          4      RR7      w  rp. pV F  w  rVV P                  VP                  VP                  RR7      w  rxp	V'       g   V'       g   KB  VP                  \        VP                  \        P                  ! V4      \        P                  ! V4      \        P                  ! R V	 4       4      4      4       K  	  \        V RS
 R2\!        R	 V 4       4      4       \        V R
S
 R2\!        R V 4       4      4       \        V RS
 R2V4       R# )r   r   r   r   F)unwrapc              3   2   "   T F  q^ ,          x  K  	  R# 5i)r   Nr*   ).0rx   s   & r&   	<genexpr>2avx_diff_template.<locals>.diff.<locals>.<genexpr>r  s     :WAQ44s   r   r   c              3   8   "   T F  qP                   x  K  	  R # 5ir}   origin)r   as   & r&   r   r   t  s     /H%Q%   r   c              3   8   "   T F  qP                   x  K  	  R # 5ir}   r   )r   rs   & r&   r   r   u  s     1LGq((Gr   r   N)r   r   r   r   r   r   r   	_set_diffr   rJ   r   r7   r   r
   r:   r   r"   )r   r   r   matchedr   	left_rule
right_ruler   r   r    r   s   &         r&   r   avx_diff_template.<locals>.diffS  s    	(#5d6F6F5G H##$&	' """$*>*>*>&&("&..%d&9&9(&CD%d&:&:8&DE #1 #
 %,!I 9=yGQGWGWNS 9G 9U5K mm'	(8(8(1(:(:;(G(1(:(:=(I(1(:(::W:W(WYZ &-" 	xj*C/H%/H,HI
!,c1LG1L.LM	(1-x8r)   r*   r   s   f r&   avx_diff_templater   K  s    #9 #9J Kr)   c                t    V ^8  d   QhR\         P                  R\        \        P                  .R3,          /# )r   r   r]   N)r
   r   r   typingAny)r$   s   "r&   r'   r'   {  s0     " "y33 "&**tAS8T "r)   c                   a  R V 3R llpV# )zs
This is a template for the type_* diff functions.

Parameters:
ruletype    The rule type, e.g. "type_transition".
c                    V ^8  d   QhRR/# r   r*   )r$   s   "r&   r'   &te_diff_template.<locals>.__annotate__  s     9 9d 9r)   c                  < V P                   P                  RS RV P                   RV P                   24       V P                  e   V P
                  f   V P                  4        V P                  V P                  V P                  S,          \        4      V P                  V P
                  S,          \        4      4      w  rp. pV Fd  w  rV\        VP                  4      \        VP                  4      8w  g   K4  VP                  \        VVP                  VP                  4      4       Kf  	  \        V RS R2V4       \        V RS R2V4       \        V RS R2V4       R# )	r   r   r   r   Nr   r   r   r   )r   r   r   r   r   r   r   r   _expand_generatorTERuleWrapperr   defaultr   r=   r   )r   r   r   r   r   r   r   r   s   &      r&   r   te_diff_template.<locals>.diff  sI    	(#5d6F6F5GtDL]L]K^_	a &$*>*>*F&&("&..""4#6#6x#@-P""4#7#7#A=Q#S %,!I $I$5$56:NzOaOa:bby/9/A/A/8/@/@!B C	 &- 	xj*E2
!,g6	(1-x8r)   r*   r   s   f r&   te_diff_templater   {  s    9 94 Kr)   c                   Z  a  ] tR tRt o Rt]! ]P                  P                  4      t	]
]P                  ,          ! ]	4      t]
]P                  ,          ! ]	4      t]
],          ! ]	4      t]! ]P                  P                   4      t]
]P                  ,          ! ]4      t]
]P                  ,          ! ]4      t]
],          ! ]4      t]! ]P                  P*                  4      t]
]P                  ,          ! ]4      t]
]P                  ,          ! ]4      t]
],          ! ]4      t]! ]P                  P4                  4      t]
]P                  ,          ! ]4      t]
]P                  ,          ! ]4      t]
],          ! ]4      t]! ]P                  P@                  4      t!]
]PD                  ,          ! ]!4      t#]
]PD                  ,          ! ]!4      t$]
]%,          ! ]!4      t&]! ]P                  PN                  4      t(]
]PD                  ,          ! ](4      t)]
]PD                  ,          ! ](4      t*]
]%,          ! ](4      t+]! ]P                  PX                  4      t-]
]PD                  ,          ! ]-4      t.]
]PD                  ,          ! ]-4      t/]
]%,          ! ]-4      t0]! ]P                  Pb                  4      t2]
]PD                  ,          ! ]24      t3]
]PD                  ,          ! ]24      t4]
]%,          ! ]24      t5]6! ]P                  Pn                  4      t8]
]Pr                  ,          ! ]84      t:]
]Pr                  ,          ! ]84      t;]
]<,          ! ]84      t=]6! ]P                  P|                  4      t?]
]Pr                  ,          ! ]?4      t@]
]Pr                  ,          ! ]?4      tA]
]<,          ! ]?4      tB]6! ]P                  P                  4      tD]
]Pr                  ,          ! ]D4      tE]
]Pr                  ,          ! ]D4      tF]
]<,          ! ]D4      tGRtHRtIV 3R lR ltJV 3R lR ltKV 3R ltLR	tMV tNR# )
r   i  zJ
Determine the difference in type enforcement rules
between two policies.
Nc                   < V ^8  d   QhRR/# r   r*   )r$   r%   s   "r&   r'   TERulesDifference.__annotate__  s     < <t <r)   c                   V P                   P                  RV P                   24       \        \        4      V n        V P                  P                  4        F/  pV P
                  VP                  ,          P                  V4       K1  	  V P
                  P                  4        F0  w  r#V P                   P                  R\        V4       RV R24       K2  	  V P                   P                  RV P                   24       \        \        4      V n        V P                  P                  4        F/  pV P                  VP                  ,          P                  V4       K1  	  V P                  P                  4        F0  w  r#V P                   P                  R\        V4       RV R24       K2  	  V P                   P                  R4       R# )z$Create rule lists for both policies.zBuilding TE rule lists from zLoaded  z rules.z!Completed building TE rule lists.N)r   r   r   r   r^   r   terulesr   r   r~   r   r   r   )r   r   r   ruless   &   r&   r   'TERulesDifference._create_te_rule_lists  s]    	5d6F6F5GHI)$/$$,,.D.55d; /  $2288:OHHHNNWSZL(7CD  ; 	5d6G6G5HIJ*40%%--/D  /66t< 0  $3399;OHHHNNWSZL(7CD  < 	:;r)   c                   < V ^8  d   QhRR/# r   r*   )r$   r%   s   "r&   r'   r     s     '$ '$T '$r)   c                    V P                   P                  R4       V =V =V =V =V =V =V =V =	V =
V =V =V =V =V =V =V =V =V =V =V =V =V =V =V =V =V =V =V =V =V =V = V =!V ="RV n#        RV n$        R# )z%Reset diff results on policy changes.zResetting TE rule differencesN)%r   r   added_allowsremoved_allowsmodified_allowsadded_auditallowsremoved_auditallowsmodified_auditallowsadded_neverallowsremoved_neverallowsmodified_neverallowsadded_dontauditsremoved_dontauditsmodified_dontauditsadded_allowxpermsremoved_allowxpermsmodified_allowxpermsadded_auditallowxpermsremoved_auditallowxpermsmodified_auditallowxpermsadded_neverallowxpermsremoved_neverallowxpermsmodified_neverallowxpermsadded_dontauditxpermsremoved_dontauditxpermsmodified_dontauditxpermsadded_type_transitionsremoved_type_transitionsmodified_type_transitionsadded_type_changesremoved_type_changesmodified_type_changesadded_type_membersremoved_type_membersmodified_type_membersr   r   r   s   &r&   _reset_diffTERulesDifference._reset_diff  s    67 "$%"$%!#$"$%')*')*&()')*#%&#%& ##r)   c                   < V ^8  d   Qh/ S[ S[P                  S[P                  3,          ;R&   S[ S[P                  S[P                  3,          ;R&   # )r   r   r   )r   r
   r   	AnyTERule)r$   r%   s   "r&   r'   r     sO     | Y1193F3FFGN} ~ i22I4G4GGHO r)   )r   r   )Or,   r-   r.   r/   r0   r   r
   r   allowdiff_allowsr   r!   r   r   r   r   
auditallowdiff_auditallowsr   r   r   
neverallowdiff_neverallowsr   r   r   	dontauditdiff_dontauditsr   r   r   r   
allowxpermdiff_allowxpermsr9   r   r   r7   r   auditallowxpermdiff_auditallowxpermsr   r   r   neverallowxpermdiff_neverallowxpermsr  r  r  dontauditxpermdiff_dontauditxpermsr  r  r  r   type_transitiondiff_type_transitionsTERuler  r  r=   r	  type_changediff_type_changesr
  r  r  type_memberdiff_type_membersr  r  r  r   r   r   r  r1   r2   r3   r4   s   @r&   r   r     s    
 #9#7#7#=#=>K'	(8(89+FL))*:*:;KHN*>:;GO'	(<(<(G(GH,Y-=-=>?OP.y/?/?@AQR/?@PQ'	(<(<(G(GH,Y-=-=>?OP.y/?/?@AQR/?@PQ&y';';'E'EFO+I,<,<=oN-i.>.>?P.~>O()=)=)H)HI,Y-B-BCDTU.y/D/DEFVW/0CDEUV-i.B.B.R.RS1)2G2GHI^_3I4I4IJK`a 45H IJ_ `-i.B.B.R.RS1)2G2GHI^_3I4I4IJK`a 45H IJ_ `,Y-A-A-P-PQ01F1FGH\]293H3HIJ^_34GHI]^,Y-A-A-Q-QR1)2B2BCDYZ3I4D4DEF[\ 4^ DEZ [()=)=)I)IJ-i.>.>?@QR/	0@0@ABST0@ARS()=)=)I)IJ-i.>.>?@QR/	0@0@ABST0@ARSJNNKOO
< <,'$ '$u  r)   r   c                   L   a  ] tR tRt o RtR
tV 3R lR ltR tR tR t	Rt
V tR	# )r   i$  zEWrap extended permission access vector rules to allow set operations.c                8   < V ^8  d   QhRS[ P                  RR/# )r   r   r]   N)r
   r9   )r$   r%   s   "r&   r'   AVRuleXpermWrapper.__annotate__*  s!      Y22 t r)   c                $   Wn         \        VP                  4      V n        \        VP                  4      V n        \	        VP
                  4      V n        VP                  V n        \        VP                  4      V n        \        V4      V n
        R # r}   )r   r   rh   rj   r   rf   
xperm_typer"   rJ   hashkeyr   r   s   &&r&   __init__AVRuleXpermWrapper.__init__*  s\    24;;?24;;?+DKK8//_
:r)   c                    V P                   # r}   r2  r  s   &r&   __hash__AVRuleXpermWrapper.__hash__3      xxr)   c                4    V P                   VP                   8  # r}   r7  r   others   &&r&   __lt__AVRuleXpermWrapper.__lt__6      xx%))##r)   c                    V P                   VP                   8H  ;'       d\    V P                  VP                  8H  ;'       d;    V P                  VP                  8H  ;'       d    V P                  VP                  8H  # r}   )rh   rj   rf   r0  r<  s   &&r&   __eq__AVRuleXpermWrapper.__eq__9  sk     {{ell* 0 0KK5<<'0 0KK5<<'0 0 OOu///	0r)   )r2  r   rJ   rh   rj   rf   r0  N)rh   rj   rf   r0  rJ   r,   r-   r.   r/   r0   	__slots__r4  r8  r>  rB  r2   r3   r4   s   @r&   r   r   $  s+     OEI $0 0r)   r   c                   @   a  ] tR tRt o RtR	tR tR tR tR t	Rt
V tR# )
r   iB  z*Wrap type_* rules to allow set operations.c                   Wn         \        VP                  4      V n        \        VP                  4      V n        \	        VP
                  4      V n        \        V4      V n         \        VP                  4      V n	        VP                  V n
         VP                  V n        R #   \        P                   d    R T n	        R T n
         L9i ; i  \        P                  \        P                  3 d    R T n         R # i ; ir}   )r   r   rh   rj   r   rf   r1  r2  r   ra   rb   r	   rc   filenameRuleUseErrorTERuleNoFilenamer3  s   &&r&   r4  TERuleWrapper.__init__H  s    24;;?24;;?+DKK8:	*:4;K;KLD%)%;%;D"
	! MMDM ++ 	*#D%)D"	* &&	(B(BC 	! DM	!s$   &+B% C %#C
C,C>=C>c                    V P                   # r}   r7  r  s   &r&   r8  TERuleWrapper.__hash__[  r:  r)   c                4    V P                   VP                   8  # r}   r7  r<  s   &&r&   r>  TERuleWrapper.__lt__^  r@  r)   c                ~   V P                   VP                   8H  ;'       d    V P                  VP                  8H  ;'       d}    V P                  VP                  8H  ;'       d\    V P                  VP                  8H  ;'       d;    V P                  VP                  8H  ;'       d    V P
                  VP
                  8H  # r}   rh   rj   rf   ra   rb   rH  r<  s   &&r&   rB  TERuleWrapper.__eq__a  s     {{ell* , ,KK5<<', ,KK5<<', ,  1 11, , ""e&=&==	, ,
 MMU^^+	,r)   )ra   rb   rH  r2  r   rh   rj   rf   NrQ  rD  r4   s   @r&   r   r   B  s&     4^I!&$, ,r)   r   )9r   collectionsr   collections.abcr   r   dataclassesr   sysr   enumr   r    r	   r
   ra   r   descriptorsr   
differencer   r   r   rk   r   r   r   objclassr   rd   re   r   r7   r=   rD   rH   rP   rT   Conditionalr#   CondExpbool	CondBlockrV   r_   rz   r   r   r   r   r   r   r   r9   r   r   r*   r)   r&   <module>r`     s    # . !    # 4 - = = E  +23 $Vn  $d#%  $ $d#&* & $& $d#$% $ $$4 
      
 ' ' '
 % % % 

#
%3J		gtItCc4EV@V;W6W1X,X'YYZZ	[X[v#\L$$N*Z6-`"JA$
 A$H0!6!67 0<',G ',r)   