scripts / sign-module /
Newer Older
19 lines | 0.52kb
add signing module routine f...
Sébastien MARQUE authored on 2020-09-29
1
#!/bin/zsh
2
# bash compatible
3

            
possible de spécifier le mod...
Sébastien MARQUE authored on 2022-10-13
4
declare -A mod
5
mod[nv]=nvidia-current
6
mod[vbox]=vboxdrv
7
mod[default]="${mod[nv]} ${mod[vbox]}"
8
test -n "$1" && test -z ${mod[$1]} && mod[$1]=${mod[default]}
9

            
10
for c in ${mod[${1:-default}]}; do
add signing module routine f...
Sébastien MARQUE authored on 2020-09-29
11
    for modfile in $(dirname $(modinfo -n $c))/*.ko; do
12
        sudo /usr/src/linux-headers-$(uname -r)/scripts/sign-file \
13
            sha256 \
14
            /root/module-signing/MOK.priv \
15
            /root/module-signing/MOK.der \
16
            "$modfile"
possible de spécifier le mod...
Sébastien MARQUE authored on 2022-10-13
17
        echo ${modfile##*/}
add signing module routine f...
Sébastien MARQUE authored on 2020-09-29
18
    done
19
done