From patchwork Mon Dec 8 02:32:06 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simon Glass X-Patchwork-Id: 836 Return-Path: X-Original-To: u-boot-concept@u-boot.org Delivered-To: u-boot-concept@u-boot.org DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=u-boot.org; s=default; t=1765161187; bh=jcy/EW9OlvEpnFIP1ea/YkI09O2Gi65g4QMimyb8h80=; h=From:To:Date:In-Reply-To:References:CC:Subject:List-Id: List-Archive:List-Help:List-Owner:List-Post:List-Subscribe: List-Unsubscribe:From; b=nf61s/B3lISM8uFhyUHulSSqpyB+wzFw2pY4pIS6t1i22hVEyVA42uGrrGeDeFZx9 WkQR6ejXWhkpf8a2YPIoroLmpl7YaS8XNTziYCThVWKRsxYm8VGwIDNV6hlFJWJjBs mREwa/Z6EAXeB45rZbrhKWrZwyqFlME4YrKkxdpRFwnJyko0Zjzz5AiHq9QSi2rfwS T2PFV8sbt7WTZUf/dRwIG7+SnqUVsE+7eEL4dzYDdwRfBwPOwJOJdYxmeEZjLrOZYC XvhmUQd9yID4GGvb0MWcTjD9cmaQAwfBrnyhu0rnsTW8APW5rQdneOYoOBdFpKY4aU njFs25RwcxLhA== Received: from localhost (localhost [127.0.0.1]) by mail.u-boot.org (Postfix) with ESMTP id 771D5689C1 for ; Sun, 7 Dec 2025 19:33:07 -0700 (MST) X-Virus-Scanned: Debian amavis at Received: from mail.u-boot.org ([127.0.0.1]) by localhost (mail.u-boot.org [127.0.0.1]) (amavis, port 10024) with ESMTP id t_cpx6-VtpCk for ; Sun, 7 Dec 2025 19:33:07 -0700 (MST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=u-boot.org; s=default; t=1765161187; bh=jcy/EW9OlvEpnFIP1ea/YkI09O2Gi65g4QMimyb8h80=; h=From:To:Date:In-Reply-To:References:CC:Subject:List-Id: List-Archive:List-Help:List-Owner:List-Post:List-Subscribe: List-Unsubscribe:From; b=nf61s/B3lISM8uFhyUHulSSqpyB+wzFw2pY4pIS6t1i22hVEyVA42uGrrGeDeFZx9 WkQR6ejXWhkpf8a2YPIoroLmpl7YaS8XNTziYCThVWKRsxYm8VGwIDNV6hlFJWJjBs mREwa/Z6EAXeB45rZbrhKWrZwyqFlME4YrKkxdpRFwnJyko0Zjzz5AiHq9QSi2rfwS T2PFV8sbt7WTZUf/dRwIG7+SnqUVsE+7eEL4dzYDdwRfBwPOwJOJdYxmeEZjLrOZYC XvhmUQd9yID4GGvb0MWcTjD9cmaQAwfBrnyhu0rnsTW8APW5rQdneOYoOBdFpKY4aU njFs25RwcxLhA== Received: from mail.u-boot.org (localhost [127.0.0.1]) by mail.u-boot.org (Postfix) with ESMTP id 65FB268923 for ; Sun, 7 Dec 2025 19:33:07 -0700 (MST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=u-boot.org; s=default; t=1765161184; bh=58nk296weUYGOni8grgCkWdHCQLlhJCHYnQOH2Q86lQ=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=cM7WoGsKDpGhJfnBOX/rxwMUjxkVo1V1loJKgL/j7vtdN3jHCSlVE27Fr9D3THmuk pI0NuiNgdUevuRZOZaC9WQXAEKwkN8RHWvP5OLWzwL9AMJB8l/5uZJx+33dXXPasG/ pewI4JRfGGYG4gjz8GeBskcwoR7mhnz1oMcaYaRWN58rCsMSXRBcsud7ZD1+YFQ3RE ggRq7IBicUft2adKudqbeR+59SVCuTZM+pZXzpVcGPaT33I9xD8Ux0CIulxBpeUoqy iT6uHV36DjqcItZeHzWsCMLrJSyaBZhbCDpZ5PQJtQNXMVw1iRCCyzkpMbINRVJpa0 TdY2GmUgKj77w== Received: from localhost (localhost [127.0.0.1]) by mail.u-boot.org (Postfix) with ESMTP id DC7C36883E; Sun, 7 Dec 2025 19:33:04 -0700 (MST) X-Virus-Scanned: Debian amavis at Received: from mail.u-boot.org ([127.0.0.1]) by localhost (mail.u-boot.org [127.0.0.1]) (amavis, port 10026) with ESMTP id o-v4g9SI6TVr; Sun, 7 Dec 2025 19:33:04 -0700 (MST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=u-boot.org; s=default; t=1765161180; bh=mQCc1vTPsGe73Cq4cbhQ/eKeQmn0VjQOC7VHf39uUkA=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=U6A70i/n4xI9evj012Kh5q1DCBU4/d4Na4QE5j9ylNQc7ORjdHugNQ90Oh8yljpU2 piM0t/h0HlXJ38NEzsHrRX3Z459+P2/aZio85RByZEYgRrXzTsiVn9rTNypiyhVmH1 IAKOHJszx7EokaUux2JfR2Lx/88+nTqn1ybfLHcAKqt8rtv8nZz2EWOrZedcBbuz00 5v2vBDVq6+zF3N5ygSBxj1kOzh/+wKqa73ehvTD9bKGVqsHkajkqCTf7AXkszAU0ip d8zpTaka8kiw22z6N6o7N+vK4qZtoPGkIOHhPtpsX7C35NUNguuDfAhHUAxvTC/Mue PN6lpx8HYDXTQ== Received: from u-boot.org (unknown [73.34.74.121]) by mail.u-boot.org (Postfix) with ESMTPSA id 7D7B0689CF; Sun, 7 Dec 2025 19:33:00 -0700 (MST) From: Simon Glass To: U-Boot Concept Date: Sun, 7 Dec 2025 19:32:06 -0700 Message-ID: <20251208023229.3929910-4-sjg@u-boot.org> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20251208023229.3929910-1-sjg@u-boot.org> References: <20251208023229.3929910-1-sjg@u-boot.org> MIME-Version: 1.0 Message-ID-Hash: Z55BUUF2ECXR6D3UTCSKVYXIV5C6WN67 X-Message-ID-Hash: Z55BUUF2ECXR6D3UTCSKVYXIV5C6WN67 X-MailFrom: sjg@u-boot.org X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; loop; banned-address; emergency; member-moderation; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header CC: Simon Glass , Claude X-Mailman-Version: 3.3.10 Precedence: list Subject: [Concept] [PATCH 03/19] bootctl: Set the password flag on the passphrase edit text List-Id: Discussion and patches related to U-Boot Concept Archived-At: List-Archive: List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: From: Simon Glass The SCENEOF_PASSWORD flag is set on the textline object, but the rendering code checks the flag on the text object being rendered. Set the flag on the edit text object so the passphrase renders as asterisks instead of showing the actual characters. Mark the textline object as hidden while we are here, so it disappears when switching to the simple bootmenu. Co-developed-by: Claude Signed-off-by: Simon Glass --- boot/bootflow_menu.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/boot/bootflow_menu.c b/boot/bootflow_menu.c index 01af30c6627..1b740c8d16b 100644 --- a/boot/bootflow_menu.c +++ b/boot/bootflow_menu.c @@ -45,6 +45,7 @@ static int bootflow_menu_set_item_props(struct scene *scn, scene_obj_set_hide(scn, ITEM_VERIFIED + i, true); ret |= scene_obj_set_hide(scn, ITEM_KEY + i, false); scene_obj_set_hide(scn, ITEM_LOCKED + i, true); + scene_obj_set_hide(scn, ITEM_PASS + i, true); scene_obj_set_hide(scn, ITEM_PASS_LABEL + i, true); scene_obj_set_hide(scn, ITEM_PASS_EDIT + i, true); if (ret) @@ -233,6 +234,7 @@ int bootflow_menu_add(struct expo *exp, struct bootflow *bflow, int seq, { struct menu_priv *priv = exp->priv; struct scene_obj_textline *tline; + struct scene_obj_txt *txt; char str[2], *key; struct scene *scn; uint preview_id; @@ -308,10 +310,11 @@ int bootflow_menu_add(struct expo *exp, struct bootflow *bflow, int seq, snprintf(name, sizeof(name), "item%d.pass.edit", seq); ret = scene_txt_str(scn, name, ITEM_PASS_EDIT + seq, 0, - abuf_data(&tline->buf), NULL); + abuf_data(&tline->buf), &txt); if (ret < 0) return log_msg_ret("ite", -EINVAL); tline->edit_id = ret; + txt->obj.flags |= SCENEOF_PASSWORD; /* Create message text (hidden by default) for success/error feedback */ snprintf(name, sizeof(name), "item%d.pass_msg", seq);