diff options
author | PÁLI Gábor János <pali.gabor@gmail.com> | 2023-08-03 10:10:44 +0200 |
---|---|---|
committer | PÁLI Gábor János <pali.gabor@gmail.com> | 2023-09-16 17:58:03 +0200 |
commit | 89279d87c5d3e0ea330be1f927e3f3bc59dbc2a7 (patch) | |
tree | 353bc9a026d0140151e760efbc4f6a6a6b24a020 /aports/busybox/0012-nslookup-sanitize-all-printed-strings-with-printable.patch | |
parent | 084335e136581edc28137b152cc559778224570e (diff) | |
download | freebsd-wifibox-alpine-89279d87c5d3e0ea330be1f927e3f3bc59dbc2a7.zip |
Update to Linux 6.1 and Alpine 3.18
- Update base-layout to 3.4.3
- Update busybox to 1.36.1
- Update iptables to 1.8.9
- Update linux-lts to 6.1.53
- Update to openrc to 0.48
- Update rtl8821ce to snapshot of 20230915
- Replace rtwB88 with a third-party driver
- Update rtw89 to snapshot of 20230913
- Import wpa_supplicant fixes from Arch Linux
Diffstat (limited to 'aports/busybox/0012-nslookup-sanitize-all-printed-strings-with-printable.patch')
-rw-r--r-- | aports/busybox/0012-nslookup-sanitize-all-printed-strings-with-printable.patch | 67 |
1 files changed, 67 insertions, 0 deletions
diff --git a/aports/busybox/0012-nslookup-sanitize-all-printed-strings-with-printable.patch b/aports/busybox/0012-nslookup-sanitize-all-printed-strings-with-printable.patch new file mode 100644 index 0000000..63d72fe --- /dev/null +++ b/aports/busybox/0012-nslookup-sanitize-all-printed-strings-with-printable.patch @@ -0,0 +1,67 @@ +From 2365aa9b62dd703cd279b94ede25ebb274cfe723 Mon Sep 17 00:00:00 2001 +From: Ariadne Conill <ariadne@dereferenced.org> +Date: Sun, 3 Apr 2022 20:44:51 +0000 +Subject: [PATCH] nslookup: sanitize all printed strings with printable_string +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +Otherwise, terminal sequences can be injected, which enables various terminal injection +attacks from DNS results. + +CVE: Pending +Upstream-Status: Pending +Signed-off-by: Ariadne Conill <ariadne@dereferenced.org> +--- + networking/nslookup.c | 10 +++++----- + 1 file changed, 5 insertions(+), 5 deletions(-) + +diff --git a/networking/nslookup.c b/networking/nslookup.c +index 6da97baf4..4bdcde1b8 100644 +--- a/networking/nslookup.c ++++ b/networking/nslookup.c +@@ -407,7 +407,7 @@ static NOINLINE int parse_reply(const unsigned char *msg, size_t len) + //printf("Unable to uncompress domain: %s\n", strerror(errno)); + return -1; + } +- printf(format, ns_rr_name(rr), dname); ++ printf(format, ns_rr_name(rr), printable_string(dname)); + break; + + case ns_t_mx: +@@ -422,7 +422,7 @@ static NOINLINE int parse_reply(const unsigned char *msg, size_t len) + //printf("Cannot uncompress MX domain: %s\n", strerror(errno)); + return -1; + } +- printf("%s\tmail exchanger = %d %s\n", ns_rr_name(rr), n, dname); ++ printf("%s\tmail exchanger = %d %s\n", ns_rr_name(rr), n, printable_string(dname)); + break; + + case ns_t_txt: +@@ -434,7 +434,7 @@ static NOINLINE int parse_reply(const unsigned char *msg, size_t len) + if (n > 0) { + memset(dname, 0, sizeof(dname)); + memcpy(dname, ns_rr_rdata(rr) + 1, n); +- printf("%s\ttext = \"%s\"\n", ns_rr_name(rr), dname); ++ printf("%s\ttext = \"%s\"\n", ns_rr_name(rr), printable_string(dname)); + } + break; + +@@ -454,7 +454,7 @@ static NOINLINE int parse_reply(const unsigned char *msg, size_t len) + } + + printf("%s\tservice = %u %u %u %s\n", ns_rr_name(rr), +- ns_get16(cp), ns_get16(cp + 2), ns_get16(cp + 4), dname); ++ ns_get16(cp), ns_get16(cp + 2), ns_get16(cp + 4), printable_string(dname)); + break; + + case ns_t_soa: +@@ -483,7 +483,7 @@ static NOINLINE int parse_reply(const unsigned char *msg, size_t len) + return -1; + } + +- printf("\tmail addr = %s\n", dname); ++ printf("\tmail addr = %s\n", printable_string(dname)); + cp += n; + + printf("\tserial = %lu\n", ns_get32(cp)); |