wok-6.x rev 11595
dropbear-pam: wanted dropbear
author | Pascal Bellard <pascal.bellard@slitaz.org> |
---|---|
date | Fri Jan 13 11:41:34 2012 +0100 (2012-01-13) |
parents | 3b8e288fd269 |
children | 5ee7ba5d5f57 |
files | dropbear-pam/receipt dropbear/receipt |
line diff
1.1 --- a/dropbear-pam/receipt Fri Jan 13 10:58:50 2012 +0100 1.2 +++ b/dropbear-pam/receipt Fri Jan 13 11:41:34 2012 +0100 1.3 @@ -5,76 +5,19 @@ 1.4 CATEGORY="security" 1.5 SHORT_DESC="Light SSH client and server using PAM." 1.6 MAINTAINER="pascal.bellard@slitaz.org" 1.7 -SOURCE="dropbear" 1.8 -TARBALL="$SOURCE-$VERSION.tar.gz" 1.9 -DEPENDS="zlib pam" 1.10 -BUILD_DEPENDS="zlib zlib-dev pam pam-dev" 1.11 -SUGGESTED="sftp-server" 1.12 +WANTED="dropbear" 1.13 +DEPENDS="dropbear pam" 1.14 WEB_SITE="http://matt.ucc.asn.au/dropbear/dropbear.html" 1.15 -WGET_URL="http://matt.ucc.asn.au/dropbear/releases/$TARBALL" 1.16 -CONFIG_FILES="/etc/dropbear" 1.17 PROVIDE="dropbear:pam ssh:pam" 1.18 1.19 -# Rules to configure and make the package. 1.20 -compile_rules() 1.21 -{ 1.22 - local i 1.23 - local DROPBEARS 1.24 - DROPBEARS="dropbearkey dropbearconvert dbclient scp" 1.25 - cd $src 1.26 - rm -rf _pkg 1.27 - sed -i -e 's|/usr/X11R6/bin/xauth|/usr/bin/xauth|' \ 1.28 - -e 's|/usr/libexec/sftp-server|/usr/sbin/sftp-server|' \ 1.29 - -e 's|ENABLE_SVR_PASSWORD_AUTH|ENABLE_SVR_PAM_AUTH|' \ 1.30 - options.h 1.31 - ./configure --prefix=/usr --enable-pam $CONFIGURE_ARGS && 1.32 - make PROGRAMS="dropbear $DROPBEARS" MULTI=1 && 1.33 - install -d -m 755 $DESTDIR/usr/sbin && 1.34 - install -m 755 dropbearmulti $DESTDIR/usr/sbin/dropbear && 1.35 - chown root $DESTDIR/usr/sbin/dropbear && 1.36 - chgrp 0 $DESTDIR/usr/sbin/dropbear && 1.37 - install -d -m 755 $DESTDIR/usr/bin && 1.38 - for i in $DROPBEARS ssh; do 1.39 - ln -s ../sbin/dropbear $DESTDIR/usr/bin/$i 1.40 - done 1.41 -} 1.42 - 1.43 # Rules to gen a SliTaz package suitable for Tazpkg. 1.44 genpkg_rules() 1.45 { 1.46 - mkdir -p $fs/usr 1.47 - cp -a $_pkg/usr/bin $fs/usr 1.48 - cp -a $_pkg/usr/sbin $fs/usr 1.49 - # Config file and init script. 1.50 - mkdir -p $fs/etc 1.51 - cp -a ../$SOURCE/stuff/dropbear $fs/etc 1.52 - cp -a ../$SOURCE/stuff/init.d $fs/etc 1.53 - cp -a ../$SOURCE/stuff/sshx $fs/usr/bin 1.54 - cp -a $stuff/pam.d $fs/etc 1.55 - touch $fs/etc/dropbear/dropbear_dss_host_key \ 1.56 - $fs/etc/dropbear/dropbear_rsa_host_key 1.57 - 1.58 - # Fix dropbear initscript perms 1.59 - chown -R root.root $fs 1.60 + mkdir -p $fs/usr/sbin 1.61 + cp -a $_pkg/usr/sbin/dropbear-pam $fs/usr/sbin/dropbear 1.62 } 1.63 1.64 -# Post message when installing. 1.65 -post_install() 1.66 +post_remove() 1.67 { 1.68 - while read dropbear openssh ; do 1.69 - [ -s $openssh ] || continue 1.70 - dropbearconvert openssh dropbear $1$openssh $1$dropbear 1.71 - dropbearkey -y -f $1$dropbear | grep Fingerprint 1.72 - done <<EOT 1.73 -/etc/dropbear/dropbear_rsa_host_key /etc/ssh/ssh_host_rsa_key 1.74 -/etc/dropbear/dropbear_dss_host_key /etc/ssh/ssh_host_dsa_key 1.75 -EOT 1.76 - echo -e "\nTo starts $SOURCE server you can run :\n" 1.77 - echo "/etc/init.d/$SOURCE start" 1.78 - echo -e "Or add $SOURCE to RUN_DAEMONS in /etc/rcS.conf\n" 1.79 + tazpkg get-install ${PACKAGE%-pam} --forced 1.80 } 1.81 - 1.82 -pre_remove() 1.83 -{ 1.84 - tazpkg get-install ${PACKAGE%-pam} 1.85 -}
2.1 --- a/dropbear/receipt Fri Jan 13 10:58:50 2012 +0100 2.2 +++ b/dropbear/receipt Fri Jan 13 11:41:34 2012 +0100 2.3 @@ -7,7 +7,7 @@ 2.4 MAINTAINER="pascal.bellard@slitaz.org" 2.5 TARBALL="$PACKAGE-$VERSION.tar.gz" 2.6 DEPENDS="zlib" 2.7 -BUILD_DEPENDS="zlib-dev" 2.8 +BUILD_DEPENDS="zlib zlib-dev pam pam-dev" 2.9 SUGGESTED="sftp-server" 2.10 WEB_SITE="http://matt.ucc.asn.au/dropbear/dropbear.html" 2.11 WGET_URL="http://matt.ucc.asn.au/dropbear/releases/$TARBALL" 2.12 @@ -24,6 +24,7 @@ 2.13 cd $src 2.14 sed -i -e 's|/usr/.*/xauth|/usr/bin/xauth|' \ 2.15 -e 's|/usr/.*/sftp-server|/usr/sbin/sftp-server|' \ 2.16 + -e 's|ENABLE_SVR_PAM_AUTH|ENABLE_SVR_PASSWORD_AUTH|' \ 2.17 options.h 2.18 ./configure --prefix=/usr --without-pam $CONFIGURE_ARGS && 2.19 make PROGRAMS="dropbear $DROPBEARS" MULTI=1 && 2.20 @@ -31,6 +32,13 @@ 2.21 install -m 755 dropbearmulti $DESTDIR/usr/sbin/dropbear && 2.22 chown root $DESTDIR/usr/sbin/dropbear && 2.23 chgrp 0 $DESTDIR/usr/sbin/dropbear && 2.24 + sed -i 's|ENABLE_SVR_PASSWORD_AUTH|ENABLE_SVR_PAM_AUTH|' \ 2.25 + options.h 2.26 + ./configure --prefix=/usr --enable-pam $CONFIGURE_ARGS && 2.27 + make PROGRAMS="dropbear $DROPBEARS" MULTI=1 && 2.28 + install -m 755 dropbearmulti $DESTDIR/usr/sbin/dropbear-pam && 2.29 + chown root $DESTDIR/usr/sbin/dropbear-pam && 2.30 + chgrp 0 $DESTDIR/usr/sbin/dropbear-pam && 2.31 install -d -m 755 $DESTDIR/usr/bin && 2.32 for i in $DROPBEARS ssh; do 2.33 ln -s ../sbin/dropbear $DESTDIR/usr/bin/$i 2.34 @@ -43,6 +51,7 @@ 2.35 mkdir -p $fs/usr 2.36 cp -a $_pkg/usr/bin $fs/usr 2.37 cp -a $_pkg/usr/sbin $fs/usr 2.38 + rm -f $fs/usr/sbin/dropbear-pam 2.39 # Config file and init script. 2.40 mkdir -p $fs/etc 2.41 cp -a $stuff/dropbear $fs/etc