Software: Apache/2.0.54 (Unix) mod_perl/1.99_09 Perl/v5.8.0 mod_ssl/2.0.54 OpenSSL/0.9.7l DAV/2 FrontPage/5.0.2.2635 PHP/4.4.0 mod_gzip/2.0.26.1a uname -a: Linux snow.he.net 4.4.276-v2-mono-1 #1 SMP Wed Jul 21 11:21:17 PDT 2021 i686 uid=99(nobody) gid=98(nobody) groups=98(nobody) Safe-mode: OFF (not secure) /usr/local/frontpage/version5.0/ drwxr-xr-x | |
| Viewing file: Select action/file-type: #! /bin/sh
#
# Copyright 1997-2001 Microsoft Corporation -- All Rights Reserved.
#
# $Revision: 1.2 $
# $Date: 2003/02/27 22:07:46 $
#
# This script resets the permission of the current FrontPage
# server extensions tree to the default values. We begin
# changing things at versionX.Y so that none of the .cnf files
# will be changed/compromised.
PATH=".:/bin:/usr/bin:/sbin:/usr/sbin:/usr/ucb:/etc:/usr/bsd"
# process the standard frontpage installation unless indicated
# otherwise on the command line
if [ "$1" = "" ]
then
FPDIR=/usr/local/frontpage/version5.0
else
FPDIR=$1
fi
# come here if we fail at any point
die() {
echo "Aborting, could not successfully $*"
exit 1
}
# Change some of the simple stuff at the top
chown bin $FPDIR `dirname $FPDIR` || die chown top dirs
chgrp bin $FPDIR `dirname $FPDIR` || die chgrp top dirs
chmod 775 $FPDIR `dirname $FPDIR` || die chmod top dirs
chown bin $FPDIR/frontpage.cnf || die chown frontpage.cnf
chgrp bin $FPDIR/frontpage.cnf || die chgrp frontpage.cnf
chmod 664 $FPDIR/frontpage.cnf || die chmod frontpage.cnf
chown bin $FPDIR/*.sh $FPDIR/*.TXT $FPDIR/*.htm || die chown top level files
chgrp bin $FPDIR/*.sh $FPDIR/*.TXT $FPDIR/*.htm || die chgrp top level files
chmod 555 $FPDIR/*.sh || die chmod top level files
chmod 444 $FPDIR/*.TXT $FPDIR/*.htm || die chmod top level files
# Handle all of the non apache-fp directory trees
for dir in bin nls admin exes help ; do
# we want everything owned by user bin, group bin
chown -R bin $FPDIR/$dir ||
die chown $dir to bin
chgrp -R bin $FPDIR/$dir ||
die chgrp $dir to bin
# start with read only permissions and add in what we're missing
chmod -R 444 $FPDIR/$dir ||
die make everything read only in $dir
# directories all get execute/access permission
for i in `find $FPDIR/$dir -type d -print` ; do
chmod a+x $i || die add execute/access permissions to $i
done
# scripts and programs all get execute/access permission
for i in `find $FPDIR/$dir -type f -print` ; do
case "$i" in
*.exe) chmod a+x $i || die set execute permissions for $i ;;
*.sh) chmod a+x $i || die set execute permissions for $i ;;
httpd) chmod a+x $i || die set execute permissions for $i ;;
*) ;;
esac
done
done
# bin/_vti_inf.htm and bin/postinfo.htm need user write permission
chmod u+w $FPDIR/bin/_vti_inf.htm || die chmod write perm on _vti_inf.htm
chmod u+w $FPDIR/bin/postinfo.htm || die chmod write perm on postinfo.htm
# The apache-fp directory tree should be owned by root, group bin
chown -R root $FPDIR/apache-fp || die chown apache-fp
chgrp -R bin $FPDIR/apache-fp || die chgrp apache-fp
# Remove all write/execute permissions
chmod -R ugo-wx,ugo+r $FPDIR/apache-fp
# The apache-fp fpexe stub needs to be suid root
chmod 4755 $FPDIR/apache-fp/_vti_bin/fpexe || die set fpexe to be suid
# Set httpd
chmod 555 $FPDIR/apache-fp/httpd || die make httpd executable
# The apache-fp directory should not be writable to protect the stub program.
chmod 555 $FPDIR/apache-fp/_vti_bin || die restrict the apache-fp directory
# The apache-fp directory should not be group/world readable or writable to
# protect the suidkey.pid files..
chmod 711 $FPDIR/apache-fp || die restrict the apache-fp directory
# The suidkey files should all be completely close to group/world
for i in $FPDIR/apache-fp/suidkey* ; do
if [ -f "$i" ]
then
chmod 600 $i ||
die remove rwx group/world permissions from the suidkey file $i
fi
done
|
:: Command execute :: | |
--[ c99shell v. 1.0 pre-release build #13 powered by Captain Crunch Security Team | http://ccteam.ru | Generation time: 0.0251 ]-- |