Diff for /doc/loncapafiles/sanitycheck.piml between versions 1.5 and 1.6

version 1.5, 2002/08/17 18:59:48 version 1.6, 2002/09/22 08:23:26
Line 33  http://www.lon-capa.org/ Line 33  http://www.lon-capa.org/
 <targetroot>/</targetroot>  <targetroot>/</targetroot>
 <files>  <files>
 <file>  <file>
   <target dist='default'>/var/lib/mysql/mysql.sock</target>
   <perlscript mode='fg'>
   unless
       (-e '<TARGET />') # Does file exist?
     {
       print("**** ERROR **** Missing <TARGET />\n");
     }
   else # It exists, so look at the file metadata more closely.
     {
       my @s = stat('<TARGET />');
       my $uid = $s[4];
       my $mode = $s[2];
       my $web_uid = getpwnam('www');
       my $smode = sprintf("%04o",$mode & 07777);
   
       if ($uid ne $web_uid) # If file owned by someone else other than www.
         {
    print('**** ERROR **** <TARGET /> should be owned by'.
         ' www.'."\n".'Try these commands to make things right:'."\n".
         'chown www:www /var/lib/mysql/mysql.sock'."\n".
         'chmod a-rwx,u+rwx /var/lib/mysql/mysql.sock'."\n");
         }
       else # Check permissions on the file to make sure it is private to apache2.
         {
    $smode =~ /^.(.)..$/;
    my $wflag = $1;
    if ($wflag != 7)
     {
       print('**** ERROR **** '.
         '<TARGET /> should be user "rwx" (by'.
         ' www).'."\n".'Try these commands to make things right:'."\n".
         'chown www:www /var/lib/mysql/mysql.sock'."\n".
         'chmod a-rwx,u+rwx /var/lib/mysql/mysql.sock'."\n");
     }
    $smode=~/^..(..)$/;
    $wflag=$1;
    if ($wflag ne "00")
     {
       print('**** ERROR **** '.
         '<TARGET /> should not be group or everybody accessible'.
         '.'."\n".'Try these commands to make things right:'."\n".
         'chown www:www /var/lib/mysql/mysql.sock'."\n".
         'chmod a-rwx,u+rwx /var/lib/mysql/mysql.sock'."\n");
     }
         }
     }
   </perlscript>
   </file>
   <file>
 <target dist='default'>/etc/httpd/conf/loncapa.conf</target>  <target dist='default'>/etc/httpd/conf/loncapa.conf</target>
 <perlscript mode='fg'>  <perlscript mode='fg'>
 open IN, "&lt;<TARGET />";  open IN, "&lt;<TARGET />";

Removed from v.1.5  
changed lines
  Added in v.1.6


FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>