make_keyblock: change to parsing key prefix
Instead of requiring an arg, just check if the private key starts with
"remote:" to detect omitting the extension.
BUG=b:318522770
BRANCH=None
TEST=[None|unit-test|led-launch]
Change-Id: I55f04e25a43b2e9fe3ddf3951e48b29a6fe26d49
Signed-off-by: Benjamin Shai <bshai@google.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/vboot_reference/+/5201825
Reviewed-by: George Engelbrecht <engeg@google.com>
Commit-Queue: Julius Werner <jwerner@chromium.org>
Reviewed-by: Julius Werner <jwerner@chromium.org>
diff --git a/scripts/keygeneration/common.sh b/scripts/keygeneration/common.sh
index 8116b76..b8ddde7 100644
--- a/scripts/keygeneration/common.sh
+++ b/scripts/keygeneration/common.sh
@@ -152,10 +152,9 @@
local flags=$2
local pubkey=$3
local signkey=$4
- local excl_extn=$5
local privkey="${signkey}"
- if [[-z "${excl_extn}" ]]; then
+ if [[ "${signkey}" != "remote:"* ]]; then
privkey="${signkey}.vbprivk"
fi