|
From: Heiko Z. <smi...@us...> - 2008-03-27 14:27:13
|
Update of /cvsroot/devil-linux/build/scripts In directory sc8-pr-cvs12.sourceforge.net:/tmp/cvs-serv25468/scripts Modified Files: Linux-PAM mysql shadow Added Files: dcc libdnet Log Message: - updated razor-agents-2.84.tar.bz2 - updated kernel to 2.6.24.4 - updated pax-linux-2.6.24.4-test36.patch.bz2 - updated gradm-2.1.11-200803102037.tar.gz - updated grsecurity-2.1.11-2.6.24.4-200803251800.patch.bz2 - updated Linux-PAM to 0.99.10.0 - su is now wokring again - updated open-vm-tools to 2008.03.19-82724 - updated shadow 4.1.0 - added libdnet 1.11 - updated pam configurations files from BLFS book - corrected permissions on su and some code cleanup Index: Linux-PAM =================================================================== RCS file: /cvsroot/devil-linux/build/scripts/Linux-PAM,v retrieving revision 1.7 retrieving revision 1.8 diff -u -d -r1.7 -r1.8 --- Linux-PAM 8 Jan 2008 16:21:07 -0000 1.7 +++ Linux-PAM 27 Mar 2008 14:27:03 -0000 1.8 @@ -33,10 +33,11 @@ # # define HOST_NAME_MAX 64 # #endif - replace_str doc/specs/Makefile.am "spec: draft-morgan-pam.raw" "spec: draft-morgan-pam.raw padout" + #replace_str doc/specs/Makefile.am "spec: draft-morgan-pam.raw" "spec: draft-morgan-pam.raw padout" ./configure --enable-static-libpam --with-mailspool=/var/mail \ - --enable-read-both-confs --sysconfdir=/etc --with-cracklib --mandir=/usr/share/man + --enable-read-both-confs --sysconfdir=/etc --with-cracklib --mandir=/usr/share/man \ + --sbindir=/lib/security --enable-securedir=/lib/security --disable-nls make $PMAKE || exit 1 @@ -55,32 +56,20 @@ PAM_OTHER - install -v -m644 /etc/login.defs /etc/login.defs.orig && - for FUNCTION in DIALUPS_CHECK_ENAB FAILLOG_ENAB LASTLOG_ENAB MAIL_CHECK_ENAB \ - OBSCURE_CHECKS_ENAB PORTTIME_CHECKS_ENAB QUOTAS_ENAB MOTD_FILE \ - FTMP_FILE NOLOGINS_FILE NOLOGIN_STR ENV_HZ PASS_MIN_LEN SU_WHEEL_ONLY \ - CRACKLIB_DICTPATH PASS_CHANGE_TRIES PASS_ALWAYS_WARN CHFN_AUTH ENVIRON_FILE - do - sed -i -e "s/^$FUNCTION/# &/" /etc/login.defs - done - ;; - install ) - cp -a /lib/libpam*.so* $CDDIR/lib || exit 1 - cp -aR /lib/security $CDDIR/lib/ || exit 1 -# cp -aR /lib/cracklib $CDDIR/lib/ || exit 1 - find $CDDIR/lib/security/ -type f -name '*la' -exec rm -f {} \; - cp -aR /etc/security $ETCDIR/etc/ || exit 1 - cp -a /etc/environment $ETCDIR/etc/ || exit 1 + install ) + rm -rf $TMPDIR + make install DESTDIR=$TMPDIR || exit 1 + copy_docs $TMPDIR || exit 1 + rm -rf $TMPDIR/usr/include || exit 1 + find $TMPDIR/lib/security/ -type f -name '*la' -exec rm -f {} \; + cp -vdpR $TMPDIR/etc/* $ETCDIR/etc/ || exit 1 + rm -rf $TMPDIR/etc + cp -vdpR $TMPDIR/* $CDDIR || exit 1 + rm -rf $TMPDIR + ;; - for (( a=1; a <= 8 ; a++ )) - do - cp -a doc/man/*.$a $CDDIR/usr/share/man/man$a/ - done - - - ;; * ) echo "ERROR ($0)" echo "please add parameter so I know what to do" Index: shadow =================================================================== RCS file: /cvsroot/devil-linux/build/scripts/shadow,v retrieving revision 1.25 retrieving revision 1.26 diff -u -d -r1.25 -r1.26 --- shadow 16 Feb 2006 16:37:37 -0000 1.25 +++ shadow 27 Mar 2008 14:27:03 -0000 1.26 @@ -10,7 +10,7 @@ ### BEGIN INIT INFO # Provides: shadow -# Required-Start: $basebuildtools $libs Linux-PAM +# Required-Start: $basebuildtools $libs Linux-PAM cracklib # Required-Stop: # Default-Start: 1 2 # Default-Stop: @@ -26,13 +26,15 @@ case $1 in build ) ./configure --prefix=/usr --disable-nls --with-gnu-ld --enable-shared --enable-shadowgrp \ - --without-selinux --with-libpam --without-libcrack || exit 1 + --without-selinux --with-libpam --with-libcrack --sysconfdir=/etc || exit 1 make $PMAKE || exit 1 strip_debug # we need this stuff later make install || exit 1 + + useradd -D -b /home -g 100 && sed -i 's/yes/no/' /etc/default/useradd ;; install ) @@ -44,29 +46,56 @@ rm -rf $TMPDIR || exit 1 mkdir -p $TMPDIR || exit 1 make DESTDIR=$TMPDIR install || exit 1 - chmod 700 $TMPDIR/bin/login || exit 1 - chmod 4550 $TMPDIR/bin/su || exit 1 - chgrp wheel $TMPDIR/bin/su || exit 1 - chmod -c go-rx $TMPDIR/usr/sbin/{chpasswd,group*,grp[cu]*,logoutd,newusers,pw[cu]*,user*} || exit 1 - copy_man ./man + + #chmod -c go-rx $TMPDIR/usr/sbin/{chpasswd,group*,grp[cu]*,logoutd,newusers,pw[cu]*,user*} || exit 1 + + copy_man $TMPDIR + rm -rf $TMPDIR/usr/share rm -rf $TMPDIR/lib/*.a - rm -rf $TMPDIR/lib/*.la - cp -dpR etc/{limits,login.access,login.def*,useradd} $ETCDIR/etc/ || exit 1 -# sed 's%^#MD5_CRYPT_ENAB.*no%MD5_CRYPT_ENAB yes%' etc/login.defs > $ETCDIR/etc/login.defs && - - for FUNCTION in FAILLOG_ENAB LASTLOG_ENAB MAIL_CHECK_ENAB OBSCURE_CHECKS_ENAB PORTTIME_CHECKS_ENAB \ - QUOTAS_ENAB MOTD_FILE FTMP_FILE NOLOGINS_FILE ENV_HZ PASS_MIN_LEN SU_WHEEL_ONLY \ - CRACKLIB_DICTPATH PASS_CHANGE_TRIES PASS_ALWAYS_WARN CHFN_AUTH ENVIRON_FILE MD5_CRYPT_ENAB - do - sed -i -e "s/^$FUNCTION/# &/" $ETCDIR/etc/login.defs - echo "sed -i -e \"s/^$FUNCTION/# &/\" $ETCDIR/etc/login.defs" - done || exit 1 - + rm -rf $TMPDIR/lib/*.la rm -rf $TMPDIR/usr/share || exit 1 - rm -rf $TMPDIR/lib || exit 1 - cp -dpR $TMPDIR/* $CDDIR/ || exit 1 + + # we don't want the pam config files from shadow for now + rm -rf $TMPDIR/etc/pam.d + + cp -vdpR $TMPDIR/etc/* $ETCDIR/etc/ || exit 1 + rm -rf $TMPDIR/etc + cp -vdpR $TMPDIR/* $CDDIR/ || exit 1 rm -rf $TMPDIR || exit 1 + + # change group first, otherwise permissions get reset + chgrp wheel $CDDIR/bin/su || exit 1 + chmod 4550 $CDDIR/bin/su || exit 1 + + mkdir -p $ETCDIR/etc/default || exit 1 + + #cp -vdpR etc/{limits,login.access,login.def*,useradd} $ETCDIR/etc/ || exit 1 + test -f $ETCDIR/etc/login.access && mv $ETCDIR/etc/login.access $ETCDIR/etc/login.access.usePAMinsted + test -f $ETCDIR/etc/limits && mv $ETCDIR/etc/limits $ETCDIR/etc/limits.usePAMinsted + chmod 644 $ETCDIR/etc/login.* || exit 1 + + cp /data/build/tmp/ETC/etc/login.defs /data/build/tmp/ETC/etc/login.defs.orig + for FUNCTION in LASTLOG_ENAB MAIL_CHECK_ENAB \ + PORTTIME_CHECKS_ENAB CONSOLE \ + MOTD_FILE NOLOGINS_FILE PASS_MIN_LEN \ + SU_WHEEL_ONLY MD5_CRYPT_ENAB \ + CONSOLE_GROUPS ENVIRON_FILE \ + ULIMIT ENV_TZ ENV_HZ ENV_SUPATH \ + ENV_PATH QMAIL_DIR MAIL_DIR MAIL_FILE \ + CHFN_AUTH FAILLOG_ENAB QUOTAS_ENAB FTMP_FILE \ + OBSCURE_CHECKS_ENAB CRACKLIB_DICTPATH \ + PASS_CHANGE_TRIES PASS_ALWAYS_WARN ISSUE_FILE + do + sed -i "s/^$FUNCTION/# &/" $ETCDIR/etc/login.defs + done + + useradd -D -b /home -g 100 + useradd -D | sed 's/yes/no/' > $ETCDIR/etc/default/useradd || exit 1 + ENV_PATH=`grep '^ENV_PATH' $ETCDIR/etc/login.defs.orig awk '{ print $2 }' | sed 's/PATH=//'` + echo 'PATH DEFAULT='`echo "${ENV_PATH}"`\ +' OVERRIDE=${PATH}' >> $ETCDIR/etc/security/pam_env.conf || exit 1 + unset ENV_PATH ;; * ) --- NEW FILE: libdnet --- #!/bin/bash # you need the next line, otherwise script won't be executed !!! # DL-build-system v3 ### BEGIN INIT INFO # Provides: libdnet # Required-Start: $basebuildtools glibc libpcap # Required-Stop: # Default-Start: 1 # Default-Stop: # Description: description ### END INIT INFO # get the directoryname of the script MYDIR=${0%/*} # source functions and config source $MYDIR/settings case $1 in build ) ./configure --prefix=/usr || exit 1 make $PMAKE all || exit 1 strip_debug # install it in local system, because other programs could need it make install ;; * ) echo "ERROR ($0)" echo "please add parameter so I know what to do" exit 1 ;; esac --- NEW FILE: dcc --- #!/bin/bash # $Source: /cvsroot/devil-linux/build/scripts/dcc,v $ # $Revision: 1.1 $ # $Date: 2008/03/27 14:27:03 $ # # http://www.devil-linux.org # you need the next line, otherwise script won't be executed !!! # DL-build-system v3 ### BEGIN INIT INFO # Provides: dcc # Required-Start: $basebuildtools $libs postfix procmail # Required-Stop: # Default-Start: 1 2 # Default-Stop: # Description: description ### END INIT INFO # get the directoryname of the script MYDIR=${0%/*} MYSCRIPT=${0##/*/} # source functions and config source $MYDIR/settings MYNAME=DCC case $1 in build ) if [ "$CONFIG_DCC" = "y" ]; then rm -rf $TMPDIR mkdir -p $TMPDIR || exit 1 echo $TMPDIR > .tmpdir ./configure --bindir=/usr/bin --libexecdir=/usr/libexec --mandir=/usr/share/man --with-rundir=/var/run --with-installroot=$TMPDIR || exit 1 make $PMAKE all || exit 1 strip_debug fi ;; install ) if [ "$CONFIG_DCC" = "y" ]; then TMPDIR=$(cat .tmpdir) rm -rf $TMPDIR || exit 1 mkdir -p $TMPDIR/var/dcc || exit 1 # we need the next line to make the install script happy mkdir -p /var/dcc make install || exit 1 copy_docs $TMPDIR cp -dvpR $TMPDIR/* $CDDIR/ || exit 1 rm -rf $TMPDIR || exit 1 fi ;; * ) echo "ERROR ($0)" echo "please add parameter so I know what to do" exit 1 ;; esac Index: mysql =================================================================== RCS file: /cvsroot/devil-linux/build/scripts/mysql,v retrieving revision 1.22 retrieving revision 1.23 diff -u -d -r1.22 -r1.23 --- mysql 10 Aug 2005 13:48:50 -0000 1.22 +++ mysql 27 Mar 2008 14:27:03 -0000 1.23 @@ -61,6 +61,8 @@ copy_files $TMPDIR/usr $CDDIR || exit 1 rm -rf $TMPDIR || exit 1 + groupdel mysql + userdel mysql groupadd -g 46 mysql || exit 1 useradd -u 46 -g mysql -s /bin/false mysql || exit 1 |