diff --git a/sysutils/ipmitool/Makefile b/sysutils/ipmitool/Makefile index f8189c0f8767..52eb12ff552f 100644 --- a/sysutils/ipmitool/Makefile +++ b/sysutils/ipmitool/Makefile @@ -1,14 +1,21 @@ -# $NetBSD: Makefile,v 1.25 2020/12/23 05:39:47 mlelstv Exp $ +# $NetBSD: Makefile,v 1.26 2023/05/18 08:43:20 spz Exp $ # -DISTNAME= ipmitool-1.8.18 -PKGREVISION= 4 +DISTNAME= IPMITOOL_1_8_19 +PKGNAME= ipmitool-1.8.19 CATEGORIES= sysutils -MASTER_SITES= ${MASTER_SITE_SOURCEFORGE:=ipmitool/} +MASTER_SITES= ${MASTER_SITE_GITHUB:=ipmitool/} +GITHUB_PROJECT= ipmitool +GITHUB_TAG= IPMITOOL_1_8_19 +WRKSRC= ${WRKDIR}/ipmitool-${GITHUB_TAG} MAINTAINER= pkgsrc-users@NetBSD.org -HOMEPAGE= http://ipmitool.sourceforge.net/ +HOMEPAGE= https://github.com/ipmitool/ipmitool COMMENT= Command-line utility for managing IPMI devices +LICENSE= modified-bsd + +USE_TOOLS= automake autoconf +USE_LIBTOOL= yes GNU_CONFIGURE= yes INSTALLATION_DIRS+= share/examples/ipmitool share/doc/ipmitool @@ -19,6 +26,11 @@ CONFIGURE_ARGS.SunOS+= --enable-solaris-opt CFLAGS.NetBSD+= -D_NETBSD_SOURCE +DEPENDS+= iana-enterprise-numbers-[0-9]*:../../net/iana-enterprise-numbers + +pre-configure: + cd ${WRKSRC} && ./bootstrap + # ipmitool uses rl_event_hook .include "../../devel/readline/buildlink3.mk" .include "../../security/openssl/buildlink3.mk" diff --git a/sysutils/ipmitool/PLIST b/sysutils/ipmitool/PLIST index 793cab6d8c37..d6dbed2da499 100644 --- a/sysutils/ipmitool/PLIST +++ b/sysutils/ipmitool/PLIST @@ -1,4 +1,4 @@ -@comment $NetBSD: PLIST,v 1.5 2011/02/17 08:38:56 markd Exp $ +@comment $NetBSD: PLIST,v 1.6 2023/05/18 08:43:20 spz Exp $ bin/ipmitool man/man1/ipmitool.1 man/man8/ipmievd.8 @@ -7,4 +7,4 @@ share/doc/ipmitool/AUTHORS share/doc/ipmitool/COPYING share/doc/ipmitool/ChangeLog share/doc/ipmitool/README -share/examples/ipmitool/oem_ibm_sel_map +share/ipmitool/oem_ibm_sel_map diff --git a/sysutils/ipmitool/distinfo b/sysutils/ipmitool/distinfo index a7241186943a..1231f9905e86 100644 --- a/sysutils/ipmitool/distinfo +++ b/sysutils/ipmitool/distinfo @@ -1,10 +1,7 @@ -$NetBSD: distinfo,v 1.13 2021/10/26 11:19:43 nia Exp $ +$NetBSD: distinfo,v 1.14 2023/05/18 08:43:20 spz Exp $ -BLAKE2s (ipmitool-1.8.18.tar.gz) = cc57ed59520bd0e40bc6d8225733797864400f12d46d003d8deb3da87682cb9f -SHA512 (ipmitool-1.8.18.tar.gz) = 274d424fff079f7628c0f9fe06580937cb9717c809a71b2f5ef97266c6b6c89983b662fbb1f090e2f94861f1799677c8fc6536013828a8a5e6cb239af53e45ab -Size (ipmitool-1.8.18.tar.gz) = 995313 bytes -SHA1 (patch-ad) = 4af586b36f1744d263c66ed28aa17a9f9840a415 -SHA1 (patch-ae) = 67828b62b46a30b204dd436681c5ecac39bb29b3 -SHA1 (patch-lib_ipmi__cfgp.c) = 3b16d340fce1bdaee66b15430c25f19f4d38ae08 -SHA1 (patch-lib_ipmi__main.c) = 4d90e86dda16ea0b596573d88833e348c11ffb24 -SHA1 (patch-src_plugins_lanplus_lanplus__crypt__impl.c) = 8aaa1c6328bd6c0559ae9863cad671cdd32ab514 +BLAKE2s (IPMITOOL_1_8_19.tar.gz) = 445528e00b5db7d975cf049e20a46ebbe2b2e1fafa6ac5ca7f47064a8217a37a +SHA512 (IPMITOOL_1_8_19.tar.gz) = 2d91706e9feba4b2ce4808eca087b81b842c4292a5840830001919c06ec8babd8f8761b74bb9dcf8fbc7765f028a5b1a192a3c1b643f2adaa157fed6fb0d1ee3 +Size (IPMITOOL_1_8_19.tar.gz) = 641383 bytes +SHA1 (patch-ae) = 6819a2a50d9c0a5f33e60b2f73e436ee43dbb717 +SHA1 (patch-configure.ac) = 54ffa45c8c518d2ded4c878cdbf81e9dc514bef4 diff --git a/sysutils/ipmitool/patches/patch-ad b/sysutils/ipmitool/patches/patch-ad deleted file mode 100644 index 737264825411..000000000000 --- a/sysutils/ipmitool/patches/patch-ad +++ /dev/null @@ -1,13 +0,0 @@ -$NetBSD: patch-ad,v 1.3 2017/12/22 21:45:23 markd Exp $ - ---- contrib/Makefile.in.orig 2016-10-08 08:11:34.000000000 +0000 -+++ contrib/Makefile.in -@@ -90,7 +90,7 @@ am__make_running_with_option = \ - test $$has_opt = yes - am__make_dryrun = (target_option=n; $(am__make_running_with_option)) - am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) --pkgdatadir = $(datadir)/@PACKAGE@ -+pkgdatadir = $(datadir)/examples/@PACKAGE@ - pkgincludedir = $(includedir)/@PACKAGE@ - pkglibdir = $(libdir)/@PACKAGE@ - pkglibexecdir = $(libexecdir)/@PACKAGE@ diff --git a/sysutils/ipmitool/patches/patch-ae b/sysutils/ipmitool/patches/patch-ae index da6e976b6716..164c9316354b 100644 --- a/sysutils/ipmitool/patches/patch-ae +++ b/sysutils/ipmitool/patches/patch-ae @@ -1,13 +1,13 @@ -$NetBSD: patch-ae,v 1.1 2011/12/22 19:00:05 drochner Exp $ +$NetBSD: patch-ae,v 1.2 2023/05/18 08:43:20 spz Exp $ CVE-2011-4339 ---- lib/helper.c.orig 2009-02-25 20:38:52.000000000 +0000 +--- lib/helper.c.orig 2022-09-01 18:42:31.000000000 +0000 +++ lib/helper.c -@@ -427,7 +427,6 @@ ipmi_start_daemon(struct ipmi_intf *intf - #endif - - chdir("/"); +@@ -917,7 +917,6 @@ ipmi_start_daemon(struct ipmi_intf *intf + lprintf(LOG_ERR, "chdir failed: %s (%d)", strerror(errno), errno); + exit(1); + } - umask(0); for (fd=0; fd<64; fd++) { diff --git a/sysutils/ipmitool/patches/patch-configure.ac b/sysutils/ipmitool/patches/patch-configure.ac new file mode 100644 index 000000000000..399f88a143aa --- /dev/null +++ b/sysutils/ipmitool/patches/patch-configure.ac @@ -0,0 +1,30 @@ +$NetBSD: patch-configure.ac,v 1.1 2023/05/18 08:43:20 spz Exp $ + +avoid downloading files in the install phase, +depend on net/iana-enterprise-numbers instead + +--- configure.ac.orig 2022-09-01 18:42:31.000000000 +0000 ++++ configure.ac +@@ -56,21 +56,7 @@ if test "x$exec_prefix" = "xNONE"; then + exec_prefix="$prefix" + fi + +-if test "x$WGET" = "x"; then +- if test "x$CURL" = "x"; then +- AC_MSG_WARN([** Neither wget nor curl could be found.]) +- AC_MSG_WARN([** IANA PEN database will not be installed by `make install` !]) +- else +- DOWNLOAD="$CURL --location --progress-bar" +- AM_CONDITIONAL([DOWNLOAD], [true]) +- fi +-else +- DOWNLOAD="$WGET -c -nd -O -" +- AM_CONDITIONAL([DOWNLOAD], [true]) +-fi +- +-AC_MSG_WARN([** Download is:]) +-AC_MSG_WARN($DOWNLOAD) ++AM_CONDITIONAL([DOWNLOAD], [false]) + AC_SUBST(DOWNLOAD, $DOWNLOAD) + + dnl diff --git a/sysutils/ipmitool/patches/patch-lib_ipmi__cfgp.c b/sysutils/ipmitool/patches/patch-lib_ipmi__cfgp.c deleted file mode 100644 index 5d0300ce0e3e..000000000000 --- a/sysutils/ipmitool/patches/patch-lib_ipmi__cfgp.c +++ /dev/null @@ -1,15 +0,0 @@ -$NetBSD: patch-lib_ipmi__cfgp.c,v 1.1 2018/01/08 22:37:57 jperkin Exp $ - -Spell stdlib.h correctly. - ---- lib/ipmi_cfgp.c.orig 2016-08-21 06:59:27.000000000 +0000 -+++ lib/ipmi_cfgp.c -@@ -30,7 +30,7 @@ - * POSSIBILITY OF SUCH DAMAGE. - */ - --#include -+#include - #include - - #include diff --git a/sysutils/ipmitool/patches/patch-lib_ipmi__main.c b/sysutils/ipmitool/patches/patch-lib_ipmi__main.c deleted file mode 100644 index 743ef3bad4de..000000000000 --- a/sysutils/ipmitool/patches/patch-lib_ipmi__main.c +++ /dev/null @@ -1,20 +0,0 @@ -$NetBSD: patch-lib_ipmi__main.c,v 1.1 2018/09/06 09:47:02 jperkin Exp $ - -Avoid defines that result in getpass() failures on Darwin. - ---- lib/ipmi_main.c.orig 2016-07-31 06:56:33.000000000 +0000 -+++ lib/ipmi_main.c -@@ -29,11 +29,13 @@ - * LIABILITY, ARISING OUT OF THE USE OF OR INABILITY TO USE THIS SOFTWARE, - * EVEN IF SUN HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. - */ -+#if !defined(__APPLE__) - #define _XOPEN_SOURCE 700 - #define _BSD_SOURCE || \ - (_XOPEN_SOURCE >= 500 || \ - _XOPEN_SOURCE && _XOPEN_SOURCE_EXTENDED) && \ - !(_POSIX_C_SOURCE >= 200112L || _XOPEN_SOURCE >= 600) -+#endif - - #include - #include diff --git a/sysutils/ipmitool/patches/patch-src_plugins_lanplus_lanplus__crypt__impl.c b/sysutils/ipmitool/patches/patch-src_plugins_lanplus_lanplus__crypt__impl.c deleted file mode 100644 index 4818117b6b50..000000000000 --- a/sysutils/ipmitool/patches/patch-src_plugins_lanplus_lanplus__crypt__impl.c +++ /dev/null @@ -1,90 +0,0 @@ -$NetBSD: patch-src_plugins_lanplus_lanplus__crypt__impl.c,v 1.1 2017/12/22 21:45:23 markd Exp $ - ---- src/plugins/lanplus/lanplus_crypt_impl.c 2016-05-28 10:20:20.000000000 +0200 -+++ src/plugins/lanplus/lanplus_crypt_impl.c 2017-02-21 10:50:21.634873466 +0100 -@@ -164,10 +164,10 @@ lanplus_encrypt_aes_cbc_128(const uint8_ - uint8_t * output, - uint32_t * bytes_written) - { -- EVP_CIPHER_CTX ctx; -- EVP_CIPHER_CTX_init(&ctx); -- EVP_EncryptInit_ex(&ctx, EVP_aes_128_cbc(), NULL, key, iv); -- EVP_CIPHER_CTX_set_padding(&ctx, 0); -+ EVP_CIPHER_CTX *ctx = EVP_CIPHER_CTX_new(); -+ EVP_CIPHER_CTX_init(ctx); -+ EVP_EncryptInit_ex(ctx, EVP_aes_128_cbc(), NULL, key, iv); -+ EVP_CIPHER_CTX_set_padding(ctx, 0); - - - *bytes_written = 0; -@@ -191,7 +191,7 @@ lanplus_encrypt_aes_cbc_128(const uint8_ - assert((input_length % IPMI_CRYPT_AES_CBC_128_BLOCK_SIZE) == 0); - - -- if(!EVP_EncryptUpdate(&ctx, output, (int *)bytes_written, input, input_length)) -+ if(!EVP_EncryptUpdate(ctx, output, (int *)bytes_written, input, input_length)) - { - /* Error */ - *bytes_written = 0; -@@ -201,7 +201,7 @@ lanplus_encrypt_aes_cbc_128(const uint8_ - { - uint32_t tmplen; - -- if(!EVP_EncryptFinal_ex(&ctx, output + *bytes_written, (int *)&tmplen)) -+ if(!EVP_EncryptFinal_ex(ctx, output + *bytes_written, (int *)&tmplen)) - { - *bytes_written = 0; - return; /* Error */ -@@ -210,7 +210,8 @@ lanplus_encrypt_aes_cbc_128(const uint8_ - { - /* Success */ - *bytes_written += tmplen; -- EVP_CIPHER_CTX_cleanup(&ctx); -+ EVP_CIPHER_CTX_cleanup(ctx); -+ EVP_CIPHER_CTX_free(ctx); - } - } - } -@@ -239,10 +240,10 @@ lanplus_decrypt_aes_cbc_128(const uint8_ - uint8_t * output, - uint32_t * bytes_written) - { -- EVP_CIPHER_CTX ctx; -- EVP_CIPHER_CTX_init(&ctx); -- EVP_DecryptInit_ex(&ctx, EVP_aes_128_cbc(), NULL, key, iv); -- EVP_CIPHER_CTX_set_padding(&ctx, 0); -+ EVP_CIPHER_CTX *ctx = EVP_CIPHER_CTX_new(); -+ EVP_CIPHER_CTX_init(ctx); -+ EVP_DecryptInit_ex(ctx, EVP_aes_128_cbc(), NULL, key, iv); -+ EVP_CIPHER_CTX_set_padding(ctx, 0); - - - if (verbose >= 5) -@@ -266,7 +267,7 @@ lanplus_decrypt_aes_cbc_128(const uint8_ - assert((input_length % IPMI_CRYPT_AES_CBC_128_BLOCK_SIZE) == 0); - - -- if (!EVP_DecryptUpdate(&ctx, output, (int *)bytes_written, input, input_length)) -+ if (!EVP_DecryptUpdate(ctx, output, (int *)bytes_written, input, input_length)) - { - /* Error */ - lprintf(LOG_DEBUG, "ERROR: decrypt update failed"); -@@ -277,7 +278,7 @@ lanplus_decrypt_aes_cbc_128(const uint8_ - { - uint32_t tmplen; - -- if (!EVP_DecryptFinal_ex(&ctx, output + *bytes_written, (int *)&tmplen)) -+ if (!EVP_DecryptFinal_ex(ctx, output + *bytes_written, (int *)&tmplen)) - { - char buffer[1000]; - ERR_error_string(ERR_get_error(), buffer); -@@ -290,7 +291,8 @@ lanplus_decrypt_aes_cbc_128(const uint8_ - { - /* Success */ - *bytes_written += tmplen; -- EVP_CIPHER_CTX_cleanup(&ctx); -+ EVP_CIPHER_CTX_cleanup(ctx); -+ EVP_CIPHER_CTX_free(ctx); - } - } -