Skip to content

Commit

Permalink
Merge pull request #76 from 1Naim/feat/sbctl-batch-sign
Browse files Browse the repository at this point in the history
feat: add sbctl-sign-batch for secure boot
  • Loading branch information
ptr1337 authored Jul 21, 2024
2 parents 4f5168d + a961b84 commit 2ac3844
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions usr/bin/sbctl-batch-sign
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
#!/bin/bash

# sbctl-batch-sign is a helper script designed to make it easier for users to sign files needed for secure boot support.
# The obvious case in which this script helps a lot is when dual booting Windows as there are a lot of files by Windows that
# needs to be signed in EFI.

if [ "$(id -u)" -ne 0 ]; then
echo "Error: This script must be run with root privileges."
exit 1
fi

if [ "$#" -eq 0 ]; then
for entries in $(sbctl verify | grep signed | cut -d' ' -f2); do
sbctl sign -s $entries
done
fi

0 comments on commit 2ac3844

Please sign in to comment.