GithubHelp home page GithubHelp logo

sbtools's Introduction

sbtools

Helpers for generating signed Arch Linux kernels for Secure Boot. And pacman hook for auto-generation.

Installation

Use sb-mkkeys to generate your own Secure Boot keys in the current directory.

Use sb-make-boot-img to combine the kernel intiramfs and boot args into a single efi binary (see sb-make-boot-img -h for help).

Use sb-sign-binary to sign a binary using your keys (see sb-sign-binary -h for help).

See How to install the efi keys.

Configuration file

The configuration file should be located at /etc/sbtools.conf and can be used to prefill some of the tools arguments (they will be overriten if the command line args are present).

the options are in the format: <name>=<path>

List of the different possible options:

  • cmd: Kernel command-line file.
  • outdir: Efi binary output dir (only used by the pacman hook)
  • out: Efi binary output file (not used by the pacman hook)
  • osrel: osrel file
  • efistuf: efistub file
  • keysdir: Location of the Secure boot keys
  • kernel: Location of the kernel to use (will break the pacman hook)
  • initrd: Initramfs to use
  • addinitrd: Additional initramfs (like microcode).

Pacman hook

For the pacman hook to work the configuration file /etc/sbtools.conf must be updtated accordingly to your setup.

The mandatory options needed to run the pacman hook are:

  • cmd
  • outdir
  • keysdir
  • osrel
  • efistuf

For each kernel /boot/vmlinuz-<NAME> the pacman-hook will generate <OUTDIR>/<NAME>.efi with defined in the previously mentionned configuration file.

Known bugs

The LZOP compression for the initramfs is not supported.

sbtools's People

Contributors

xdbob avatar

Stargazers

 avatar  avatar  avatar  avatar

Watchers

 avatar

sbtools's Issues

Handle re-compression of initramfs

The linux kernel can handle compressed+bundled initramfs, the uncat tool is still needed since I wish to support heterogeneous environment (intel-ucode.img is often uncompressed).

Handle compressed initcpio

The /boot partition is often rather small, for multiple kernel/initramfs, the compressed images are really useful.

Deprecate initramfs recompression support

  1. CPU µcode must not be compressed, thus current implementation is broken
  2. compression should be handle by the initrd generating tool (dracut, mkinitcpio, etc.)

Since the only use case of multi initrd is µcode, we can drop the support for multiple --initrd options and have a specific --ucode option.

Fix default options values

Right now, there are no working defaults, the config files options are just overwritten from the command line

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.