We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 620eb8f commit 2d88cfbCopy full SHA for 2d88cfb
src/luks/clevis-luks-bind
@@ -88,6 +88,11 @@ if ! CFG="${@:$((OPTIND++)):1}" || [ -z "$CFG" ]; then
88
usage
89
fi
90
91
+# Check whether the config is valid JSON.
92
+if ! jose fmt --json="${CFG}" --object 2>/dev/null; then
93
+ echo "Configuration is malformed; it should be valid JSON" >&2
94
+ exit 1
95
+fi
96
97
if [ "${luks_type}" = "luks1" ] && [ -n "${TOKEN_ID}" ]; then
98
echo "${DEV} is a LUKS1 device; -t is only supported in LUKS2" >&2
0 commit comments