From: Ahmad Fatoum <a.fatoum@pengutronix.de>
To: barebox@lists.infradead.org
Cc: Ahmad Fatoum <a.fatoum@pengutronix.de>
Subject: [PATCH 2/3] test: self: jwt: add dedicated option for development_rsa2048.pem
Date: Thu, 21 Aug 2025 22:59:41 +0200 [thread overview]
Message-ID: <20250821205942.1435683-2-a.fatoum@pengutronix.de> (raw)
In-Reply-To: <20250821205942.1435683-1-a.fatoum@pengutronix.de>
This test key can be useful beyond the JWT selftest, so add an option to
select it.
The key added by the option is stand-alone, i.e., it is not part of the
key ring and won't be consulted for FIT image verification.
Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de>
---
test/Kconfig | 8 ++++++++
test/self/Kconfig | 1 +
test/self/Makefile | 3 ++-
3 files changed, 11 insertions(+), 1 deletion(-)
diff --git a/test/Kconfig b/test/Kconfig
index 07b22f09e99b..50162ef5761f 100644
--- a/test/Kconfig
+++ b/test/Kconfig
@@ -46,4 +46,12 @@ config CMD_FUZZ
endif
+config TEST_KEY_RSA2048
+ bool
+ help
+ This is selected by crypto test code that needs a RSA2048 public
+ key. The key added by this option is stand-alone, i.e., it is
+ not part of the key ring and won't be consulted for FIT image
+ verification.
+
endif
diff --git a/test/self/Kconfig b/test/self/Kconfig
index 33d05e4cf205..4c43dfe3940d 100644
--- a/test/self/Kconfig
+++ b/test/self/Kconfig
@@ -86,6 +86,7 @@ config SELFTEST_JSON
config SELFTEST_JWT
bool "JSON Web Token selftest"
depends on JWT
+ select TEST_KEY_RSA2048
config SELFTEST_MMU
bool "MMU remapping selftest"
diff --git a/test/self/Makefile b/test/self/Makefile
index 6cf857ee98ff..9aa8aab78b31 100644
--- a/test/self/Makefile
+++ b/test/self/Makefile
@@ -10,7 +10,8 @@ obj-$(CONFIG_SELFTEST_ENVIRONMENT_VARIABLES) += envvar.o
obj-$(CONFIG_SELFTEST_FS_RAMFS) += ramfs.o
obj-$(CONFIG_SELFTEST_DIRFD) += dirfd.o
obj-$(CONFIG_SELFTEST_JSON) += json.o
-obj-$(CONFIG_SELFTEST_JWT) += jwt.o development_rsa2048.pem.o
+obj-$(CONFIG_SELFTEST_JWT) += jwt.o
+obj-$(CONFIG_TEST_KEY_RSA2048) += development_rsa2048.pem.o
obj-$(CONFIG_SELFTEST_DIGEST) += digest.o
obj-$(CONFIG_SELFTEST_MMU) += mmu.o
obj-$(CONFIG_SELFTEST_STRING) += string.o
--
2.39.5
next prev parent reply other threads:[~2025-08-22 2:25 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-08-21 20:59 [PATCH 1/3] fuzz: add test harness for fuzzing nul-terminated strings Ahmad Fatoum
2025-08-21 20:59 ` Ahmad Fatoum [this message]
2025-08-21 20:59 ` [PATCH 3/3] security: jwt: add simple fuzzer Ahmad Fatoum
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20250821205942.1435683-2-a.fatoum@pengutronix.de \
--to=a.fatoum@pengutronix.de \
--cc=barebox@lists.infradead.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox