Add auto installer for mostly securing grub via sig file.

This commit is contained in:
Captain ALM 2024-08-02 21:04:23 +01:00
parent 262e71b25f
commit 415ef0d104
Signed by: alfred
GPG Key ID: 4E4ADD02609997B1
4 changed files with 22 additions and 0 deletions

Binary file not shown.

3
gpg-agent.conf Normal file
View File

@ -0,0 +1,3 @@
pinentry-program /usr/bin/pinentry-curses
no-grab
default-cache-ttl 1800

1
gpg.conf Normal file
View File

@ -0,0 +1 @@
use-agent

18
install-grub-security.sh Normal file
View File

@ -0,0 +1,18 @@
#!/bin/bash
echo "[+] Installing...";
sudo cp bin/* /bin/ -f;
sudo cp initramfs-tools-hooks/* /etc/initramfs-tools/hooks/ -f;
sudo cp local-sbin/* /usr/local/sbin/ -f;
sudo cp kernel-hooks/* /etc/kernel/ -fr;
sudo cp lib-systemd-system-sleep/* /usr/lib/systemd/system-sleep/ -f;
sudo 7za x -o/etc grub.d.my.7z -y;
sudo cp sbat /root/sbat -f;
if [ ! -f /root/pubkey ]; then
sudo gpg --batch --passphrase '' --quick-gen-key root@localhost default default;
sudo gpg --export -o /root/pubkey;
fi
sudo cp /root/pubkey /boot/pubkey -f;
sudo cp gpg.conf /root/.gnupg/gpg.conf -f;
sudo cp gpg-agent.conf /root/.gnupg/gpg-agent.conf -f;
echo "[+] Complete!";
exit;