coreboot

coreboot™: fast, flexible and reproducible Open Source firmware!

Reproducible Coreboot

Reproducible builds enable anyone to reproduce bit by bit identical binary packages from a given source, so that anyone can verify that a given binary derived from the source it was said to be derived. There is more information about reproducible builds on the Debian wiki and on https://reproducible-builds.org. These pages explain in more depth why this is useful, what common issues exist and which workarounds and solutions are known.

Reproducible Coreboot is an effort to apply this to coreboot. Thus each coreboot.rom is build twice (without payloads), with a few variations added and then those two ROMs are compared using diffoscope. Please note that the toolchain is not varied at all as the rebuild happens on exactly the same system. More variations are expected to be seen in the wild.

There is a weekly run jenkins job to test the master branch of coreboot.git. The jenkins job is running reproducible_coreboot.sh in a Debian environment and this script is solely responsible for creating this page. Feel invited to join #reproducible-builds (on irc.oftc.net) to request job runs whenever sensible. Patches and other feedback are very much appreciated - if you want to help, please start by looking at the ToDo list for coreboot, you might find something easy to contribute.
Thanks to Profitbricks for donating the virtual machines this is running on!

240 (100.0%) out of 240 built coreboot images were reproducible in our test setup ! These tests were last run on 2019-05-17 for version 4.9-1685-g997207d9a6 using diffoscope 114.

variationfirst buildsecond build
hostname osuosl-build169-amd64 or osuosl-build170-amd64the other one
domainname is not yet varied between rebuilds of coreboot.
env CAPTURE_ENVIRONMENTnot setCAPTURE_ENVIRONMENT="I capture the environment"
env TZTZ="/usr/share/zoneinfo/Etc/GMT+12"TZ="/usr/share/zoneinfo/Etc/GMT-14"
env LANGLANG="en_GB.UTF-8"LANG="fr_CH.UTF-8"
env LC_ALLnot setLC_ALL="fr_CH.UTF-8"
env PATHPATH="/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:"PATH="/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/i/capture/the/path"
env USER is not yet varied between rebuilds of coreboot.
uid is not yet varied between rebuilds of coreboot.
gid is not yet varied between rebuilds of coreboot.
UTS namespace is not yet varied between rebuilds of coreboot.
kernel version, modified using /usr/bin/linux64 --uname-2.6Linux 4.9.0-9-amd64Linux 2.6.69-9-amd64
umask00220002
CPU type Intel(R) Xeon(R) CPU E5-2660 0 @ 2.20GHzsame for both builds
/bin/sh is not yet varied between rebuilds of coreboot.
year, month, datetoday (2019-05-17)same for both builds (currently, work in progress)
hour, minutehour and minute will probably vary between two builds...the future system actually runs 398 days, 6 hours and 23 minutes ahead...
Filesystemtmpfssame for both builds (currently, this could be varied using disorderfs)
everything else...is likely the same. There will be more variations in the wild.

commit 997207d9a663a74a5b1ed4499fd7b1ce83494d78
Author: Alan Green 
Date:   Thu May 16 08:52:12 2019 +1000

    src/include/assert.h: add noreturn attribute to dead_code()
    
    Clang does not recognize dead_code() as termination of execution. It
    gives this message:
    
    error: control reaches end of non-void function
          [-Werror,-Wreturn-type]
    
    This change adds an __attribute__((noreturn)) to ensure that clang
    recognises that this function will terminate execution.
    
    This change is more general solution to the problem that was addressed
    in the specific at https://review.coreboot.org/c/coreboot/+/32798
    
    Signed-off-by: Alan Green 
    Change-Id: I5ba7189559aa01545d5bbe893bced400a3aaabbb
    Reviewed-on: https://review.coreboot.org/c/coreboot/+/32833
    Tested-by: build bot (Jenkins) 
    Reviewed-by: Julius Werner      

cross toolchain sourcesha256sum
acpica-unix2-20190509.tar.gz 860b5f94a0590b278592acf16a4556b05ff0309c08e8c48aa29827cfa02c8e9d
binutils-2.32.tar.xz 0ab6c55dd86a92ed561972ba15b9b70a8b9f75557f896446c82e8b36e473ee04
gcc-8.3.0.tar.xz 64baadfe6cc0f4947a84cb12d7f0dfaf45bb58b7e92461639596c21e02d97d2c
gmp-6.1.2.tar.xz 87b565e89a9a684fe4ebeeddb8399dce2599f9c9049854ca8c0dfbdea0e21912
mpc-1.1.0.tar.gz 6985c538143c1208dcb1ac42cedad6ff52e267b47e5f970183a3e75125b43c2e
mpfr-4.0.2.tar.xz 1d3be708604eae0e42d578ba93b390c2a145f17743a744d8f3f8c2ad5855a38a
Debian 9.9 package on amd64installed version
gcc 4:6.3.0-4
g++ 4:6.3.0-4
make 4.1-9.1
cmake 3.7.2-1
flex 2.6.1-1.3
bison 2:3.0.4.dfsg-1+b1
iasl