aboutsummaryrefslogtreecommitdiffstats
path: root/scripts
diff options
context:
space:
mode:
authorKonstantin Aladyshev <aladyshev22@gmail.com>2022-08-02 15:50:34 +0300
committerKonstantin Aladyshev <aladyshev22@gmail.com>2022-08-02 15:50:34 +0300
commit3cf6d5377332b7d91ff2a76b0d045e81654d845f (patch)
tree4519aba73a5418d4b8b925093009ccc4046c9a7f /scripts
parentc36b0b56082db6c55bfdb960204bbc65fdf43052 (diff)
downloadUEFI-Lessons-3cf6d5377332b7d91ff2a76b0d045e81654d845f.tar.gz
UEFI-Lessons-3cf6d5377332b7d91ff2a76b0d045e81654d845f.tar.bz2
UEFI-Lessons-3cf6d5377332b7d91ff2a76b0d045e81654d845f.zip
Add script for PCD token generation
Signed-off-by: Konstantin Aladyshev <aladyshev22@gmail.com>
Diffstat (limited to 'scripts')
-rw-r--r--scripts/README.md4
-rwxr-xr-xscripts/genToken.sh8
2 files changed, 12 insertions, 0 deletions
diff --git a/scripts/README.md b/scripts/README.md
index 41f2461..8e2af0e 100644
--- a/scripts/README.md
+++ b/scripts/README.md
@@ -25,3 +25,7 @@
- Font:
[create_font_data.html](create_font_data.html) - HTML with javascript code to transform font file to UEFI Glyph array
+
+- PCD:
+
+[genToken.sh](genToken.sh) - script to generate random 4-byte token for PCD
diff --git a/scripts/genToken.sh b/scripts/genToken.sh
new file mode 100755
index 0000000..c59c010
--- /dev/null
+++ b/scripts/genToken.sh
@@ -0,0 +1,8 @@
+#!/bin/bash
+
+##
+# This is a simple script that generates a random 4-byte hex value for a PCD Token
+##
+
+hexdump -vn4 -e'"0x%08X\n"' /dev/urandom
+