From 0ea6aa41a265048b4b87bae6c7ee610372ef93f4 Mon Sep 17 00:00:00 2001 From: "Andrew J. Hesford" Date: Mon, 9 Nov 2020 20:03:27 -0500 Subject: [PATCH] libimobiledevice: update to 1.3.0. --- common/shlibs | 2 +- .../patches/CVE-2016-5104.patch | 32 ------------------- srcpkgs/libimobiledevice/template | 23 +++++++------ 3 files changed, 15 insertions(+), 42 deletions(-) delete mode 100644 srcpkgs/libimobiledevice/patches/CVE-2016-5104.patch diff --git a/common/shlibs b/common/shlibs index 8f415b57c5b..95e6569d298 100644 --- a/common/shlibs +++ b/common/shlibs @@ -2040,7 +2040,7 @@ libnpth.so.0 npth-1.1_1 libnpupnp.so.4 libnpupnp-4.0.2_1 libglfw.so.3 glfw-3.0.4_1 libusbmuxd-2.0.so.6 libusbmuxd-2.0.2_1 -libimobiledevice.so.6 libimobiledevice-1.2.0_1 +libimobiledevice-1.0.so.6 libimobiledevice-1.3.0_1 libstfl.so.0 stfl-0.23_1 libCDApplet.so cairo-dock-plugins-3.4.0_1 libldns.so.3 libldns-1.7.1_1 diff --git a/srcpkgs/libimobiledevice/patches/CVE-2016-5104.patch b/srcpkgs/libimobiledevice/patches/CVE-2016-5104.patch deleted file mode 100644 index f9b5e12a4fd..00000000000 --- a/srcpkgs/libimobiledevice/patches/CVE-2016-5104.patch +++ /dev/null @@ -1,32 +0,0 @@ -From df1f5c4d70d0c19ad40072f5246ca457e7f9849e Mon Sep 17 00:00:00 2001 -From: Joshua Hill -Date: Tue, 29 Dec 2015 22:27:17 +0100 -Subject: [PATCH] common: [security fix] Make sure sockets only listen locally - ---- - common/socket.c | 4 ++-- - 1 file changed, 2 insertions(+), 2 deletions(-) - -diff --git a/common/socket.c b/common/socket.c -index b276864e..e2968a64 100644 ---- common/socket.c -+++ common/socket.c -@@ -172,7 +172,7 @@ int socket_create(uint16_t port) - - memset((void *) &saddr, 0, sizeof(saddr)); - saddr.sin_family = AF_INET; -- saddr.sin_addr.s_addr = htonl(INADDR_ANY); -+ saddr.sin_addr.s_addr = htonl(INADDR_LOOPBACK); - saddr.sin_port = htons(port); - - if (0 > bind(sfd, (struct sockaddr *) &saddr, sizeof(saddr))) { -@@ -329,7 +329,7 @@ int socket_accept(int fd, uint16_t port) - - memset(&addr, 0, sizeof(addr)); - addr.sin_family = AF_INET; -- addr.sin_addr.s_addr = htonl(INADDR_ANY); -+ addr.sin_addr.s_addr = htonl(INADDR_LOOPBACK); - addr.sin_port = htons(port); - - addr_len = sizeof(addr); - diff --git a/srcpkgs/libimobiledevice/template b/srcpkgs/libimobiledevice/template index 4e99e7a9cd9..43fbd4531b7 100644 --- a/srcpkgs/libimobiledevice/template +++ b/srcpkgs/libimobiledevice/template @@ -1,26 +1,31 @@ # Template file for 'libimobiledevice' pkgname=libimobiledevice -version=1.2.0 -revision=17 +version=1.3.0 +revision=1 build_style=gnu-configure hostmakedepends="automake libtool pkgconf python3-Cython" -makedepends="python3-devel libglib-devel libressl-devel libusb-devel - libplist-devel libusbmuxd-devel" +makedepends="python3-devel libglib-devel libressl-devel + libusb-devel libplist-devel libusbmuxd-devel" short_desc="Library to communicate with Apple devices" maintainer="Orphaned " license="LGPL-2.1-only" -homepage="https://github.com/libimobiledevice/libimobiledevice" +homepage="https://libimobiledevice.org" +changelog="https://raw.githubusercontent.com/libimobiledevice/libimobiledevice/master/NEWS" distfiles="https://github.com/libimobiledevice/libimobiledevice/archive/${version}.tar.gz" -checksum=8ba1ea817691b3548b83371f8ec22d73d1e37f8fda7c899ac9c7121d924ca830 +checksum=acbfb73eabee162e64c0d9de207d71c0a5f47c40cd5ad32a5097f734328ce10a if [ "$CROSS_BUILD" ]; then configure_args="ac_cv_sys_file_offset_bits=yes ac_cv_sys_large_file=yes" fi +post_patch() { + # LibreSSL does not provide this function + vsed -e '/SSL_CTX_set_security_level/d' -i src/idevice.c + vsed -e 's,-L$(libdir),,g' -i cython/Makefile.am +} + pre_configure() { - sed -i 's,SSLv3_,SSLv23_,g' src/idevice.c - sed -i 's,-L$(libdir),,g' cython/Makefile.am - export PYTHON_CPPFLAGS="-I${XBPS_CROSS_BASE}/usr/include/python${py3_ver}" + export PYTHON_CPPFLAGS="-I${XBPS_CROSS_BASE}/${py3_inc}" export PYTHON_LDFLAGS="-L${XBPS_CROSS_BASE}/usr/lib -lpython${py3_ver}" autoreconf -fi }