Initial Commit
- initial default booting image
This commit is contained in:
@@ -0,0 +1,32 @@
|
||||
From 48ced849ed621a05cec4c04d4567323af3a76e81 Mon Sep 17 00:00:00 2001
|
||||
From: dataisland <dataisland@outlook.com>
|
||||
Date: Fri, 15 Sep 2023 18:20:49 +0000
|
||||
Subject: [PATCH] Fix null-pointer-dereference in yasm_expr_get_intnum
|
||||
|
||||
Fixes the following CVE:
|
||||
- CVE-2021-33454: NULL pointer dereference in yasm_expr_get_intnum() in libyasm/expr.c
|
||||
|
||||
For more info see:
|
||||
- https://nvd.nist.gov/vuln/detail/CVE-2021-33454
|
||||
- https://github.com/yasm/yasm/pull/244
|
||||
|
||||
CVE: CVE-2021-33454
|
||||
Upstream: https://github.com/yasm/yasm/pull/244
|
||||
Signed-off-by: Titouan Christophe <titouan.christophe@mind.be>
|
||||
---
|
||||
libyasm/expr.c | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/libyasm/expr.c b/libyasm/expr.c
|
||||
index c2c868ede..6838eca56 100644
|
||||
--- a/libyasm/expr.c
|
||||
+++ b/libyasm/expr.c
|
||||
@@ -1260,7 +1260,7 @@ yasm_expr_get_intnum(yasm_expr **ep, int calc_bc_dist)
|
||||
{
|
||||
*ep = yasm_expr_simplify(*ep, calc_bc_dist);
|
||||
|
||||
- if ((*ep)->op == YASM_EXPR_IDENT && (*ep)->terms[0].type == YASM_EXPR_INT)
|
||||
+ if (*ep && (*ep)->op == YASM_EXPR_IDENT && (*ep)->terms[0].type == YASM_EXPR_INT)
|
||||
return (*ep)->terms[0].data.intn;
|
||||
else
|
||||
return (yasm_intnum *)NULL;
|
||||
38
package/yasm/0002-bitvect-fix-build-with-gcc-15.patch
Normal file
38
package/yasm/0002-bitvect-fix-build-with-gcc-15.patch
Normal file
@@ -0,0 +1,38 @@
|
||||
From 64ef740eb262f329e55eebadf2ce276b146d44e9 Mon Sep 17 00:00:00 2001
|
||||
From: Martin Jansa <martin.jansa@gmail.com>
|
||||
Date: Tue, 22 Apr 2025 19:06:24 +0200
|
||||
Subject: [PATCH] bitvect: fix build with gcc-15
|
||||
|
||||
* fixes:
|
||||
libyasm/bitvect.h:86:32: error: cannot use keyword 'false' as enumeration constant
|
||||
86 | typedef enum boolean { false = FALSE, true = TRUE } boolean;
|
||||
| ^~~~~
|
||||
../git/libyasm/bitvect.h:86:32: note: 'false' is a keyword with '-std=c23' onwards
|
||||
|
||||
as suggested in:
|
||||
https://github.com/yasm/yasm/issues/283#issuecomment-2661108816
|
||||
|
||||
Signed-off-by: Martin Jansa <martin.jansa@gmail.com>
|
||||
Upstream: https://github.com/yasm/yasm/pull/287
|
||||
Signed-off-by: Thomas Perale <thomas.perale@mind.be>
|
||||
---
|
||||
libyasm/bitvect.h | 6 +++++-
|
||||
1 file changed, 5 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/libyasm/bitvect.h b/libyasm/bitvect.h
|
||||
index 3aee3a531..a13470ada 100644
|
||||
--- a/libyasm/bitvect.h
|
||||
+++ b/libyasm/bitvect.h
|
||||
@@ -83,7 +83,11 @@ typedef Z_longword *Z_longwordptr;
|
||||
#ifdef MACOS_TRADITIONAL
|
||||
#define boolean Boolean
|
||||
#else
|
||||
- typedef enum boolean { false = FALSE, true = TRUE } boolean;
|
||||
+ #if __STDC_VERSION__ < 202311L
|
||||
+ typedef enum boolean { false = FALSE, true = TRUE } boolean;
|
||||
+ #else
|
||||
+ typedef bool boolean;
|
||||
+ #endif
|
||||
#endif
|
||||
#endif
|
||||
|
||||
10
package/yasm/Config.in
Normal file
10
package/yasm/Config.in
Normal file
@@ -0,0 +1,10 @@
|
||||
config BR2_PACKAGE_YASM
|
||||
bool "yasm"
|
||||
depends on BR2_i386 || BR2_x86_64
|
||||
help
|
||||
Yasm is a complete rewrite of the NASM-2.10.01 assembler.
|
||||
It supports the x86 and AMD64 instruction sets, accepts NASM
|
||||
and GAS assembler syntaxes and outputs binary, ELF32 and ELF64
|
||||
object formats.
|
||||
|
||||
http://www.tortall.net/projects/yasm/
|
||||
7
package/yasm/yasm.hash
Normal file
7
package/yasm/yasm.hash
Normal file
@@ -0,0 +1,7 @@
|
||||
# Locally computed:
|
||||
sha256 3dce6601b495f5b3d45b59f7d2492a340ee7e84b5beca17e48f862502bd5603f yasm-1.3.0.tar.gz
|
||||
sha256 795f8d76eade6130129b680ac72ea81cb3e143467a65ea1f5f64946151d7fa20 COPYING
|
||||
sha256 a84b45f23040624681ca6974ff48d8ef6b477a1cb51e4a1c842e49d00c231e0d BSD.txt
|
||||
sha256 b7fd9b73ea99602016a326e0b62e6646060d18febdd065ceca8bb482208c3d88 Artistic.txt
|
||||
sha256 e6d6a009505e345fe949e1310334fcb0747f28dae2856759de102ab66b722cb4 GNU_GPL-2.0
|
||||
sha256 1faefae1fe8838a2e48864df7d1376e421a50c551c5ae2f60c9f2093206e18a9 GNU_LGPL-2.0
|
||||
26
package/yasm/yasm.mk
Normal file
26
package/yasm/yasm.mk
Normal file
@@ -0,0 +1,26 @@
|
||||
################################################################################
|
||||
#
|
||||
# yasm
|
||||
#
|
||||
################################################################################
|
||||
|
||||
YASM_VERSION = 1.3.0
|
||||
YASM_SITE = http://www.tortall.net/projects/yasm/releases
|
||||
YASM_LICENSE = BSD-2-Clause, BSD-3-Clause, Artistic, GPL-2.0, LGPL-2.0
|
||||
YASM_LICENSE_FILES = COPYING BSD.txt Artistic.txt GNU_GPL-2.0 GNU_LGPL-2.0
|
||||
YASM_CPE_ID_VENDOR = tortall
|
||||
|
||||
# 0001-fix-null-pointer-dereference-in-yasm_expr_get_intnum.patch
|
||||
YASM_IGNORE_CVES += CVE-2021-33454
|
||||
|
||||
# This sed prevents it compiling 2 programs (vsyasm and ytasm)
|
||||
# that are only of use on Microsoft Windows.
|
||||
define YASM_PRE_CONFIGURE_FIXUP
|
||||
$(SED) 's#) ytasm.*#)#' $(@D)/Makefile.in
|
||||
endef
|
||||
|
||||
YASM_PRE_CONFIGURE_HOOKS += YASM_PRE_CONFIGURE_FIXUP
|
||||
HOST_YASM_PRE_CONFIGURE_HOOKS += YASM_PRE_CONFIGURE_FIXUP
|
||||
|
||||
$(eval $(autotools-package))
|
||||
$(eval $(host-autotools-package))
|
||||
Reference in New Issue
Block a user