From 5695ca0725219c2b6e0055564e62697e2f0e0818 Mon Sep 17 00:00:00 2001 From: Samuli Suominen Date: Sun, 11 Jul 2010 10:05:42 +0000 Subject: [PATCH] =?utf8?q?Fix=20building=20with=20OpenSSL=20>=3D=201.0.0?= =?utf8?q?=20wrt=20#327765=20by=20Diego=20E.=20Petten=C3=B2.=20Package-Man?= =?utf8?q?ager:=20portage-2.2=5Frc67/cvs/Linux=20x86=5F64?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit --- app-crypt/heimdal/ChangeLog | 8 +- app-crypt/heimdal/Manifest | 14 +- .../heimdal/files/heimdal_openssl-1.patch | 174 ++++++++++++++++++ app-crypt/heimdal/heimdal-1.3.3-r1.ebuild | 122 ++++++++++++ 4 files changed, 306 insertions(+), 12 deletions(-) create mode 100644 app-crypt/heimdal/files/heimdal_openssl-1.patch create mode 100644 app-crypt/heimdal/heimdal-1.3.3-r1.ebuild diff --git a/app-crypt/heimdal/ChangeLog b/app-crypt/heimdal/ChangeLog index 890e2b928189..266cc4746583 100644 --- a/app-crypt/heimdal/ChangeLog +++ b/app-crypt/heimdal/ChangeLog @@ -1,6 +1,12 @@ # ChangeLog for app-crypt/heimdal # Copyright 1999-2010 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/app-crypt/heimdal/ChangeLog,v 1.156 2010/06/23 21:46:33 angelos Exp $ +# $Header: /var/cvsroot/gentoo-x86/app-crypt/heimdal/ChangeLog,v 1.157 2010/07/11 10:05:41 ssuominen Exp $ + +*heimdal-1.3.3-r1 (11 Jul 2010) + + 11 Jul 2010; Samuli Suominen + +heimdal-1.3.3-r1.ebuild, +files/heimdal_openssl-1.patch: + Fix building with OpenSSL >= 1.0.0 wrt #327765 by Diego E. Pettenò. 23 Jun 2010; Christoph Mende heimdal-1.3.3.ebuild: Stable on amd64 wrt bug #322709 diff --git a/app-crypt/heimdal/Manifest b/app-crypt/heimdal/Manifest index 2ad87d31da57..16ee8340a84f 100644 --- a/app-crypt/heimdal/Manifest +++ b/app-crypt/heimdal/Manifest @@ -1,6 +1,3 @@ ------BEGIN PGP SIGNED MESSAGE----- -Hash: SHA256 - AUX heimdal-0.7.2-as_needed.patch 853 RMD160 5c03f5008e395e87c48f89fe91828e0d034de7db SHA1 0b4dda9830d36185055b66976436545e3daa926b SHA256 640969f1ebe65bae204d45b076dbd488f62a4fd5cf6d96bdc5373423e71f39e3 AUX heimdal-autoconf-2.64.patch 364 RMD160 1b362be75f32eaf79502aa406db7ded25a2878d7 SHA1 1727677c8e5de5c12469a44a28c61f04b15d6a37 SHA256 2dc9dfb773b58b54d1aef76362db734066828893dd1e2ffcee9e20b3484abbf3 AUX heimdal-autoconf-ipv6-backport.patch 4521 RMD160 0ee4317834939d23bd34cce02034bd3de7eb1022 SHA1 768461c3a40d55ecae3872c8957249fef0e71201 SHA256 6a1f8d23072e5b5a2253e3eb0fc931a4dc7f0be8076466b0f8993e644de5248f @@ -16,6 +13,7 @@ AUX heimdal-symlinked-manpages.patch 1104 RMD160 e76c9089229a1a5a87807c306a73d5b AUX heimdal-system_sqlite.patch 1861 RMD160 fa9cf71fef33b3e434f8d3a5bce5c51f0d3c97e5 SHA1 9255730737444febe78ebc47f246893e3887e880 SHA256 79abe4fae56218066b6827989d22d1e0ea1060c027f3698370d1cf7988b487de AUX heimdal_db5.patch 923 RMD160 e7e74d67b2b8789b006ea0dae5695a49386f86f3 SHA1 66106a8c39db0c61a90f0e847417a107cd91931e SHA256 5dac2109683705b2ade8962abfd88f1d989a371b811bc17176c5b360a67bcbe3 AUX heimdal_disable-check-iprop.patch 577 RMD160 ce3733c555c5c13f320bb9a11b5911ab43f7da85 SHA1 a5ab37be218e03e57cf637a5f45ba630bcb45bcf SHA256 b2ab6f335b5a756856a5df635df82488f9dcdb3ed02a7114f90b4a34911f9721 +AUX heimdal_openssl-1.patch 4623 RMD160 1450ee6db0dc8f4603ad3db7f093f4e9021f34f7 SHA1 f0c03e0afe2daff84eec888c2025568628210358 SHA256 359c6201937e91ad9f78cbac07a7e74e467582400de16049eba0fbb30aad1a86 AUX heimdal_testsuite.patch 11928 RMD160 4e5f3277b07b8c0dd08d8518e381d9d21c296332 SHA1 e9e35a7306f4c59d05a0934b41a192faaa638a6b SHA256 0edb8be49749b27c37d8a19d7129f52dde26a17cc029d541042e568b39fe1db3 AUX heimdal_testsuite_extra.patch 2352 RMD160 1f2dd032c995d672d376821060ea10684720c5ad SHA1 5537e1d96bc5509c987a2ea75df8dc3d3a5a1cb8 SHA256 301a27f3b36e00ca289d35c3554c4f03f1688e5e16a883b15a3d75180f9c8052 AUX krb5.conf 424 RMD160 80a0159824b8a44698d97d911c701bb05f2f0688 SHA1 7602cc72576d144429cae5cf568feb25a5906ab7 SHA256 3acbae7a561b0a76c90ab53f41d5ffb5b811a39049c5ed15b1e7a34e8c889c6e @@ -26,13 +24,7 @@ DIST heimdal-gentoo-patches-0.2.tar.bz2 5215 RMD160 f6b87d3caf8f156fdcf7c61542ea EBUILD heimdal-1.2.1-r1.ebuild 4237 RMD160 4b3f562242cf2eabcaaeab583223b90cd38cb23d SHA1 db55235d6a779c80cff7ef11f09f6e033d397043 SHA256 e14cc0cacb4edc26c3df8366a40fbabd8ab444c1e2b4d6d37fdec9f0ed8d5cbf EBUILD heimdal-1.2.1-r4.ebuild 4064 RMD160 931764a654b3a4fe4aedb6d9163fe6125c959d51 SHA1 b1c3ba453075d6f4d398ce13b2516246a1315f4f SHA256 92eb7771c35730ca33e296a4d9cec6fa867e5df24040a263294d864b84833018 EBUILD heimdal-1.3.2-r1.ebuild 2637 RMD160 b65f56b535b931375948fe47a16fc2ed4ae70e28 SHA1 2c94e7eab79c53d2bf7bcf094491e6361c764070 SHA256 c9639dc0714cc0d78ecacf5777c4d7ab1295b63fc3e7590cb99ad9253fde6581 +EBUILD heimdal-1.3.3-r1.ebuild 3150 RMD160 d88ebcb7bfea6a6632d145f5e02a6f380612f530 SHA1 2b0d49690c4b3052aa3d39add21ca6b913f80076 SHA256 977be9abeee76aa27a0ed3d0c45c7cfe7ef95faa55d946fd20a8eaec38a481d7 EBUILD heimdal-1.3.3.ebuild 3096 RMD160 df150b697f170cea3ceb1e576eac4c428b668d61 SHA1 8f6061529478ac3ba24053988e919336766e1a82 SHA256 f00dea19f08f8dd21e8cdfb09c2d948f7c0e3dbda7510ff07fec026c18dfa734 -MISC ChangeLog 25793 RMD160 149fbfc888353a88f8acda9b651cccb0cf3c9b65 SHA1 54a4db9bb804efe7a45ba0354e1dcf02eeaeff29 SHA256 0c7435b69ff80aea05cad5b3beaba027902ae2eecc4fd5c41530db124eae8a0b +MISC ChangeLog 26014 RMD160 a36a8e1d803a7aa508719a950d902c457633fa04 SHA1 e9bc830d4fe073b0419abc67a772aed8c7f0296e SHA256 2f6ad5138a19be360a8864c02b061b531c0dc97f0aa310eb108e6f309b0b69eb MISC metadata.xml 923 RMD160 47b35a8f1efeaa17ac7104932a7ac75fa58b2f48 SHA1 82f3c37e41de86ca104a021461613a23680b86cb SHA256 f3eb7cc9ed2e70bdf91b8b1817f352a9eb0ce22e8a026510250b064040e18a3b ------BEGIN PGP SIGNATURE----- -Version: GnuPG v2.0.15 (GNU/Linux) - -iF4EAREIAAYFAkwigNcACgkQmWq1bYTyC0NWxQEAn2LGjMAyk2UNuMFyLzdHcwQK -0rW1mNfprNwooP4wFrUBAJjQxXcHQZWw2hee04W2wrac3uwtofiW/M++b0ZPHsyl -=WJfz ------END PGP SIGNATURE----- diff --git a/app-crypt/heimdal/files/heimdal_openssl-1.patch b/app-crypt/heimdal/files/heimdal_openssl-1.patch new file mode 100644 index 000000000000..548056c8588c --- /dev/null +++ b/app-crypt/heimdal/files/heimdal_openssl-1.patch @@ -0,0 +1,174 @@ +http://git.frugalware.org/gitweb/gitweb.cgi?p=frugalware-current.git;a=blob_plain;f=source/lib/heimdal/drop_md2_support.diff;hb=HEAD + +--- include/crypto-headers.h ++++ include/crypto-headers.h +@@ -13,7 +13,6 @@ + #include + #include + #include +-#include + #include + #include + #include +@@ -39,7 +38,6 @@ + + #include + #include +-#include + #include + #include + #include +--- lib/hx509/crypto.c ++++ lib/hx509/crypto.c +@@ -148,11 +148,6 @@ + { 6, rk_UNCONST(md5_oid_tree) }, rk_UNCONST(&null_entry_oid) + }; + +-static const unsigned md2_oid_tree[] = { 1, 2, 840, 113549, 2, 2 }; +-const AlgorithmIdentifier _hx509_signature_md2_data = { +- { 6, rk_UNCONST(md2_oid_tree) }, rk_UNCONST(&null_entry_oid) +-}; +- + static const unsigned ecPublicKey[] ={ 1, 2, 840, 10045, 2, 1 }; + const AlgorithmIdentifier _hx509_signature_ecPublicKey = { + { 6, rk_UNCONST(ecPublicKey) }, NULL +@@ -193,11 +188,6 @@ + { 7, rk_UNCONST(rsa_with_md5_oid) }, NULL + }; + +-static const unsigned rsa_with_md2_oid[] ={ 1, 2, 840, 113549, 1, 1, 2 }; +-const AlgorithmIdentifier _hx509_signature_rsa_with_md2_data = { +- { 7, rk_UNCONST(rsa_with_md2_oid) }, NULL +-}; +- + static const unsigned rsa_oid[] ={ 1, 2, 840, 113549, 1, 1, 1 }; + const AlgorithmIdentifier _hx509_signature_rsa_data = { + { 7, rk_UNCONST(rsa_oid) }, NULL +@@ -1289,19 +1279,6 @@ + rsa_create_signature + }; + +-static const struct signature_alg rsa_with_md2_alg = { +- "rsa-with-md2", +- &asn1_oid_id_pkcs1_md2WithRSAEncryption, +- &_hx509_signature_rsa_with_md2_data, +- &asn1_oid_id_pkcs1_rsaEncryption, +- &_hx509_signature_md2_data, +- PROVIDE_CONF|REQUIRE_SIGNER|RA_RSA_USES_DIGEST_INFO|SIG_PUBLIC_SIG, +- 1230739889, +- NULL, +- rsa_verify_signature, +- rsa_create_signature +-}; +- + static const struct signature_alg dsa_sha1_alg = { + "dsa-with-sha1", + &asn1_oid_id_dsa_with_sha1, +@@ -1354,19 +1331,6 @@ + NULL + }; + +-static const struct signature_alg md2_alg = { +- "rsa-md2", +- &asn1_oid_id_rsa_digest_md2, +- &_hx509_signature_md2_data, +- NULL, +- NULL, +- SIG_DIGEST, +- 0, +- EVP_md2, +- evp_md_verify_signature, +- NULL +-}; +- + /* + * Order matter in this structure, "best" first for each "key + * compatible" type (type is ECDSA, RSA, DSA, none, etc) +@@ -1381,13 +1345,11 @@ + &rsa_with_sha1_alg, + &pkcs1_rsa_sha1_alg, + &rsa_with_md5_alg, +- &rsa_with_md2_alg, + &heim_rsa_pkcs1_x509, + &dsa_sha1_alg, + &sha256_alg, + &sha1_alg, + &md5_alg, +- &md2_alg, + NULL + }; + +@@ -1823,10 +1785,6 @@ + { return &_hx509_signature_md5_data; } + + const AlgorithmIdentifier * +-hx509_signature_md2(void) +-{ return &_hx509_signature_md2_data; } +- +-const AlgorithmIdentifier * + hx509_signature_ecPublicKey(void) + { return &_hx509_signature_ecPublicKey; } + +@@ -1859,10 +1817,6 @@ + { return &_hx509_signature_rsa_with_md5_data; } + + const AlgorithmIdentifier * +-hx509_signature_rsa_with_md2(void) +-{ return &_hx509_signature_rsa_with_md2_data; } +- +-const AlgorithmIdentifier * + hx509_signature_rsa(void) + { return &_hx509_signature_rsa_data; } + +--- lib/hx509/hx509-protos.h ++++ lib/hx509/hx509-protos.h +@@ -976,9 +976,6 @@ + hx509_signature_ecdsa_with_sha256 (void); + + const AlgorithmIdentifier * +-hx509_signature_md2 (void); +- +-const AlgorithmIdentifier * + hx509_signature_md5 (void); + + const AlgorithmIdentifier * +@@ -988,9 +985,6 @@ + hx509_signature_rsa_pkcs1_x509 (void); + + const AlgorithmIdentifier * +-hx509_signature_rsa_with_md2 (void); +- +-const AlgorithmIdentifier * + hx509_signature_rsa_with_md5 (void); + + const AlgorithmIdentifier * +--- lib/hx509/ks_p11.c ++++ lib/hx509/ks_p11.c +@@ -1139,7 +1139,6 @@ + MECHNAME(CKM_SHA256, "sha256"); + MECHNAME(CKM_SHA_1, "sha1"); + MECHNAME(CKM_MD5, "md5"); +- MECHNAME(CKM_MD2, "md2"); + MECHNAME(CKM_RIPEMD160, "ripemd-160"); + MECHNAME(CKM_DES_ECB, "des-ecb"); + MECHNAME(CKM_DES_CBC, "des-cbc"); +--- lib/hx509/tst-crypto-available2 ++++ lib/hx509/tst-crypto-available2 +@@ -1,4 +1,3 @@ + 2.16.840.1.101.3.4.2.1 + 1.3.14.3.2.26 + 1.2.840.113549.2.5 +-1.2.840.113549.2.2 +--- lib/hx509/version-script.map ++++ lib/hx509/version-script.map +@@ -200,10 +200,8 @@ + hx509_revoke_verify; + hx509_set_error_string; + hx509_set_error_stringv; +- hx509_signature_md2; + hx509_signature_md5; + hx509_signature_rsa; +- hx509_signature_rsa_with_md2; + hx509_signature_rsa_with_md5; + hx509_signature_rsa_with_sha1; + hx509_signature_rsa_with_sha256; diff --git a/app-crypt/heimdal/heimdal-1.3.3-r1.ebuild b/app-crypt/heimdal/heimdal-1.3.3-r1.ebuild new file mode 100644 index 000000000000..7bff48b3e4b2 --- /dev/null +++ b/app-crypt/heimdal/heimdal-1.3.3-r1.ebuild @@ -0,0 +1,122 @@ +# Copyright 1999-2010 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/app-crypt/heimdal/heimdal-1.3.3-r1.ebuild,v 1.1 2010/07/11 10:05:41 ssuominen Exp $ + +EAPI=2 +VIRTUALX_REQUIRED="manual" + +inherit libtool virtualx eutils toolchain-funcs + +#RESTRICT="test" + +DESCRIPTION="Kerberos 5 implementation from KTH" +HOMEPAGE="http://www.h5l.org/" +SRC_URI="http://www.h5l.org/dist/src/${P}.tar.gz" + +LICENSE="BSD" +SLOT="0" +KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86" +IUSE="afs +berkdb hdb-ldap ipv6 otp pkinit ssl threads test X" + +RDEPEND="ssl? ( dev-libs/openssl ) + berkdb? ( sys-libs/db ) + !berkdb? ( sys-libs/gdbm ) + >=dev-db/sqlite-3.5.7 + >=sys-libs/e2fsprogs-libs-1.41.11 + afs? ( net-fs/openafs ) + hdb-ldap? ( >=net-nds/openldap-2.3.0 ) + !virtual/krb5" + +DEPEND="${RDEPEND} + dev-util/pkgconfig + >=sys-devel/autoconf-2.62 + test? ( X? ( ${VIRTUALX_DEPEND} ) )" + +PROVIDE="virtual/krb5" + +src_prepare() { + epatch "${FILESDIR}/heimdal_db5.patch" + epatch "${FILESDIR}/heimdal_testsuite.patch" + epatch "${FILESDIR}/heimdal_testsuite_extra.patch" + epatch "${FILESDIR}/heimdal_disable-check-iprop.patch" + epatch "${FILESDIR}/heimdal_openssl-1.patch" +} + +src_configure() { + econf \ + --enable-kcm \ + --disable-osfc2 \ + --enable-shared \ + --with-libintl=/usr \ + --with-readline=/usr \ + --with-sqlite3=/usr \ + --libexecdir=/usr/sbin \ + $(use_enable afs afs-support) \ + $(use_enable berkdb berkeley-db) \ + $(use_enable otp) \ + $(use_enable pkinit kx509) \ + $(use_enable pkinit pk-init) \ + $(use_enable threads pthread-support) \ + $(use_with hdb-ldap openldap /usr) \ + $(use_with ipv6) \ + $(use_with ssl openssl /usr) \ + $(use_with X x) +} + +src_compile() { + emake -j1 || die "emake failed" +} + +src_test() { + einfo "Disabled check-iprop which is known to fail. Other tests should work." + default_src_test +} + +src_install() { + INSTALL_CATPAGES="no" emake DESTDIR="${D}" install || die "emake install failed" + + dodoc ChangeLog README NEWS TODO + + # Begin client rename and install + for i in {telnetd,ftpd,rshd,popper} + do + mv "${D}"/usr/share/man/man8/{,k}${i}.8 + mv "${D}"/usr/sbin/{,k}${i} + done + + for i in {rcp,rsh,telnet,ftp,su,login,pagsh,kf} + do + mv "${D}"/usr/share/man/man1/{,k}${i}.1 + mv "${D}"/usr/bin/{,k}${i} + done + + mv "${D}"/usr/share/man/man5/{,k}ftpusers.5 + mv "${D}"/usr/share/man/man5/{,k}login.access.5 + + newinitd "${FILESDIR}"/heimdal-kdc.initd heimdal-kdc + newinitd "${FILESDIR}"/heimdal-kadmind.initd heimdal-kadmind + newinitd "${FILESDIR}"/heimdal-kpasswdd.initd heimdal-kpasswdd + newinitd "${FILESDIR}"/heimdal-kcm.initd heimdal-kcm + + insinto /etc + newins "${FILESDIR}"/krb5.conf krb5.conf.example + + if use hdb-ldap; then + insinto /etc/openldap/schema + doins "${S}/lib/hdb/hdb.schema" + fi + + # default database dir + keepdir /var/heimdal +} + +pkg_preinst() { + + if has_version "=${CATEGORY}/${PN}-1.3.2*" ; then + if use hdb-ldap ; then + ewarn "Schema name changed to hdb.schema to follow upstream." + ewarn "Please check you slapd conf file to make sure" + ewarn "that the correct schema file is included." + fi + fi +} -- 2.26.2