Code Monkey home page Code Monkey logo

sign-dkms-modules's Introduction

Helper for signing DKMS modules for use with Secure Boot

Running a system with Secure Boot enable has its advantages and disadvantages. One of the disadvantages are that DKMS modules require a bit of special handing. Because they're compiled on your own system, not the Debian maintainer's (or whoever signs the official modules), they are not signed with an officially recognized key. With Secure Boot enabled, the kernel will refuse to load them.

One of the solutions is to create a MOK signing key yourself, enroll it on your machine, and sign all your modules with it. Doing so will effectively whitelist your modules, and the kernel will happily accept them.

Rather than manually iterating over all the modules and running the sign-file script on them, wouldn't it be nice with a helper script? That's exactly what this script is. You provide a MOK keypair and the script does all the signing.

See the Debian wiki for more information on how Secure Boot works. Here's how they suggest you create and enroll your key:

# openssl req -new -x509 -newkey rsa:2048 -keyout MOK.priv -outform DER -out MOK.der -days 36500 -subj "/CN=My Name/" -nodes

# mokutil --import MOK.der // prompts for one-time password

# mokutil --list-new // recheck your key will be prompted on next boot

<rebooting machine then enters MOK manager EFI utility: enroll MOK, continue, confirm, enter password, reboot>

# dmesg | grep cert // verify your key is loaded

sign-dkms-modules's People

Contributors

ttytyper avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.