;ò
–Áƒ@c           @   s  d  k  Td k Z d k Z d k Z d k Z d k Z d k Z d k Z d d d d f Z e	 i
 d d ƒ Z e	 i
 d e ƒ Z e i d	 e i ƒ Z e i d
 e i ƒ Z e i d e i ƒ Z e i d e i ƒ Z e i d e i ƒ Z e i d ƒ Z e i d e i ƒ Z e i d e i ƒ Z e i d ƒ Z e i d ƒ Z d d d f g d d f g f Z x/ e D]' Z e i d e d e i ƒ e d <qdWd „  Z d „  Z d e i f d „  ƒ  YZ e ƒ  Z e	 i o; e  d d d d d  d! d" d# d$ d% d& d' d( d) d* d+ ƒ n d S(,   (   s   *Ns   /bin/shs	   /bin/bashs
   /sbin/sashs   /usr/bin/perls
   ExtractDirs   /tmps   ValidShellss   ^[^#]*%s   %%s   ^[^#]*if.*[^ :\]]\]s   [^a-zA-Z]+~/|\$HOMEsF   (^|\s|;|/bin/|\|)(cp|mv|ln|tar|rpm|chmod|chown|rm|cpio|install|perl)\ss   ^[ 
]*([^ 
]+)[ 
]*$s   update-menuss   \s(/var)?/tmps#   ^/usr/lib/menu/|^/etc/menu-methods/s   (\${?RPM_BUILD_(ROOT|DIR)}?)s   chkfontpaths   /usr/sbin/chkfontpaths
   rpm-helpers   ^[^#]+i    c         C   sx   d t  t i ƒ  f } |  o d Sn t | d ƒ } | i |  ƒ | i ƒ  t	 i
 d | ƒ } t i | ƒ | d Sd  S(   Ns   %s/.bash-script.%di    s   ws   /bin/bash -n %s(   s   extract_dirs   oss   getpids   tmpfiles   shellscripts   opens   files   writes   closes   commandss   getstatusoutputs   rets   remove(   s   shellscripts   tmpfiles   rets   file(    (    s   /usr/share/rpmlint/PostCheck.pys   incorrect_shell_script1   s    
c         C   sx   d t  t i ƒ  f } |  o d Sn t | d ƒ } | i |  ƒ | i ƒ  t	 i
 d | ƒ } t i | ƒ | d Sd  S(   Ns   %s/.perl-script.%di    s   ws   /usr/bin/perl -wc %s(   s   extract_dirs   oss   getpids   tmpfiles
   perlscripts   opens   files   writes   closes   commandss   getstatusoutputs   rets   remove(   s
   perlscripts   tmpfiles   rets   file(    (    s   /usr/share/rpmlint/PostCheck.pys   incorrect_perl_script<   s    
s	   PostCheckc           B   s#   t  Z d „  Z d „  Z d „  Z RS(   Nc         C   s   t  i  i |  d ƒ d  S(   Ns	   PostCheck(   s   AbstractChecks   __init__s   self(   s   self(    (    s   /usr/share/rpmlint/PostCheck.pys   __init__I   s    c      	   C   s  | i ƒ  o d  Sn d } t d „  | i ƒ  ƒ } | i ƒ  i ƒ  } xþ t i t i	 d f t i
 t i d f t i t i d f t i t i d f t i t i d f f D]œ }	 | |	 d } | |	 d } t | ƒ t i j o  |  i | | | | |	 | ƒ q¦ xA t d t | ƒ ƒ D]* } |  i | | | | | | |	 | ƒ qWq¦ W| i ƒ  }
 |
 o¦ | t i
 } | t i } | o | o t! | d	 ƒ qÿxh |
 D]\ } | p t# i$ | | ƒ d
 j o | p t# i$ | | ƒ d
 j o t! | d | ƒ q›q›Wn d  S(   Ni    c         C   s   |  d S(   Ni    (   s   x(   s   x(    (    s   /usr/share/rpmlint/PostCheck.pys   <lambda>R   s    s   %pres   %posts   %preuns   %postuns   %triggeri   s   ghost-files-without-postiniÿÿÿÿs"   postin-without-ghost-file-creation(%   s   pkgs   isSources
   menu_errors   maps   prereqs   filess   keyss   rpms   RPMTAG_PREINs   RPMTAG_PREINPROGs   RPMTAG_POSTINs   RPMTAG_POSTINPROGs   RPMTAG_PREUNs   RPMTAG_PREUNPROGs   RPMTAG_POSTUNs   RPMTAG_POSTUNPROGs   RPMTAG_TRIGGERSCRIPTSs   RPMTAG_TRIGGERSCRIPTPROGs   tags   scripts   progs   types   typess   ListTypes   selfs	   check_auxs   ranges   lens   idxs
   ghostFiless   ghost_filess   postins   preins   printWarnings   fs   strings   find(   s   selfs   pkgs
   menu_errors   preins   fs   idxs   scripts   prereqs   postins   tags   ghost_filess   progs   files(    (    s   /usr/share/rpmlint/PostCheck.pys   checkL   s0    a   , Bc         C   si  | o8| o. | t j o t | d | d | ƒ q< n | d j p | d j p
 | d j o¾t i | ƒ o t i | ƒ o t	 | d | d ƒ n t
 i | ƒ o t	 | d | d ƒ n t i | ƒ } | o% t	 | d | d | i d ƒ ƒ n t i | ƒ oV d	 } x) | D]! }
 t i |
 ƒ o d
 } PqqW| o t | d | d ƒ qgn t i | ƒ o t | d | d ƒ n xŽ t D]‚ }	 |	 d
 i | ƒ oh d
 } x7 |	 d	 D]+ } | | j p
 | | j o d	 } PqÂqÂW| o t | d |	 d	 d
 ƒ qq—q—Wn | d j p
 | d j oŽ t | ƒ o t | d | d ƒ n t i | ƒ o t | d | d ƒ n t i | ƒ } | o% t	 | d | d | i d	 ƒ ƒ qÉn | d j o* t | ƒ o t | d | d ƒ q n t i | ƒ } | o% t	 | d | d | i d	 ƒ ƒ qen' | t j o t	 | d | d ƒ n d  S(   Ns   invalid-shell-in-i   s   /bin/shs	   /bin/bashs   /usr/bin/perls   percent-in-s   spurious-bracket-in-s   dangerous-command-in-i   i    s"   update-menus-without-menu-file-in-s   use-tmp-in-s   no-prereq-ons   shell-syntax-error-in-s   use-of-home-in-s   bogus-variable-use-in-s   perl-syntax-error-in-s   one-line-command-in-s   empty-(   s   scripts   progs   valid_shellss
   printErrors   pkgs   tags   braces_regexs   searchs   double_braces_regexs   printWarnings   bracket_regexs   dangerous_command_regexs   ress   groups   update_menu_regexs
   menu_errors   filess   fs
   menu_regexs	   tmp_regexs   prereq_assocs   cs   founds   ps   prereqs   incorrect_shell_scripts
   home_regexs   bogus_var_regexs   incorrect_perl_scripts   single_command_regex(   s   selfs   pkgs   filess   progs   scripts   tags   prereqs
   menu_errors   ress   cs   fs   ps   found(    (    s   /usr/share/rpmlint/PostCheck.pys	   check_auxp   sd     '!% 	  	())(   s   __name__s
   __module__s   __init__s   checks	   check_aux(    (    (    s   /usr/share/rpmlint/PostCheck.pys	   PostCheckG   s   		$s   one-line-command-in-%posts×   You should use %post -p <command> instead of using:

%post
<command>

It will avoid the fork of a shell interpreter to execute your command as
well as allows rpm to automatically mark the dependency on your command.s   one-line-command-in-%postunsÛ   You should use %postun -p <command> instead of using:

%postun
<command>

It will avoid the fork of a shell interpreter to execute your command as
well as allows rpm to automatically mark the dependency on your command.s   one-line-command-in-%presÕ   You should use %pre -p <command> instead of using:

%pre
<command>

It will avoid the fork of a shell interpreter to execute your command as
well as allows rpm to automatically mark the dependency on your command.s   one-line-command-in-%preunsÙ   You should use %preun -p <command> instead of using:

%preun
<command>

It will avoid the fork of a shell interpreter to execute your command as
well as allows rpm to automatically mark the dependency on your command.s   spurious-bracket-in-%presO   The %pre scriptlet contains an if [] construction without a space before the
].s   spurious-bracket-in-%postsP   The %post scriptlet contains an if [] construction without a space before the
].s   spurious-bracket-in-%preunsQ   The %preun scriptlet contains an if [] construction without a space before the
].s   spurious-bracket-in-%postunsR   The %postun scriptlet contains an if [] construction without a space before the
].(!   s   Filters   AbstractChecks   rpms   res   oss   commandss   strings   typess   DEFAULT_VALID_SHELLSs   Configs	   getOptions   extract_dirs   valid_shellss   compiles	   MULTILINEs   braces_regexs   double_braces_regexs   bracket_regexs
   home_regexs   dangerous_command_regexs   single_command_regexs   update_menu_regexs	   tmp_regexs
   menu_regexs   bogus_var_regexs   prereq_assocs   ps   incorrect_shell_scripts   incorrect_perl_scripts	   PostChecks   checks   infos
   addDetails(   s   braces_regexs   DEFAULT_VALID_SHELLSs   single_command_regexs   dangerous_command_regexs
   menu_regexs   checks   prereq_assocs   valid_shellss   double_braces_regexs
   home_regexs   rpms   update_menu_regexs   res   strings   bogus_var_regexs	   PostChecks   incorrect_shell_scripts   typess   commandss   bracket_regexs   extract_dirs   ps   incorrect_perl_scripts	   tmp_regexs   oss   AbstractCheck(    (    s   /usr/share/rpmlint/PostCheck.pys   ?   sZ   							! %		_	
