MD5 aa5bb13b4847f4e0031a5246186a9588 scponly-4.6-r1.ebuild 4164
RMD160 36c088bc958f9f34ec6f9ed1e1abd9c2b20dcfbb scponly-4.6-r1.ebuild 4164
SHA256 50a0fb0ec55dd82fca9895a115954d4a2478c6dbccf72804115ab20973251352 scponly-4.6-r1.ebuild 4164
-MISC ChangeLog 4013 RMD160 ebf867c8185629f8f9cc605947b6578b00b47673 SHA1 7dbd3d5a9fbf0bd48077ed27fe8edd2886d532a2 SHA256 969fe88b6b5d75de6d677e965cd23ebcb27d430536fff3f1018dd74dd73c343c
-MD5 bd0ee7c5980e300e9d13758deffac2c7 ChangeLog 4013
-RMD160 ebf867c8185629f8f9cc605947b6578b00b47673 ChangeLog 4013
-SHA256 969fe88b6b5d75de6d677e965cd23ebcb27d430536fff3f1018dd74dd73c343c ChangeLog 4013
+EBUILD scponly-4.6-r2.ebuild 4017 RMD160 5f920eec41d935e0315589fc399bece8162edd9f SHA1 d072d800562c989969d9e24b9188b96473f68bdc SHA256 b024595847ea3cdd706e3e2fa4816cadf44f8549df0653966a67445fbea85525
+MD5 5900b2f3c3ac2a91f91c00f4034eb8ec scponly-4.6-r2.ebuild 4017
+RMD160 5f920eec41d935e0315589fc399bece8162edd9f scponly-4.6-r2.ebuild 4017
+SHA256 b024595847ea3cdd706e3e2fa4816cadf44f8549df0653966a67445fbea85525 scponly-4.6-r2.ebuild 4017
+MISC ChangeLog 4161 RMD160 c4323bdc434683bb68ec1c4a4d397d823bd5ec48 SHA1 005c5419c70b8f92f2837224aa3b69a5b89d02ba SHA256 c255188a58c18f879ff1fd9cc3ce7cb4618dadadf2649a750ae0b707902a8f51
+MD5 038532d37eed4d7083e0a151aa745b82 ChangeLog 4161
+RMD160 c4323bdc434683bb68ec1c4a4d397d823bd5ec48 ChangeLog 4161
+SHA256 c255188a58c18f879ff1fd9cc3ce7cb4618dadadf2649a750ae0b707902a8f51 ChangeLog 4161
MISC metadata.xml 201 RMD160 d72cb3677f941247cced43c6670a8d64642d5263 SHA1 552087b28a02c98c8c2426f5cab77d1089527572 SHA256 90b7d63705a9ef11d62f6fe39fe9e780d9e249d32c6b7b564ff05b818aa1f7f7
MD5 e10a0da4fac2882942ffa8360ccdd921 metadata.xml 201
RMD160 d72cb3677f941247cced43c6670a8d64642d5263 metadata.xml 201
MD5 1608ee46d01cebc4e9702f6eb819d184 files/digest-scponly-4.6-r1 223
RMD160 d66fccafddfaf4df2cf951828b83c14ef666a7dc files/digest-scponly-4.6-r1 223
SHA256 b0f8518cea81ae04a0fcf666acf00ec50e751579462104854362e3112eb4adac files/digest-scponly-4.6-r1 223
+MD5 1608ee46d01cebc4e9702f6eb819d184 files/digest-scponly-4.6-r2 223
+RMD160 d66fccafddfaf4df2cf951828b83c14ef666a7dc files/digest-scponly-4.6-r2 223
+SHA256 b0f8518cea81ae04a0fcf666acf00ec50e751579462104854362e3112eb4adac files/digest-scponly-4.6-r2 223
--- /dev/null
+# Copyright 1999-2007 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/net-misc/scponly/scponly-4.6-r2.ebuild,v 1.1 2007/04/23 13:20:41 matsuu Exp $
+
+inherit eutils
+
+DESCRIPTION="A tiny pseudoshell which only permits scp and sftp"
+HOMEPAGE="http://www.sublimation.org/scponly/"
+SRC_URI="http://www.sublimation.org/scponly/${P}.tgz"
+
+LICENSE="as-is"
+SLOT="0"
+KEYWORDS="~amd64 ~ppc ~sparc ~x86"
+IUSE="subversion"
+
+DEPEND="virtual/libc
+ net-misc/openssh
+ subversion? ( dev-util/subversion )"
+
+myuser="scponly"
+myhome="/home/${myuser}"
+
+src_unpack() {
+ unpack ${A}
+ cd "${S}"
+ # Bug 125796
+ epatch "${FILESDIR}"/${P}-helper.patch
+}
+
+src_compile() {
+ PATH="${PATH}:/usr/$(get_libdir)/misc" \
+ econf \
+ --enable-scp-compat \
+ --enable-winscp-compat \
+ --enable-rsync-compat \
+ --enable-chrooted-binary \
+ $(use_enable subversion svn-compat) \
+ $(use_enable subversion svnserv-compat) \
+ || die "./configure failed"
+ emake || die
+}
+
+src_install() {
+ make DESTDIR="${D}" install || die
+
+ dodoc AUTHOR BUILDING-JAILS.TXT CHANGELOG CONTRIB README TODO
+ dodoc setup_chroot.sh
+}
+
+pkg_postinst() {
+ einfo "You might want to run:"
+ einfo "\"emerge --config =${CATEGORY}/${PF}\""
+ einfo "to setup the chroot."
+ einfo "Otherwise you will have to setup chroot manually."
+
+ # two slashes ('//') are used by scponlyc to determine the chroot point.
+ enewgroup ${myuser}
+ enewuser ${myuser} -1 /usr/sbin/scponlyc ${myhome}// ${myuser}
+}
+
+pkg_config() {
+ # pkg_postinst is based on ${S}/setup_chroot.sh.
+
+ einfo "Updating /etc/shells"
+ { grep -v "^/usr/bin/scponly$" /etc/shells;
+ echo "/usr/bin/scponly"
+ } > ${T}/shells
+ cp ${T}/shells /etc/shells
+
+ { grep -v "^/usr/sbin/scponlyc$" /etc/shells;
+ echo "/usr/sbin/scponlyc"
+ } > ${T}/shells
+ cp ${T}/shells /etc/shells
+
+ BINARIES="/usr/$(get_libdir)/misc/sftp-server /bin/ls /usr/bin/scp /bin/rm /bin/ln /bin/mv /bin/chmod /bin/chown /bin/chgrp /bin/mkdir /bin/rmdir /bin/pwd /bin/groups /usr/bin/ld /bin/echo /usr/bin/rsync"
+ if built_with_use ${PN} subversion; then
+ BINARIES="$BINARIES /usr/bin/svn /usr/bin/svnserve"
+ fi
+ LIB_LIST=`ldd $BINARIES 2> /dev/null | cut -f2 -d\> | cut -f1 -d\( | grep "^[ ]" | sort -u`
+ LDSO_LIST="/$(get_libdir)/ld.so /libexec/ld-elf.so /libexec/ld-elf.so.1 /usr/libexec/ld.so /$(get_libdir)/ld-linux.so.2 /usr/libexec/ld-elf.so.1"
+ for lib in $LDSO_LIST; do
+ if [ -f $lib ]; then
+ LIB_LIST="$LIB_LIST $lib"
+ fi
+ done
+ ls /$(get_libdir)/libnss_compat* > /dev/null 2>&1
+ if [ $? -eq 0 ]; then
+ LIB_LIST="$LIB_LIST /$(get_libdir)/libnss_compat*"
+ fi
+
+ ldconfig
+ LIB_LIST="$LIB_LIST /etc/ld.so.cache /etc/ld.so.conf"
+
+ if [ ! -d ${myhome} ]; then
+ install -c -d ${myhome}
+ chmod 755 ${myhome}
+ fi
+ if [ ! -d ${myhome} ]; then
+ install -c -d ${myhome}/etc
+ chown 0:0 ${myhome}/etc
+ chmod 755 ${myhome}/etc
+ fi
+ if [ ! -d ${myhome}/$(get_libdir) ]; then
+ install -c -d ${myhome}/$(get_libdir)
+ chmod 755 ${myhome}/$(get_libdir)
+ fi
+ if [ ! -d ${myhome}/lib ]; then
+ ln -s $(get_libdir) ${myhome}/lib
+ fi
+ if [ ! -d ${myhome}/usr/$(get_libdir) ]; then
+ install -c -d ${myhome}/usr/$(get_libdir)
+ chmod 755 ${myhome}/usr/$(get_libdir)
+ fi
+ if [ ! -d ${myhome}/usr/lib ]; then
+ ln -s $(get_libdir) ${myhome}/usr/lib
+ fi
+
+ for bin in $BINARIES; do
+ install -c -d ${myhome}/`/bin/dirname $bin`
+ install -c $bin ${myhome}/$bin
+ done
+ for lib in $LIB_LIST; do
+ install -c -d ${myhome}/`/bin/dirname $lib`
+ install -c $lib ${myhome}/$lib
+ done
+
+ chown 0:0 ${myhome}
+ if [ -d ${myhome}/.ssh ]; then
+ chown 0:0 ${myhome}/.ssh
+ fi
+
+ if [ ! -d ${myhome}/incoming ]; then
+ einfo "creating ${myhome}/incoming directory for uploading files"
+ install -c -o ${myuser} -d ${myhome}/incoming
+ fi
+ chown $myuser:$myuser ${myhome}/incoming
+
+ if [ ! -e ${myhome}/etc/passwd ]; then
+ grep "^${myuser}" /etc/passwd > ${myhome}/etc/passwd
+ fi
+
+ # Bug 135505
+ if [ ! -e ${myhome}/dev/null ]; then
+ install -c -d ${myhome}/dev
+ mknod -m 777 ${myhome}/dev/null c 1 3
+ fi
+}