diff options
author | Alin Năstac <mrness@gentoo.org> | 2007-12-11 20:12:23 +0000 |
---|---|---|
committer | Alin Năstac <mrness@gentoo.org> | 2007-12-11 20:12:23 +0000 |
commit | 0c9f8a9ebe50027d74bb34b2cd1b392b5df12650 (patch) | |
tree | b09bba708b058af1e5a2feebafcd8928ed7b928c /net-proxy | |
parent | arm/sh stable (diff) | |
download | historical-0c9f8a9ebe50027d74bb34b2cd1b392b5df12650.tar.gz historical-0c9f8a9ebe50027d74bb34b2cd1b392b5df12650.tar.bz2 historical-0c9f8a9ebe50027d74bb34b2cd1b392b5df12650.zip |
Version bump (#201816).
Package-Manager: portage-2.1.3.19
Diffstat (limited to 'net-proxy')
-rw-r--r-- | net-proxy/sshproxy/ChangeLog | 8 | ||||
-rw-r--r-- | net-proxy/sshproxy/Manifest | 38 | ||||
-rw-r--r-- | net-proxy/sshproxy/files/digest-sshproxy-0.6.0_beta0 | 3 | ||||
-rw-r--r-- | net-proxy/sshproxy/files/sshproxy.ini | 14 | ||||
-rw-r--r-- | net-proxy/sshproxy/files/sshproxyd.initd | 7 | ||||
-rw-r--r-- | net-proxy/sshproxy/sshproxy-0.6.0_beta0.ebuild | 167 |
6 files changed, 211 insertions, 26 deletions
diff --git a/net-proxy/sshproxy/ChangeLog b/net-proxy/sshproxy/ChangeLog index 12c31e63f1f6..1d15e449795c 100644 --- a/net-proxy/sshproxy/ChangeLog +++ b/net-proxy/sshproxy/ChangeLog @@ -1,6 +1,12 @@ # ChangeLog for net-proxy/sshproxy # Copyright 1999-2007 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/net-proxy/sshproxy/ChangeLog,v 1.6 2007/11/04 08:25:03 mrness Exp $ +# $Header: /var/cvsroot/gentoo-x86/net-proxy/sshproxy/ChangeLog,v 1.7 2007/12/11 20:12:23 mrness Exp $ + +*sshproxy-0.6.0_beta0 (11 Dec 2007) + + 11 Dec 2007; Alin Năstac <mrness@gentoo.org> files/sshproxy.ini, + files/sshproxyd.initd, +sshproxy-0.6.0_beta0.ebuild: + Version bump (#201816). 04 Nov 2007; Alin Năstac <mrness@gentoo.org> sshproxy-0.5.0.ebuild: Remove useless pkg_setup call from pkg_preinst. diff --git a/net-proxy/sshproxy/Manifest b/net-proxy/sshproxy/Manifest index 2a64d436eb1d..5065801e3f57 100644 --- a/net-proxy/sshproxy/Manifest +++ b/net-proxy/sshproxy/Manifest @@ -1,27 +1,32 @@ -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 -AUX sshproxy.ini 500 RMD160 ff2d1f4a1248960e74e034145d001902711c50af SHA1 eb2b670a9b0b88c1bab9b1ed5b020384a578c905 SHA256 59dfbfa7da4ff45d57e7b11e571e24274b0e9928e37ad31b4cd25fd926168df1 -MD5 28e0900653b6309576c882194a500003 files/sshproxy.ini 500 -RMD160 ff2d1f4a1248960e74e034145d001902711c50af files/sshproxy.ini 500 -SHA256 59dfbfa7da4ff45d57e7b11e571e24274b0e9928e37ad31b4cd25fd926168df1 files/sshproxy.ini 500 +AUX sshproxy.ini 493 RMD160 a3374b25ca48b9e06def302ca6ccf490893487ce SHA1 27046518680f5d72a0205c1a3cee82d56ecad692 SHA256 4ef520bf7ca985232ed54abf6c68c62d76d60ca5061ae38dc346a6efad70aecd +MD5 bbffdbdcfe8160580f736fee440f4582 files/sshproxy.ini 493 +RMD160 a3374b25ca48b9e06def302ca6ccf490893487ce files/sshproxy.ini 493 +SHA256 4ef520bf7ca985232ed54abf6c68c62d76d60ca5061ae38dc346a6efad70aecd files/sshproxy.ini 493 AUX sshproxyd.confd 195 RMD160 fb23a5667dfde2477c7f4213d597b39bcd811315 SHA1 d7f89bdea160a05a58e6905677a279b872db3bc7 SHA256 a7fdc26b308d71a4ff1c2070af0bff241f766f0492570384e00edf4b3234ed73 MD5 643aeef181664f79d36aa34b79097fce files/sshproxyd.confd 195 RMD160 fb23a5667dfde2477c7f4213d597b39bcd811315 files/sshproxyd.confd 195 SHA256 a7fdc26b308d71a4ff1c2070af0bff241f766f0492570384e00edf4b3234ed73 files/sshproxyd.confd 195 -AUX sshproxyd.initd 444 RMD160 2b563e310de7c3ff9ecc249d7ac9b99caeaec3d6 SHA1 07d74663cb1636dfbc417c17bd8603b023390f20 SHA256 275c3a538e646bf0e429ec322d9521b0168fe74d9bbfe25392506abb53a4dd68 -MD5 dd59774321eabfc63e814a0c0e7decf0 files/sshproxyd.initd 444 -RMD160 2b563e310de7c3ff9ecc249d7ac9b99caeaec3d6 files/sshproxyd.initd 444 -SHA256 275c3a538e646bf0e429ec322d9521b0168fe74d9bbfe25392506abb53a4dd68 files/sshproxyd.initd 444 +AUX sshproxyd.initd 482 RMD160 aecb78a75b9587274eba286bea9d615d75741c79 SHA1 ab19155320d0bb25ca4b63bde20155b4f2756a6c SHA256 4e4975ce221053ef50af497625d9fc9c3a5b37a2b22b295ace1c202a18ccd324 +MD5 8167a8c35ecbe6b7de8eec089e0f26b8 files/sshproxyd.initd 482 +RMD160 aecb78a75b9587274eba286bea9d615d75741c79 files/sshproxyd.initd 482 +SHA256 4e4975ce221053ef50af497625d9fc9c3a5b37a2b22b295ace1c202a18ccd324 files/sshproxyd.initd 482 DIST sshproxy-0.5.0.tar.gz 108834 RMD160 786a8b2708329ec5e91657cc20479928f73e2b22 SHA1 9a401bde8a26aa5cfcb1be1d5f745a9fb8699e5a SHA256 a5f091fc389696cfe618466b61e76559a36ee503b6ce7855089050900021caa8 +DIST sshproxy-0.6.0_beta0.tar.gz 126549 RMD160 381c83ab9db5a0c306dd0df52a3e29c64f7ed04a SHA1 11b8f94dc2ccce6f4ca48ccd21043942e9ff88e8 SHA256 1915989a98a3fcb6a4769feacb31eeb40003660370c1068bdaa5e847339a3da4 EBUILD sshproxy-0.5.0.ebuild 5062 RMD160 e64ec2f45630011933af21f9e971b4e6a139e672 SHA1 6d62457ebd0f43e3a6e7c977387b297bc62798ba SHA256 fc8c64d405cd7735eb74d4944ac839880c2b76ad64c5c0425416974fb6e5f6a7 MD5 c12e7fd89e62a4eb6baa82bc0103e24f sshproxy-0.5.0.ebuild 5062 RMD160 e64ec2f45630011933af21f9e971b4e6a139e672 sshproxy-0.5.0.ebuild 5062 SHA256 fc8c64d405cd7735eb74d4944ac839880c2b76ad64c5c0425416974fb6e5f6a7 sshproxy-0.5.0.ebuild 5062 -MISC ChangeLog 1205 RMD160 f1666f0689b765d69766d30a58e97bf9c35eacbf SHA1 d59f35f6c6621595660d79650c8ea48dd6766051 SHA256 15753be0e0b0f7da5ed41a37a6e731dbb60dcf271779a3ec209d9dc98ab2b56b -MD5 b0fdd7035019fd9b21ea419ea991c497 ChangeLog 1205 -RMD160 f1666f0689b765d69766d30a58e97bf9c35eacbf ChangeLog 1205 -SHA256 15753be0e0b0f7da5ed41a37a6e731dbb60dcf271779a3ec209d9dc98ab2b56b ChangeLog 1205 +EBUILD sshproxy-0.6.0_beta0.ebuild 5084 RMD160 9d2ffe1c0f0c1f5db5246b891ca05e2b293b9b7e SHA1 594981f9088d7a9f3dc7b052139151231a6805d5 SHA256 50c0049c7da0641b131a8f6c985cb417e03b190cbda6a8ea9b2801f800ada474 +MD5 7bc5989177a203167b4382f147af3f66 sshproxy-0.6.0_beta0.ebuild 5084 +RMD160 9d2ffe1c0f0c1f5db5246b891ca05e2b293b9b7e sshproxy-0.6.0_beta0.ebuild 5084 +SHA256 50c0049c7da0641b131a8f6c985cb417e03b190cbda6a8ea9b2801f800ada474 sshproxy-0.6.0_beta0.ebuild 5084 +MISC ChangeLog 1392 RMD160 95d19f40e2c957157c7becb44ccbf87966d48f12 SHA1 5bfeca03dbd21333bdc7de9c3927fbb811048d4d SHA256 6632bba7785c42769ea79e76f05ad344143e2ce229c77d2f5de7ba9d2dd974f2 +MD5 c5f7fe48a511001daf8d488e585eb932 ChangeLog 1392 +RMD160 95d19f40e2c957157c7becb44ccbf87966d48f12 ChangeLog 1392 +SHA256 6632bba7785c42769ea79e76f05ad344143e2ce229c77d2f5de7ba9d2dd974f2 ChangeLog 1392 MISC metadata.xml 1233 RMD160 a95b010856b0ba9c54eecb3726d2014e645ad60d SHA1 fe0116aa0442c685eb09901850e7d5fbcc8a0137 SHA256 5dc949731b1ef27fb9a2822f065ff1bc1e0d0126af04d7091429fb05e49a7257 MD5 b88fa69e1a1ddb51ae0d6967893efa22 metadata.xml 1233 RMD160 a95b010856b0ba9c54eecb3726d2014e645ad60d metadata.xml 1233 @@ -29,10 +34,13 @@ SHA256 5dc949731b1ef27fb9a2822f065ff1bc1e0d0126af04d7091429fb05e49a7257 metadata MD5 d5d581cc50b6731a7be0f4dfbce3d898 files/digest-sshproxy-0.5.0 244 RMD160 4e66248e3092aec1ce5229032b24a0dba51ed9dc files/digest-sshproxy-0.5.0 244 SHA256 50aae9ac83a60ecf75456a5fc05ee8c38194e4f34e9ec1a7642b80534ef8191c files/digest-sshproxy-0.5.0 244 +MD5 c8f2b040033f5465349d191b5a7e64da files/digest-sshproxy-0.6.0_beta0 262 +RMD160 9eac6c84a2141bba0e7a16d4cae315f44e8b9aae files/digest-sshproxy-0.6.0_beta0 262 +SHA256 7ffa9fb7f80f7b22bb4d958bb9e8120e82ae773f59637b90536d87a6ba30d5f6 files/digest-sshproxy-0.6.0_beta0 262 -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.7 (GNU/Linux) -iD8DBQFHLYHlVSA5X31g7/gRAvboAKCJOTge3iswV3lQ5LyTeLuxh9INcACfXfTe -sdZuFQaehoVnfgKQzhu/enc= -=v6SC +iD8DBQFHXu8yVSA5X31g7/gRAqeUAJ4sws3RKSuY3rS+3R7GnUbfBn3/KgCgho1D +GFrYfjm36lVQlWUAht37OtE= +=wroc -----END PGP SIGNATURE----- diff --git a/net-proxy/sshproxy/files/digest-sshproxy-0.6.0_beta0 b/net-proxy/sshproxy/files/digest-sshproxy-0.6.0_beta0 new file mode 100644 index 000000000000..3c038d14b287 --- /dev/null +++ b/net-proxy/sshproxy/files/digest-sshproxy-0.6.0_beta0 @@ -0,0 +1,3 @@ +MD5 28b12a3a3e12cba94080821f989f3b30 sshproxy-0.6.0_beta0.tar.gz 126549 +RMD160 381c83ab9db5a0c306dd0df52a3e29c64f7ed04a sshproxy-0.6.0_beta0.tar.gz 126549 +SHA256 1915989a98a3fcb6a4769feacb31eeb40003660370c1068bdaa5e847339a3da4 sshproxy-0.6.0_beta0.tar.gz 126549 diff --git a/net-proxy/sshproxy/files/sshproxy.ini b/net-proxy/sshproxy/files/sshproxy.ini index 983669d6146a..c37cb374b3d2 100644 --- a/net-proxy/sshproxy/files/sshproxy.ini +++ b/net-proxy/sshproxy/files/sshproxy.ini @@ -1,26 +1,26 @@ [sshproxy] max_connections = 0 -client_db = file_db +client_db = ini_db pkey_id = sshproxy@%HOSTNAME% plugin_dir = /usr/lib/sshproxy -plugin_list = file_db +plugin_list = ini_db port = 2242 logger_conf = /usr/share/sshproxy/logger.conf cipher_type = blowfish log_dir = /var/log/sshproxy -acl_db = file_db -site_db = file_db +acl_db = ini_db +site_db = ini_db listen_on = auto_add_key = no [blowfish] secret = %BLOWFISH_SECRET% -[client_db.file] +[client_db.ini] file = /var/lib/sshproxy/client.db -[acl_db.file] +[acl_db.ini] file = /var/lib/sshproxy/acl.db -[site_db.file] +[site_db.ini] db_path = /var/lib/sshproxy/site.db diff --git a/net-proxy/sshproxy/files/sshproxyd.initd b/net-proxy/sshproxy/files/sshproxyd.initd index 02e3bdcc35f0..52dd72a771ee 100644 --- a/net-proxy/sshproxy/files/sshproxyd.initd +++ b/net-proxy/sshproxy/files/sshproxyd.initd @@ -7,10 +7,11 @@ depend() { start() { ebegin "Starting SSH Proxy daemon" - start-stop-daemon --start --exec /usr/bin/sshproxyd -- \ + start-stop-daemon --start --background \ + --pidfile /var/run/sshproxyd.pid --exec /usr/bin/sshproxyd -- \ --daemon --user ${SSHPROXYD_USER:-sshproxy} \ - --config-dir ${SSHPROXYD_CONFDIR:-/etc/sshproxy} \ - --pid /var/run/sshproxyd.pid + --config-dir ${SSHPROXYD_CONFDIR:-/etc/sshproxy} \ + --pid /var/run/sshproxyd.pid eend $? } diff --git a/net-proxy/sshproxy/sshproxy-0.6.0_beta0.ebuild b/net-proxy/sshproxy/sshproxy-0.6.0_beta0.ebuild new file mode 100644 index 000000000000..9d5f25898239 --- /dev/null +++ b/net-proxy/sshproxy/sshproxy-0.6.0_beta0.ebuild @@ -0,0 +1,167 @@ +# Copyright 1999-2007 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/net-proxy/sshproxy/sshproxy-0.6.0_beta0.ebuild,v 1.1 2007/12/11 20:12:23 mrness Exp $ + +inherit distutils + +DESCRIPTION="sshproxy is an ssh gateway to apply ACLs on ssh connections" +HOMEPAGE="http://sshproxy-project.org/" +SRC_URI="http://sshproxy-project.org/download/${P}.tar.gz" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="~amd64 ~x86" + +IUSE="client-only mysql minimal" +# mysql: install the mysql_db backend driver +# minimal: do not install extra plugins +# client-only: install only the client wrappers + +DEPEND="!client-only? ( + >=dev-python/paramiko-1.6.2 + mysql? ( >=dev-python/mysql-python-1.2.0 ) + )" +RDEPEND="${DEPEND} + net-misc/openssh" + +pkg_setup() { + enewgroup sshproxy + enewuser sshproxy -1 -1 /var/lib/sshproxy sshproxy +} + +src_install () { + dobin bin/pssh + dobin bin/pscp + if ! use client-only; then + distutils_src_install + + diropts -o sshproxy -g sshproxy -m0750 + keepdir /var/lib/sshproxy + keepdir /var/log/sshproxy + + # Create a default sshproxy.ini + dodir /etc/sshproxy + insopts -o sshproxy -g sshproxy -m0600 + insinto /etc/sshproxy + doins "${FILESDIR}/sshproxy.ini" + local BLOWFISH_SECRET=$(printf "%04hX%04hX%04hX%04hX\n" ${RANDOM} ${RANDOM} ${RANDOM} ${RANDOM}) + sed -i -e "s/%BLOWFISH_SECRET%/${BLOWFISH_SECRET}/" \ + -e "s/%HOSTNAME%/${HOSTNAME}/" \ + "${D}/etc/sshproxy/sshproxy.ini" + + rm -rf "${D}/usr/lib/sshproxy/spexpect" + if use minimal; then + local p + for p in acl_funcs console_extra logusers; do + rm -rf "${D}/usr/lib/sshproxy/${p}" + done + else + keepdir /var/log/sshproxy/logusers + { # initialize a reasonable value for the logusers plugin + echo + echo "[logusers]" + echo "logdir = /var/log/sshproxy/logusers" + echo + } >> "${D}/etc/sshproxy/sshproxy.ini" + fi + + # init/conf files for sshproxy daemon + newinitd "${FILESDIR}/sshproxyd.initd" sshproxyd + newconfd "${FILESDIR}/sshproxyd.confd" sshproxyd + + if use mysql; then + insinto /usr/share/sshproxy/mysql_db + doins misc/mysql_db.sql + doins misc/sshproxy-mysql-user.sql + else + rm -rf "${D}/usr/lib/sshproxy/mysql_db" + sed -i -e 's/[ \t]\+mysql//' \ + "${D}/etc/init.d/sshproxyd" + fi + fi +} + +pkg_postinst () { + if use client-only; then + echo + einfo "Don't forget to set the following environment variables" + einfo " SSHPROXY_HOST (default to localhost)" + einfo " SSHPROXY_PORT (default to 2242)" + einfo " SSHPROXY_USER (default to \$USER)" + einfo "for each sshproxy user." + else + distutils_pkg_postinst + + echo + einfo "If this is your first installation, run" + einfo " emerge --config =${CATEGORY}/${PF}" + einfo "to initialize the backend and configure sshproxy." + echo + einfo "There is no need to install sshproxy on a client machine." + einfo "You can connect to a SSH server using this proxy by running" + einfo " ssh -tp PROXY_PORT PROXY_USER@PROXY_HOST -- REMOTE_USER@REMOTE_HOST" + fi +} + +pkg_config() { + if [[ -d "${ROOT}/usr/lib/sshproxy/mysql_db" ]]; then + local PASSWD=$(printf "%04hX%04hX%04hX%04hX\n" ${RANDOM} ${RANDOM} ${RANDOM} ${RANDOM}) + local SHARE="${ROOT}/usr/share/sshproxy/mysql_db" + local DB_HOST DB_PORT + read -p "Enter the MySQL host (default localhost): " DB_HOST + [[ -n "${DB_HOST}" ]] || DB_HOST=localhost + read -p "Enter the MySQL port (default 3306): " DB_PORT + [[ -n "${DB_PORT}" ]] || DB_PORT=3306 + + ewarn "When prompted for a password, enter your MySQL root password" + ewarn + + if mysql -h ${DB_HOST} -P ${DB_PORT} -u root -p <<EOF ; then +CREATE DATABASE sshproxy; +USE sshproxy; +$(sed -e "s/sshproxypw/${PASSWD}/g" "${SHARE}/sshproxy-mysql-user.sql") +$(<"${SHARE}/mysql_db.sql") +EOF + + { + echo + echo "[client_db.mysql]" + echo "host = ${DB_HOST}" + echo "password = ${PASSWD}" + echo "db = sshproxy" + echo "user = sshproxy" + echo "port = ${DB_PORT}" + echo + echo "[acl_db.mysql]" + echo "host = ${DB_HOST}" + echo "password = ${PASSWD}" + echo "db = sshproxy" + echo "user = sshproxy" + echo "port = ${DB_PORT}" + echo + echo "[site_db.mysql]" + echo "host = ${DB_HOST}" + echo "password = ${PASSWD}" + echo "db = sshproxy" + echo "user = sshproxy" + echo "port = ${DB_PORT}" + } >> "${ROOT}/etc/sshproxy/sshproxy.ini" + + sed -i -e 's/^\(\(acl\|client\|site\)_db = \)ini_db/\1mysql_db/g' \ + "${ROOT}/etc/sshproxy/sshproxy.ini" + grep -q "^plugin_list .* mysql_db" \ + "${ROOT}/etc/sshproxy/sshproxy.ini" || \ + sed -i -e 's/^\(plugin_list = .*\)$/\1 mysql_db/g' \ + "${ROOT}/etc/sshproxy/sshproxy.ini" + else + ewarn "Failed to create MySQL database!" + ewarn "If the database already existed and you want to replace it," + ewarn "hit Ctrl-C now and drop the old database by running the command:" + ewarn " /usr/bin/mysqladmin -h ${DB_HOST} -P ${DB_PORT} -u root -p drop sshproxy" + read -p "Hit Ctrl-C to stop the procedure or Enter to continue " key + fi + fi + + INITD_STARTUP="/etc/init.d/sshproxyd start" chroot "${ROOT}" \ + sshproxy-setup -u sshproxy -c /etc/sshproxy +} |