diff options
author | Mike Frysinger <vapier@gentoo.org> | 2011-01-24 02:55:47 +0000 |
---|---|---|
committer | Mike Frysinger <vapier@gentoo.org> | 2011-01-24 02:55:47 +0000 |
commit | b338ef3199bb525735aa9092e9056a8440e925a9 (patch) | |
tree | b19fc85ee90d51b0df8a4b1803c2539ebfff106f /net-misc/openssh | |
parent | old (diff) | |
download | historical-b338ef3199bb525735aa9092e9056a8440e925a9.tar.gz historical-b338ef3199bb525735aa9092e9056a8440e925a9.tar.bz2 historical-b338ef3199bb525735aa9092e9056a8440e925a9.zip |
Version bump.
Package-Manager: portage-2.2.0_alpha19/cvs/Linux x86_64
Diffstat (limited to 'net-misc/openssh')
-rw-r--r-- | net-misc/openssh/ChangeLog | 10 | ||||
-rw-r--r-- | net-misc/openssh/Manifest | 38 | ||||
-rw-r--r-- | net-misc/openssh/files/sshd.rc6.2 | 84 | ||||
-rw-r--r-- | net-misc/openssh/openssh-5.7_p1.ebuild | 257 |
4 files changed, 363 insertions, 26 deletions
diff --git a/net-misc/openssh/ChangeLog b/net-misc/openssh/ChangeLog index 06752658ed6d..71440870369f 100644 --- a/net-misc/openssh/ChangeLog +++ b/net-misc/openssh/ChangeLog @@ -1,6 +1,12 @@ # ChangeLog for net-misc/openssh -# Copyright 1999-2010 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/net-misc/openssh/ChangeLog,v 1.400 2010/12/10 18:18:50 robbat2 Exp $ +# Copyright 1999-2011 Gentoo Foundation; Distributed under the GPL v2 +# $Header: /var/cvsroot/gentoo-x86/net-misc/openssh/ChangeLog,v 1.401 2011/01/24 02:55:47 vapier Exp $ + +*openssh-5.7_p1 (24 Jan 2011) + + 24 Jan 2011; Mike Frysinger <vapier@gentoo.org> +openssh-5.7_p1.ebuild, + +files/sshd.rc6.2: + Version bump. 10 Dec 2010; Robin H. Johnson <robbat2@gentoo.org> metadata.xml: Update restrict in metadata per mgorny's request to use DEPEND syntax. diff --git a/net-misc/openssh/Manifest b/net-misc/openssh/Manifest index c900c976a86e..1d910e4cba02 100644 --- a/net-misc/openssh/Manifest +++ b/net-misc/openssh/Manifest @@ -1,14 +1,12 @@ -AUX openssh-3.9_p1-opensc.patch 3242 RMD160 9c382109f0a64c30d6404f6c6ecdd274b8114fd3 SHA1 1020a213c5acb479003bebe6e4bed0f5b1e56a9f SHA256 36f27a6cd277cf08fadbc23cd4d019def69f40a601d75e63ead7bdc7cdf0539b +-----BEGIN PGP SIGNED MESSAGE----- +Hash: SHA256 + AUX openssh-4.7_p1-GSSAPI-dns.patch 4494 RMD160 4e02e0a85c0e33c917ec8c22b4e1c173a9d7d79e SHA1 d8a81eb92a49763106cfa5b319c22c6f188508ef SHA256 88a08f349258d4be5b2faa838a89fe1aa0196502990b745ac0e3a70dda30a0d7 -AUX openssh-4.7p1-selinux.diff 541 RMD160 bcb8f1fef2ae8378e7000732223c6116e06e0d6f SHA1 395b4dcff3eb7b92582a4364e612fff87278e7bc SHA256 ef8d71c46059bdcc8487cad06914639a8237197561cc030d8eed3baf418cc810 AUX openssh-5.2_p1-autoconf.patch 386 RMD160 8e57ae97df0b2483f826a7aba00bc0622b9a28f8 SHA1 22c4e40f54f97f866b460fe8987eb16363410caf SHA256 42bb5f23f02241186abd6158ac15cd1fba0fadb4bd79e6b051fbd05605419ebb AUX openssh-5.2_p1-gsskex-fix.patch 408 RMD160 6a6296cd1c8acc52af4e0d8b6238b326d5d41e77 SHA1 b31e5294c68e6af9a75987a1c3ece5e52f56e9a5 SHA256 8190db31ed2e8dc6ce79030e5c648d04610b06dd8366df5948ef6e990314ee96 AUX openssh-5.2_p1-x509-hpn-glue.patch 2851 RMD160 2c3fbb549976f9004e89bcfb58dadf2186f64517 SHA1 ff666fb2a0ef3fc7d703f99438ca4c39ee2eafdf SHA256 a21336a892b61e29a556d16e9f0a67ee08ad04dd61e3963a201fdf032ce55f75 AUX openssh-5.2p1-ldap-stdargs.diff 252 RMD160 7bf89a0946446b43ce3026b7b01a9a4c637f388a SHA1 7b62038dc3060b1e77df213c85874ba80acd8f64 SHA256 97281375efa33e9ce70a55bfa95b6b426208175e7e3ff493012bc25d9b012f45 -AUX openssh-5.3_p1-pkcs11-hpn-glue.patch 765 RMD160 9c865591eed26cadb34b0a4f35b574cda13a7da1 SHA1 4203cc42e801b5c598a4d7fd021bf965d64c1391 SHA256 0f85b457061fee06f053945ed1a37a962e41cd1c49c616fb9d5e4ad776fda6a4 AUX openssh-5.4_p1-openssl.patch 255 RMD160 6d495664c5d94058cb4aa8a0011a070cb27a8fb9 SHA1 9e78702afc936a478f64c73bada9e85f7dbd8081 SHA256 f83627039491e9969f1ed5d77fe816465ce75809e8c2f2bfb07012bc21384347 -AUX openssh-5.4_p1-pkcs11.patch 1099 RMD160 d94041f2448ecc6e9d6add0301979abeaf47fd4c SHA1 371b2cd92ff915a8efc4377de60c7626e0371453 SHA256 5603b9f4cb99990404f7953d2524190ef50e6b0f5434a2465c6dea21720be4b6 -AUX openssh-5.4_p1-relative-AuthorizedKeysFile.patch 1501 RMD160 5f73b12112e52278561923e72d706a575d68d9f1 SHA1 9be8ba4a6d0b748d69596e111eddaa70a69fd645 SHA256 9c06be753927eaecec8eaae401f6890c4ab7a8cf91dc7a35bb95228ed1c0d362 AUX openssh-5.6_p1-hpn-progressmeter.patch 334 RMD160 024480c0f7ccac80905ae4b4ae6adfa21428cf97 SHA1 446cfaa4be26fefbabd8f8933d91b5d5783f196c SHA256 eaa98f954934364a1994111f5a422d0730b6e224822cef03efe6d6fc0c7f056f AUX openssh-5.6_p1-x509-hpn-glue.patch 1974 RMD160 bccefdc9ee8e923968c6dac5d470466b1b7e78b9 SHA1 8f882f22d2c85967d3d54c250a11077b67f9a1a9 SHA256 164db7af08e0565821d6d609b1beadab39777521bfff143a83acc1e097ad60f1 AUX sshd.confd 396 RMD160 029680b2281961130a815ef599750c4fc4e84987 SHA1 23c283d0967944b6125be26ed4628f49abf586b2 SHA256 29c6d57ac3ec6018cadc6ba6cd9b90c9ed46e20049b970fdcc68ee2481a2ee41 @@ -16,34 +14,26 @@ AUX sshd.pam 294 RMD160 1d4499a7de54188e51e87a240ec7a1b3b1af583d SHA1 4cd17fb407 AUX sshd.pam_include.2 156 RMD160 c4f6ba6e3a705eef63e571189e28de71e7d61178 SHA1 1223f7a43a5e124521d48852b2d23bb8ba0a788f SHA256 166136e27d653e0bf481a6ca79fecb7d9fa2fc3d597d041f97df595f65a8193c AUX sshd.rc6 2159 RMD160 961c7222fe809d81dc04c1f62e14c8292c0e3452 SHA1 d9853a50ff89d4359cc813a0f5ec936659941646 SHA256 83b94fed859ab3a00861969f97c166bd3b2fdd217f26468153e17005dfd55828 AUX sshd.rc6.1 2244 RMD160 112f62244a4654d706fa3892da514df8130dabf3 SHA1 4a561034f7376bf10dc4601f2b847f247b83bf53 SHA256 09b7f29890fd0c28e364637236518c7ee4fea018af94dd72b8682a548678cd73 -DIST openssh-5.2p1+x509-6.2.1.diff.gz 153887 RMD160 3642946adfc122f28fb80518719040dddacf84ea SHA1 e48447e4335c543f4b702b3e3d0e41d6d9f7f6aa SHA256 9a745634eaf450fb2c0f9dcc31f3021dcd70d6bbdba0ae5b6952f2dfcb21ee55 -DIST openssh-5.2p1-gsskex-all-20090726.patch 90959 RMD160 45763e73aa65181d56aafed9ab7dd217150769f2 SHA1 64058c69fb866a8ab0233d454f3bb8e94a0b9db7 SHA256 6eb297d6fa74be3323c5e4f53df5b6e1f4edf6bf394e3e707c075846886e18e7 -DIST openssh-5.2p1-hpn13v6.diff.gz 33540 RMD160 d647d3b0547e4d698c616f5ed6643b3ddbcced95 SHA1 9683d5feb3f7e302ef836901af5366df6c425815 SHA256 90a395037a826a8ebcff68be8e46ddce1f89fd776c312c0e10e73cb703ed21bd -DIST openssh-5.2p1.tar.gz 1016612 RMD160 7c53f342034b16e9faa9f5a09ef46390420722eb SHA1 8273a0237db98179fbdc412207ff8eb14ff3d6de SHA256 4023710c37d0b3d79e6299cb79b6de2a31db7d581fe59e775a5351784034ecae -DIST openssh-5.2pkcs11-0.26.tar.bz2 18642 RMD160 07093fb2ad47247b2f028fae4fe1b80edf4ddaf8 SHA1 755793398e1b04ee6c15458a69ce4ad68d2abee0 SHA256 9655f118c614f76cfdd3164b5c0e3e430f20a4ce16c65df0dc1b594648cf1c07 -DIST openssh-5.3p1+x509-6.2.1.diff.gz 154130 RMD160 d16e9d4fd7f6e64091c7b421df7bbd7c21b40c4e SHA1 52182f3a3f84b5ce5e9fada5669776abb851a3fd SHA256 e7e122e74498a0db4253e4a2a43b55688685381066fbad69ad1beafd27b62523 -DIST openssh-5.3p1-hpn13v6-gentoo.diff.gz 23262 RMD160 f4a99017f658d5b803b966cb3711f246be6344f9 SHA1 a30568339458976933e770900a933f013e8ce2c2 SHA256 3f3861ca5e58134dc3f3f7a042d53b9d652b7e4232fcadd45c7fba2d98f5bf63 -DIST openssh-5.3p1.tar.gz 1027130 RMD160 f8c98b4b91b7e0e02b33837ef6978e8b7570cf9e SHA1 d411fde2584ef6022187f565360b2c63a05602b5 SHA256 d0c917462896974480b14454a8e1cb8b809291f67e5b9779c9b4dc4156c5ef12 -DIST openssh-5.4p1+x509-6.2.3.diff.gz 156621 RMD160 20be6252837563c299dfc8d32ac8823f21efbba4 SHA1 fe77afbe1a2884ee9545b027c311b9e7d4b84115 SHA256 90a21d282b846c28d8c8123dbc6f9bf9e1ec21d818ffe4260027875667164b0b +AUX sshd.rc6.2 2051 RMD160 026c92ef4c0926ca1d5ab91a55b4d12028ba800d SHA1 246ffa14a9636f843c9314a32f11dacdc67cd52f SHA256 c8f8fd4789188c43259c7351cb3d666b24b1703e45129ba09e1b849192967d08 DIST openssh-5.4p1-hpn13v7-x509variant.diff.gz 22941 RMD160 383b3883984ee0e6068363fdd645d2dd24c7964c SHA1 d3f04c938ab6e5e10587d0ffb717af37360a8dd6 SHA256 c2b1a81c6952ae73cc4dfd1528d560588c45cf1242ea8b0e6eadb0cc83b50377 -DIST openssh-5.4p1-hpn13v8.diff.gz 22937 RMD160 40ce779b379c299d8079edbd0538c0927f11f238 SHA1 816ee2a3d0943aa7ccdaad3e0c516c22de000827 SHA256 03a5322a47f7c2011ec2cc5aee64e69b3ead08bde3eb64a20afd2c5ca1fe2529 -DIST openssh-5.4p1.tar.gz 1094604 RMD160 2382307f19edc727a108da262e531ecf3671cf09 SHA1 2a3042372f08afb1415ceaec8178213276a36302 SHA256 ae96e70d04104824ab10f0d7aaef4584ac96b2a870adfcd8b457d836c8c5404e DIST openssh-5.5p1+x509-6.2.3.diff.gz 156737 RMD160 cf6d9e5f51512b3e22a3561ff7e1c6daad80d016 SHA1 5f163b03b3086605d9759b76565e6f3a5fa8cb85 SHA256 a2fdf904c21036fe6ee89da7572a37f4763ef414348f9a953c7c7e0fb3562a7f DIST openssh-5.5p1-hpn13v9.diff.gz 22657 RMD160 bb9d44589018030fa3102898f85f4dfd7032d2f0 SHA1 8601fabf0067ff9c59501dc0006ad3853dbb3de0 SHA256 0556ad75cbd29cba71263a5b7ddc44c03d17c09297a6c41a16d39d3549e5079c DIST openssh-5.5p1.tar.gz 1097574 RMD160 7cee614112b691da5daac9f2579becba2409b727 SHA1 361c6335e74809b26ea096b34062ba8ff6c97cd6 SHA256 36eedd6efe6663186ed23573488670f9b02e34744694e94a9f869b6f25e47e8a DIST openssh-5.6p1+x509-6.2.3.diff.gz 168109 RMD160 d2a0bb07ede384a7fd752d0a1a2b7750101c5fe3 SHA1 319992226b8109c3f6ce9bbe5884635edb2349cf SHA256 90977eded2ae5e71bc3b84aad8597442074742d78d471087d020e58dd58342ad DIST openssh-5.6p1-hpn13v10.diff.gz 22988 RMD160 9c62cd1520a69f10b85496450130a9fd0a5f5954 SHA1 71f5a346b297330c50b324cdc19e361070a31776 SHA256 6a9ee815e8ffcc9068c3dce4ad4f2898fc0db6b768a3152280aceb8c06c8b450 -DIST openssh-5.6p1-hpn13v9-gentoo.diff.gz 23106 RMD160 0f8538a81005ab8c45b53267757aabf8eb15de63 SHA1 a9897d1df3d917f612f92b6a67356ab8be56c4da SHA256 820d7b242e0421a168593e14dd3db5425cd81719caed7a9dfac8d32bd13aad2a DIST openssh-5.6p1.tar.gz 1117952 RMD160 e3e1229cc0efa7cb534c83e61fade8371fc24a23 SHA1 347dd39c91c3529f41dae63714d452fb95efea1e SHA256 538af53b2b8162c21a293bb004ae2bdb141abd250f61b4cea55244749f3c6c2b -DIST openssh-lpk-5.2p1-0.3.11.patch.gz 18116 RMD160 2ff9bdff19e0854a96063be1e0589fa3f85da0d7 SHA1 33b36cf94f68a80fca497da110529ce69d62fbb0 SHA256 450b56a989767aa65a974213e8f7e9d0ee9d08522247db7b787730e53685bebd -DIST openssh-lpk-5.3p1-0.3.11.patch.gz 18137 RMD160 3e316722d521e163a82d661465abef7f128d736b SHA1 870a703e2cafa744681733766e48faf3229e3b7e SHA256 34d8dbccde3b1fedb6b75d7a725ade8b37389c46f5b13a2e5a80d8cd8e6ffaaa +DIST openssh-5.7p1.tar.gz 1113345 RMD160 7f2ee186d5b99e1b40b90669b681b49da962b8f8 SHA1 423e27475f06e1055847dfff7f61e1ac632b5372 SHA256 59057d727d902d8b04b2ce0ba8f288c6e02cb65aca183cc8d559a4a66426581b DIST openssh-lpk-5.4p1-0.3.13.patch.gz 18105 RMD160 734b2c3ea740b6de610e3bfa91c93a2540b79acc SHA1 4c73f21b16db41c16e096db834380ec53f15c723 SHA256 4e5dbe769e487c914ecc5b104866f6d4412cbe35c3f2bed897d06f7d824878be DIST openssh-lpk-5.6p1-0.3.13.patch.gz 18376 RMD160 c928a22d890de17c43ac8a71ac0a551fbe38a831 SHA1 477ef82043278ba9e314e14e7a487f1541fbc48b SHA256 42a76b67c390c3ed28efd6e1734ca5a7edfefc635c35086dbd610999130678e9 -EBUILD openssh-5.2_p1-r3.ebuild 8150 RMD160 b9049bb12151086a4261cfc70aad4ba0def0d4a7 SHA1 a9f0ec39435444e2ca4ca2e0ca99d3a10ded6bd8 SHA256 ba524fd8817de5ece224ba2fca841964020069bd580ae644c99ad9ff3587af1d -EBUILD openssh-5.3_p1-r1.ebuild 8321 RMD160 c632f38bae4c60e4836c96ca7e35dd103b598159 SHA1 1a7f59e8144586def7d83b6c6721d6da5c9e8d40 SHA256 1fa0285b909c4bd834bf495d3140aa8c7e6586ca1f85ec0c46aa0e0b4ee8df5d -EBUILD openssh-5.4_p1-r3.ebuild 8268 RMD160 0116016c792b5f56411dddf5a5f037dc4126361e SHA1 55e4e4e09ad214d3bb82304d1a1848ae45101099 SHA256 cbe163e47210ca42bf24545375aec9f9757af200eab68b9d539c7b2c39926f03 EBUILD openssh-5.5_p1-r2.ebuild 8180 RMD160 e2bcad59293157b59d2b92fbb841fd8c4e2e6c40 SHA1 962947647c14a4a473921842375b9a7bf4bd308c SHA256 3f26e1d3d6cd6fdfef8107bbcb217899857ed12f9d7b805d93333d08ee58a90f -EBUILD openssh-5.6_p1-r1.ebuild 7889 RMD160 5136804037e2b8dc2202014aec6ed877583234e6 SHA1 3abb985a3b875d3f9554e111ed676edc6879297f SHA256 d5549c197592a412130803c7e25bf94b55e607f0a239f6570b269e9713df68a6 EBUILD openssh-5.6_p1-r2.ebuild 7926 RMD160 71fd935260a189065944cd6817ec3f13c18a0d5d SHA1 a02d6fe0bd57ff2bbe87879b5f641782dc7896cf SHA256 21f2dfc54e2ccc50eeab14f2b21cbe4566a28fd068f7162bb6e2254d28f5fbab -MISC ChangeLog 62537 RMD160 615e40533a90ac0cd109f16221067011600e9eba SHA1 df93c1fd31be1c3382b166fed109b1fdfdf7cd71 SHA256 e30f2e03d38848f4bae76d72e0c86221894ffd437f7c9641585cc829ab1bf0e2 +EBUILD openssh-5.7_p1.ebuild 7914 RMD160 ed8a67b03c00a87f2cb10b93ba5e0db081add68a SHA1 65fdc6afd946be556a956e8fd7520913f116ec54 SHA256 4717c2ef2c45b82c59be485f3ea612a0ada94d247b36dfc8b1d2de439590099a +MISC ChangeLog 62679 RMD160 cb3f4779b10841be9590810be5fd0e296b90ef6d SHA1 25885f1d3f0b51c016eb0afe29d796443c71c2dd SHA256 5a6a479c86f50d45527be5bb72919e74e1af871c60a53d271fd82b9deef6a119 MISC metadata.xml 1660 RMD160 1a6a25ed6f3cd79d6e6cf8b650e5d255fff650c2 SHA1 7d5870faabf2c356ccdbb795babcb2fae2ce642c SHA256 050feb498c8c5760f29186c40f476a42491adb271d32544564e6b0e40a01cc8f +-----BEGIN PGP SIGNATURE----- +Version: GnuPG v2.0.16 (GNU/Linux) + +iF4EAREIAAYFAk086jUACgkQaC/OocHi7JZl5AD/ZlB0QNmwEC6d/gwFEoOM9Irn +3C94BM+2uT6kJ5kKCIcA/2HowMaOYVzsSwvBdd4EXQuMx7nz7Q7oqvZlutH/0fop +=kPSt +-----END PGP SIGNATURE----- diff --git a/net-misc/openssh/files/sshd.rc6.2 b/net-misc/openssh/files/sshd.rc6.2 new file mode 100644 index 000000000000..86f87baa878d --- /dev/null +++ b/net-misc/openssh/files/sshd.rc6.2 @@ -0,0 +1,84 @@ +#!/sbin/runscript +# Copyright 1999-2011 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/net-misc/openssh/files/sshd.rc6.2,v 1.1 2011/01/24 02:55:47 vapier Exp $ + +opts="${opts} reload checkconfig gen_keys" + +depend() { + use logger dns + need net +} + +SSHD_CONFDIR=${SSHD_CONFDIR:-/etc/ssh} +SSHD_PIDFILE=${SSHD_PIDFILE:-/var/run/${SVCNAME}.pid} +SSHD_BINARY=${SSHD_BINARY:-/usr/sbin/sshd} + +checkconfig() { + if [ ! -d /var/empty ] ; then + mkdir -p /var/empty || return 1 + fi + + if [ ! -e "${SSHD_CONFDIR}"/sshd_config ] ; then + eerror "You need an ${SSHD_CONFDIR}/sshd_config file to run sshd" + eerror "There is a sample file in /usr/share/doc/openssh" + return 1 + fi + + gen_keys || return 1 + + "${SSHD_BINARY}" -t ${myopts} || return 1 +} + +gen_key() { + local type=$1 key ks + [ $# -eq 1 ] && ks="${type}_" + key="${SSHD_CONFDIR}/ssh_host_${ks}key" + if [ ! -e "${key}" ] ; then + ebegin "Generating ${type} host key" + ssh-keygen -t ${type} -f "${key}" -N '' + eend $? || return $? + fi +} + +gen_keys() { + if egrep -q '^[[:space:]]*Protocol[[:space:]]+.*1' "${SSHD_CONFDIR}"/sshd_config ; then + gen_key rsa1 "" || return 1 + fi + gen_key dsa && gen_key rsa && gen_key ecdsa + return $? +} + +start() { + local myopts="" + [ "${SSHD_PIDFILE}" != "/var/run/sshd.pid" ] \ + && myopts="${myopts} -o PidFile=${SSHD_PIDFILE}" + [ "${SSHD_CONFDIR}" != "/etc/ssh" ] \ + && myopts="${myopts} -f ${SSHD_CONFDIR}/sshd_config" + + checkconfig || return 1 + ebegin "Starting ${SVCNAME}" + start-stop-daemon --start --exec "${SSHD_BINARY}" \ + --pidfile "${SSHD_PIDFILE}" \ + -- ${myopts} ${SSHD_OPTS} + eend $? +} + +stop() { + if [ "${RC_CMD}" = "restart" ] ; then + checkconfig || return 1 + fi + + ebegin "Stopping ${SVCNAME}" + start-stop-daemon --stop --exec "${SSHD_BINARY}" \ + --pidfile "${SSHD_PIDFILE}" --quiet + eend $? +} + +reload() { + checkconfig || return 1 + ebegin "Reloading ${SVCNAME}" + start-stop-daemon --stop --signal HUP --oknodo \ + --exec "${SSHD_BINARY}" --pidfile "${SSHD_PIDFILE}" + eend $? +} diff --git a/net-misc/openssh/openssh-5.7_p1.ebuild b/net-misc/openssh/openssh-5.7_p1.ebuild new file mode 100644 index 000000000000..21d4f9db76df --- /dev/null +++ b/net-misc/openssh/openssh-5.7_p1.ebuild @@ -0,0 +1,257 @@ +# Copyright 1999-2011 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/net-misc/openssh/openssh-5.7_p1.ebuild,v 1.1 2011/01/24 02:55:47 vapier Exp $ + +EAPI="2" +inherit eutils flag-o-matic multilib autotools pam + +# Make it more portable between straight releases +# and _p? releases. +PARCH=${P/_/} + +#HPN_PATCH="${PARCH}-hpn13v10.diff.gz" +#LDAP_PATCH="${PARCH/openssh/openssh-lpk}-0.3.13.patch.gz" +#X509_VER="6.2.3" X509_PATCH="${PARCH/5.7/5.6}+x509-${X509_VER}.diff.gz" + +DESCRIPTION="Port of OpenBSD's free SSH release" +HOMEPAGE="http://www.openssh.org/" +SRC_URI="mirror://openbsd/OpenSSH/portable/${PARCH}.tar.gz + ${HPN_PATCH:+hpn? ( http://www.psc.edu/networking/projects/hpn-ssh/${HPN_PATCH} mirror://gentoo/${HPN_PATCH} )} + ${LDAP_PATCH:+ldap? ( mirror://gentoo/${LDAP_PATCH} )} + ${X509_PATCH:+X509? ( http://roumenpetrov.info/openssh/x509-${X509_VER}/${X509_PATCH} )} + " + +LICENSE="as-is" +SLOT="0" +KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~sparc-fbsd ~x86-fbsd" +IUSE="hpn kerberos ldap libedit pam selinux skey static tcpd X X509" + +RDEPEND="pam? ( virtual/pam ) + kerberos? ( virtual/krb5 ) + selinux? ( >=sys-libs/libselinux-1.28 ) + skey? ( >=sys-auth/skey-1.1.5-r1 ) + ldap? ( net-nds/openldap ) + libedit? ( dev-libs/libedit ) + >=dev-libs/openssl-0.9.6d + >=sys-libs/zlib-1.2.3 + tcpd? ( >=sys-apps/tcp-wrappers-7.6 ) + X? ( x11-apps/xauth ) + userland_GNU? ( sys-apps/shadow )" +DEPEND="${RDEPEND} + dev-util/pkgconfig + virtual/os-headers + sys-devel/autoconf" +RDEPEND="${RDEPEND} + pam? ( >=sys-auth/pambase-20081028 )" +PROVIDE="virtual/ssh" + +S=${WORKDIR}/${PARCH} + +pkg_setup() { + # this sucks, but i'd rather have people unable to `emerge -u openssh` + # than not be able to log in to their server any more + maybe_fail() { [[ -z ${!2} ]] && echo ${1} ; } + local fail=" + $(use X509 && maybe_fail X509 X509_PATCH) + $(use ldap && maybe_fail ldap LDAP_PATCH) + $(use hpn && maybe_fail hpn HPN_PATCH) + " + fail=$(echo ${fail}) + if [[ -n ${fail} ]] ; then + eerror "Sorry, but this version does not yet support features" + eerror "that you requested: ${fail}" + eerror "Please mask ${PF} for now and check back later:" + eerror " # echo '=${CATEGORY}/${PF}' >> /etc/portage/package.mask" + die "booooo" + fi +} + +src_prepare() { + sed -i \ + -e '/_PATH_XAUTH/s:/usr/X11R6/bin/xauth:/usr/bin/xauth:' \ + pathnames.h || die + # keep this as we need it to avoid the conflict between LPK and HPN changing + # this file. + cp version.h version.h.pristine + + if use X509 ; then + # Apply X509 patch + epatch "${DISTDIR}"/${X509_PATCH} + # Apply glue so that HPN will still work after X509 + epatch "${FILESDIR}"/${PN}-5.6_p1-x509-hpn-glue.patch + fi + if ! use X509 ; then + if [[ -n ${LDAP_PATCH} ]] && use ldap ; then + epatch "${DISTDIR}"/${LDAP_PATCH} + epatch "${FILESDIR}"/${PN}-5.2p1-ldap-stdargs.diff #266654 + # version.h patch conflict avoidence + mv version.h version.h.lpk + cp -f version.h.pristine version.h + fi + else + use ldap && ewarn "Sorry, X509 and LDAP conflict internally, disabling LDAP" + fi + epatch "${FILESDIR}"/${PN}-5.4_p1-openssl.patch + epatch "${FILESDIR}"/${PN}-4.7_p1-GSSAPI-dns.patch #165444 integrated into gsskex + if [[ -n ${HPN_PATCH} ]] && use hpn; then + epatch "${DISTDIR}"/${HPN_PATCH} + epatch "${FILESDIR}"/${P}-hpn-progressmeter.patch + # version.h patch conflict avoidence + mv version.h version.h.hpn + cp -f version.h.pristine version.h + # The AES-CTR multithreaded variant is temporarily broken, and + # causes random hangs when combined with the -f switch of ssh. + # To avoid this, we change the internal table to use the non-multithread + # version for the meantime. + sed -i \ + -e '/aes...-ctr.*SSH_CIPHER_SSH2/s,evp_aes_ctr_mt,evp_aes_128_ctr,' \ + cipher.c || die + fi + epatch "${FILESDIR}"/${PN}-5.2_p1-autoconf.patch + + sed -i "s:-lcrypto:$(pkg-config --libs openssl):" configure{,.ac} || die + + # Disable PATH reset, trust what portage gives us. bug 254615 + sed -i -e 's:^PATH=/:#PATH=/:' configure || die + + # Now we can build a sane merged version.h + t="${T}"/version.h + m="${t}.merge" f="${t}.final" + cat version.h.{hpn,pristine,lpk} 2>/dev/null \ + | sed '/^#define SSH_RELEASE/d' \ + | sort | uniq >"${m}" + sed -n -r \ + -e '/^\//p' \ + <"${m}" >"${f}" + sed -n -r \ + -e '/SSH_LPK/s,"lpk","-lpk",g' \ + -e '/^#define/p' \ + <"${m}" >>"${f}" + v="SSH_VERSION SSH_PORTABLE" + [[ -f version.h.hpn ]] && v="${v} SSH_HPN" + [[ -f version.h.lpk ]] && v="${v} SSH_LPK" + echo "#define SSH_RELEASE ${v}" >>"${f}" + cp "${f}" version.h + + eautoreconf +} + +static_use_with() { + local flag=$1 + if use static && use ${flag} ; then + ewarn "Disabling '${flag}' support because of USE='static'" + # rebuild args so that we invert the first one (USE flag) + # but otherwise leave everything else working so we can + # just leverage use_with + shift + [[ -z $1 ]] && flag="${flag} ${flag}" + set -- !${flag} "$@" + fi + use_with "$@" +} + +src_configure() { + addwrite /dev/ptmx + addpredict /etc/skey/skeykeys #skey configure code triggers this + + use static && append-ldflags -static + + econf \ + --with-ldflags="${LDFLAGS}" \ + --disable-strip \ + --sysconfdir=/etc/ssh \ + --libexecdir=/usr/$(get_libdir)/misc \ + --datadir=/usr/share/openssh \ + --with-privsep-path=/var/empty \ + --with-privsep-user=sshd \ + --with-md5-passwords \ + --with-ssl-engine \ + $(static_use_with pam) \ + $(static_use_with kerberos kerberos5 /usr) \ + ${LDAP_PATCH:+$(use X509 || ( use ldap && use_with ldap ))} \ + $(use_with libedit) \ + $(use_with selinux) \ + $(use_with skey) \ + $(use_with tcpd tcp-wrappers) +} + +src_install() { + emake install-nokeys DESTDIR="${D}" || die + fperms 600 /etc/ssh/sshd_config + dobin contrib/ssh-copy-id + newinitd "${FILESDIR}"/sshd.rc6.2 sshd + newconfd "${FILESDIR}"/sshd.confd sshd + keepdir /var/empty + + newpamd "${FILESDIR}"/sshd.pam_include.2 sshd + if use pam ; then + sed -i \ + -e "/^#UsePAM /s:.*:UsePAM yes:" \ + -e "/^#PasswordAuthentication /s:.*:PasswordAuthentication no:" \ + -e "/^#PrintMotd /s:.*:PrintMotd no:" \ + -e "/^#PrintLastLog /s:.*:PrintLastLog no:" \ + "${D}"/etc/ssh/sshd_config || die "sed of configuration file failed" + fi + + # This instruction is from the HPN webpage, + # Used for the server logging functionality + if [[ -n ${HPN_PATCH} ]] && use hpn ; then + keepdir /var/empty/dev + fi + + doman contrib/ssh-copy-id.1 + dodoc ChangeLog CREDITS OVERVIEW README* TODO sshd_config + + diropts -m 0700 + dodir /etc/skel/.ssh +} + +src_test() { + local t tests skipped failed passed shell + tests="interop-tests compat-tests" + skipped="" + shell=$(getent passwd ${UID} | cut -d: -f7) + if [[ ${shell} == */nologin ]] || [[ ${shell} == */false ]] ; then + elog "Running the full OpenSSH testsuite" + elog "requires a usable shell for the 'portage'" + elog "user, so we will run a subset only." + skipped="${skipped} tests" + else + tests="${tests} tests" + fi + for t in ${tests} ; do + # Some tests read from stdin ... + emake -k -j1 ${t} </dev/null \ + && passed="${passed}${t} " \ + || failed="${failed}${t} " + done + einfo "Passed tests: ${passed}" + ewarn "Skipped tests: ${skipped}" + if [[ -n ${failed} ]] ; then + ewarn "Failed tests: ${failed}" + die "Some tests failed: ${failed}" + else + einfo "Failed tests: ${failed}" + return 0 + fi +} + +pkg_postinst() { + enewgroup sshd 22 + enewuser sshd 22 -1 /var/empty sshd + + ewarn "Remember to merge your config files in /etc/ssh/ and then" + ewarn "reload sshd: '/etc/init.d/sshd reload'." + if use pam ; then + echo + ewarn "Please be aware users need a valid shell in /etc/passwd" + ewarn "in order to be allowed to login." + fi + # This instruction is from the HPN webpage, + # Used for the server logging functionality + if [[ -n ${HPN_PATCH} ]] && use hpn ; then + echo + einfo "For the HPN server logging patch, you must ensure that" + einfo "your syslog application also listens at /var/empty/dev/log." + fi +} |