summaryrefslogtreecommitdiffstats
path: root/meta/recipes-devtools/nasm/nasm/CVE-2019-14248.patch
diff options
context:
space:
mode:
Diffstat (limited to 'meta/recipes-devtools/nasm/nasm/CVE-2019-14248.patch')
-rw-r--r--meta/recipes-devtools/nasm/nasm/CVE-2019-14248.patch43
1 files changed, 0 insertions, 43 deletions
diff --git a/meta/recipes-devtools/nasm/nasm/CVE-2019-14248.patch b/meta/recipes-devtools/nasm/nasm/CVE-2019-14248.patch
deleted file mode 100644
index d45d2cb465..0000000000
--- a/meta/recipes-devtools/nasm/nasm/CVE-2019-14248.patch
+++ /dev/null
@@ -1,43 +0,0 @@
1From 93d41d82963b2cfd0b24c906f5a8daf53281b559 Mon Sep 17 00:00:00 2001
2From: "H. Peter Anvin (Intel)" <hpa@zytor.com>
3Date: Fri, 16 Aug 2019 01:12:54 -0700
4Subject: [PATCH] BR 3392576: don't segfault on a bad %pragma limit
5
6Don't segfault on a bad %pragma limit. Instead treat a NULL pointer as
7an empty string.
8
9Reported-by: Ren Kimura <rkx1209dev@gmail.com>
10Signed-off-by: H. Peter Anvin (Intel) <hpa@zytor.com>
11
12CVE: CVE-2019-14248
13Upstream-Status: Backport [https://repo.or.cz/nasm.git/commit/93d41d82963b2cfd0b24c906f5a8daf53281b559]
14Signed-off-by: Anuj Mittal <anuj.mittal@intel.com>
15---
16 asm/nasm.c | 7 ++++++-
17 1 file changed, 6 insertions(+), 1 deletion(-)
18
19diff --git a/asm/nasm.c b/asm/nasm.c
20index c84d675..65116ab 100644
21--- a/asm/nasm.c
22+++ b/asm/nasm.c
23@@ -212,6 +212,11 @@ nasm_set_limit(const char *limit, const char *valstr)
24 bool rn_error;
25 int errlevel;
26
27+ if (!limit)
28+ limit = "";
29+ if (!valstr)
30+ valstr = "";
31+
32 for (i = 0; i <= LIMIT_MAX; i++) {
33 if (!nasm_stricmp(limit, limit_info[i].name))
34 break;
35@@ -204,7 +209,7 @@ nasm_set_limit(const char *limit, const char *valstr)
36 errlevel = ERR_WARNING|ERR_NOFILE|ERR_USAGE;
37 else
38 errlevel = ERR_WARNING|ERR_PASS1|WARN_UNKNOWN_PRAGMA;
39- nasm_error(errlevel, "unknown limit: `%s'", limit);
40+ nasm_error(errlevel, "invalid limit value: `%s'", valstr);
41 return DIRR_ERROR;
42 }
43