mirror of
https://github.com/archlinuxarm/PKGBUILDs.git
synced 2024-09-19 22:08:32 +00:00
core/mkinitcpio-busybox to 1.33.1-1
This commit is contained in:
parent
23971545ec
commit
e6845b5a53
|
@ -1,50 +0,0 @@
|
|||
From 883cdb79a440d0425766f67aaef0cabde0a5060e Mon Sep 17 00:00:00 2001
|
||||
From: Denys Vlasenko <vda.linux@googlemail.com>
|
||||
Date: Sat, 9 Jan 2021 08:27:37 +0100
|
||||
Subject: ash: fix ${unset_var/pattern/repl}
|
||||
|
||||
function old new delta
|
||||
subevalvar 1349 1353 +4
|
||||
|
||||
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
|
||||
---
|
||||
shell/ash.c | 3 ++-
|
||||
shell/ash_test/ash-vars/var_bash_repl_empty_var.right | 1 +
|
||||
shell/ash_test/ash-vars/var_bash_repl_empty_var.tests | 2 ++
|
||||
3 files changed, 5 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/shell/ash.c b/shell/ash.c
|
||||
index 37f9dd71b..76bf39ec2 100644
|
||||
--- a/shell/ash.c
|
||||
+++ b/shell/ash.c
|
||||
@@ -7015,7 +7015,8 @@ subevalvar(char *start, char *str, int strloc,
|
||||
slash_pos = -1;
|
||||
if (repl) {
|
||||
slash_pos = expdest - ((char *)stackblock() + strloc);
|
||||
- STPUTC('/', expdest);
|
||||
+ if (!(flag & EXP_DISCARD))
|
||||
+ STPUTC('/', expdest);
|
||||
//bb_error_msg("repl+1:'%s'", repl + 1);
|
||||
p = argstr(repl + 1, (flag & EXP_DISCARD) | EXP_TILDE); /* EXP_TILDE: echo "${v/x/~}" expands ~ ! */
|
||||
*repl = '/';
|
||||
diff --git a/shell/ash_test/ash-vars/var_bash_repl_empty_var.right b/shell/ash_test/ash-vars/var_bash_repl_empty_var.right
|
||||
index 892916783..cf8f088c1 100644
|
||||
--- a/shell/ash_test/ash-vars/var_bash_repl_empty_var.right
|
||||
+++ b/shell/ash_test/ash-vars/var_bash_repl_empty_var.right
|
||||
@@ -1,2 +1,3 @@
|
||||
|
||||
+
|
||||
Ok:0
|
||||
diff --git a/shell/ash_test/ash-vars/var_bash_repl_empty_var.tests b/shell/ash_test/ash-vars/var_bash_repl_empty_var.tests
|
||||
index 73a43d38e..22aaba560 100755
|
||||
--- a/shell/ash_test/ash-vars/var_bash_repl_empty_var.tests
|
||||
+++ b/shell/ash_test/ash-vars/var_bash_repl_empty_var.tests
|
||||
@@ -1,3 +1,5 @@
|
||||
+unset v
|
||||
+echo ${v/*/w}
|
||||
v=''
|
||||
echo ${v/*/w}
|
||||
echo Ok:$?
|
||||
--
|
||||
cgit v1.2.1
|
||||
|
|
@ -1,57 +0,0 @@
|
|||
From f25d254dfd4243698c31a4f3153d4ac72aa9e9bd Mon Sep 17 00:00:00 2001
|
||||
From: Samuel Sapalski <samuel.sapalski@nokia.com>
|
||||
Date: Wed, 3 Mar 2021 16:31:22 +0100
|
||||
Subject: [PATCH] decompress_gunzip: Fix DoS if gzip is corrupt
|
||||
|
||||
On certain corrupt gzip files, huft_build will set the error bit on
|
||||
the result pointer. If afterwards abort_unzip is called huft_free
|
||||
might run into a segmentation fault or an invalid pointer to
|
||||
free(p).
|
||||
|
||||
In order to mitigate this, we check in huft_free if the error bit
|
||||
is set and clear it before the linked list is freed.
|
||||
|
||||
Signed-off-by: Samuel Sapalski <samuel.sapalski@nokia.com>
|
||||
Signed-off-by: Peter Kaestle <peter.kaestle@nokia.com>
|
||||
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
|
||||
---
|
||||
archival/libarchive/decompress_gunzip.c | 12 ++++++++++--
|
||||
1 file changed, 10 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/archival/libarchive/decompress_gunzip.c b/archival/libarchive/decompress_gunzip.c
|
||||
index eb3b64930..e93cd5005 100644
|
||||
--- a/archival/libarchive/decompress_gunzip.c
|
||||
+++ b/archival/libarchive/decompress_gunzip.c
|
||||
@@ -220,10 +220,20 @@ static const uint8_t border[] ALIGN1 = {
|
||||
* each table.
|
||||
* t: table to free
|
||||
*/
|
||||
+#define BAD_HUFT(p) ((uintptr_t)(p) & 1)
|
||||
+#define ERR_RET ((huft_t*)(uintptr_t)1)
|
||||
static void huft_free(huft_t *p)
|
||||
{
|
||||
huft_t *q;
|
||||
|
||||
+ /*
|
||||
+ * If 'p' has the error bit set we have to clear it, otherwise we might run
|
||||
+ * into a segmentation fault or an invalid pointer to free(p)
|
||||
+ */
|
||||
+ if (BAD_HUFT(p)) {
|
||||
+ p = (huft_t*)((uintptr_t)(p) ^ (uintptr_t)(ERR_RET));
|
||||
+ }
|
||||
+
|
||||
/* Go through linked list, freeing from the malloced (t[-1]) address. */
|
||||
while (p) {
|
||||
q = (--p)->v.t;
|
||||
@@ -289,8 +299,6 @@ static unsigned fill_bitbuffer(STATE_PARAM unsigned bitbuffer, unsigned *current
|
||||
* or a valid pointer to a Huffman table, ORed with 0x1 if incompete table
|
||||
* is given: "fixed inflate" decoder feeds us such data.
|
||||
*/
|
||||
-#define BAD_HUFT(p) ((uintptr_t)(p) & 1)
|
||||
-#define ERR_RET ((huft_t*)(uintptr_t)1)
|
||||
static huft_t* huft_build(const unsigned *b, const unsigned n,
|
||||
const unsigned s, const struct cp_ext *cp_ext,
|
||||
unsigned *m)
|
||||
--
|
||||
2.31.0
|
||||
|
|
@ -7,8 +7,8 @@
|
|||
# - removed -mtune, changed -march to v8/v7/v6/v5 compat
|
||||
|
||||
pkgname=mkinitcpio-busybox
|
||||
pkgver=1.32.1
|
||||
pkgrel=3
|
||||
pkgver=1.33.1
|
||||
pkgrel=1
|
||||
pkgdesc='Base initramfs tools'
|
||||
arch=(x86_64)
|
||||
url="https://www.busybox.net/"
|
||||
|
@ -16,22 +16,15 @@ license=(GPL)
|
|||
depends=(glibc libxcrypt)
|
||||
options=(!buildflags)
|
||||
source=(https://busybox.net/downloads/busybox-$pkgver.tar.bz2{,.sig}
|
||||
0001-ash-fix-unset_var-pattern-repl.patch
|
||||
0002-decompress_gunzip-Fix-DoS-if-gzip-is-corrupt.patch
|
||||
config)
|
||||
sha256sums=('9d57c4bd33974140fd4111260468af22856f12f5b5ef7c70c8d9b75c712a0dee'
|
||||
sha256sums=('12cec6bd2b16d8a9446dd16130f2b92982f1819f6e1c5f5887b6db03f5660d28'
|
||||
'SKIP'
|
||||
'4e4fb268c51e378a3ad0a12f903a601a136d31cae8b684a51ebabbc9a6cf9250'
|
||||
'cdc11deae6bb32d0994a252d545f6624513f7f46e44e9dca259f243fc87f598f'
|
||||
'81843d10a63f3e29f37560ded54a049b45c8a4b38560bf9489ec4124eead170e')
|
||||
'8ec3581a99a0e28e3b08ae64f3187f6b28ceeacef34c6c98ec74bd07b4703c2e')
|
||||
validpgpkeys=('C9E9416F76E610DBD09D040F47B70C55ACC9965B') # Denis Vlasenko <vda.linux@googlemail.com>
|
||||
|
||||
prepare() {
|
||||
cd "busybox-$pkgver"
|
||||
|
||||
patch -Np1 < ../0001-ash-fix-unset_var-pattern-repl.patch
|
||||
patch -Np1 < ../0002-decompress_gunzip-Fix-DoS-if-gzip-is-corrupt.patch
|
||||
|
||||
if [ ${CARCH} = "aarch64" ]; then
|
||||
ARMCARCH="armv8-a"
|
||||
elif [ ${CARCH} = "armv7h" ]; then
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
#
|
||||
# Automatically generated make config: don't edit
|
||||
# Busybox version: 1.32.1
|
||||
# Busybox version: 1.33.1
|
||||
# Fri May 14 17:47:50 2021
|
||||
#
|
||||
CONFIG_HAVE_DOT_CONFIG=y
|
||||
|
||||
|
@ -35,7 +36,6 @@ CONFIG_BUSYBOX_EXEC_PATH="/bin/busybox"
|
|||
# CONFIG_FEATURE_CLEAN_UP is not set
|
||||
CONFIG_FEATURE_SYSLOG_INFO=y
|
||||
CONFIG_FEATURE_SYSLOG=y
|
||||
CONFIG_PLATFORM_LINUX=y
|
||||
|
||||
#
|
||||
# Build Options
|
||||
|
@ -54,6 +54,7 @@ CONFIG_EXTRA_LDFLAGS=""
|
|||
CONFIG_EXTRA_LDLIBS=""
|
||||
# CONFIG_USE_PORTABLE_CODE is not set
|
||||
CONFIG_STACK_OPTIMIZATION_386=y
|
||||
# CONFIG_STATIC_LIBGCC is not set
|
||||
|
||||
#
|
||||
# Installation Options ("make install" behavior)
|
||||
|
@ -330,6 +331,7 @@ CONFIG_UNIQ=y
|
|||
CONFIG_UNLINK=y
|
||||
# CONFIG_USLEEP is not set
|
||||
# CONFIG_UUDECODE is not set
|
||||
CONFIG_BASE32=y
|
||||
CONFIG_BASE64=y
|
||||
# CONFIG_UUENCODE is not set
|
||||
CONFIG_WC=y
|
||||
|
@ -622,7 +624,6 @@ CONFIG_FSTRIM=y
|
|||
CONFIG_GETOPT=y
|
||||
CONFIG_FEATURE_GETOPT_LONG=y
|
||||
CONFIG_HEXDUMP=y
|
||||
# CONFIG_FEATURE_HEXDUMP_REVERSE is not set
|
||||
# CONFIG_HD is not set
|
||||
CONFIG_XXD=y
|
||||
# CONFIG_HWCLOCK is not set
|
||||
|
@ -710,6 +711,7 @@ CONFIG_FEATURE_MOUNT_LOOP_CREATE=y
|
|||
# CONFIG_FEATURE_VOLUMEID_BCACHE is not set
|
||||
# CONFIG_FEATURE_VOLUMEID_BTRFS is not set
|
||||
# CONFIG_FEATURE_VOLUMEID_CRAMFS is not set
|
||||
# CONFIG_FEATURE_VOLUMEID_EROFS is not set
|
||||
# CONFIG_FEATURE_VOLUMEID_EXFAT is not set
|
||||
# CONFIG_FEATURE_VOLUMEID_EXT is not set
|
||||
# CONFIG_FEATURE_VOLUMEID_F2FS is not set
|
||||
|
@ -869,6 +871,10 @@ CONFIG_FEATURE_PREFER_IPV4_ADDRESS=y
|
|||
# CONFIG_FEATURE_HTTPD_ERROR_PAGES is not set
|
||||
# CONFIG_FEATURE_HTTPD_PROXY is not set
|
||||
# CONFIG_FEATURE_HTTPD_GZIP is not set
|
||||
# CONFIG_FEATURE_HTTPD_ETAG is not set
|
||||
# CONFIG_FEATURE_HTTPD_LAST_MODIFIED is not set
|
||||
# CONFIG_FEATURE_HTTPD_DATE is not set
|
||||
# CONFIG_FEATURE_HTTPD_ACL_IP is not set
|
||||
CONFIG_IFCONFIG=y
|
||||
CONFIG_FEATURE_IFCONFIG_STATUS=y
|
||||
CONFIG_FEATURE_IFCONFIG_SLIP=y
|
||||
|
|
Loading…
Reference in a new issue