guix: Update osslsigncode to 2.14 #36256

pull achow101 wants to merge 2 commits into bitcoin:master from achow101:osslsigncode-2.14 changing 2 files +39 −5
  1. achow101 commented at 1:55 AM on September 15, 2026: member

    #34948 missed the package nss-certs in splitting the codesigning to a separate guix manifest. This results in an error during codesigining: Use the "-CAfile" option to add one or more trusted CA certificates to verify the signature.

    However, introducing the package is not enough to make codesigning work. #34550 switched us to using osslsigncode 2.13 from upstream, but osslsigncode versions 2.6 through 2.13 all require network access as they validate CRLs. While the verify command has the ability to skip CRL validation, attach-signature does not.

    osslsigncode 2.14 resolves both issues for us by removing signature validation, instead it only checks that the hash in the signature matches the hash of the binary. But we still want to do a belt-and-suspenders signature validation, and we can achieve this by calling verify afterwards with CRL validation disabled to avoid the network access issue, along with including the nss-certs package.

    Lastly, guix upstream already has 2.14, so we could get it by bumping the time-machine commit. But it seems like bumping that is problematic for other packages, see #36233 and #35855. Instead, this PR copies in the package definition from upstream.

  2. guix: Use osslsigncode 2.14
    Versions prior to osslsigncode 2.14 unconditionally perform a full verification
    of the binary after signatures are attached. This verification requires
    having a reasonably up to date root CA file, and since 2.6, CRLs are
    validated which requires network access.
    
    The current manifest is both missing the root CA file, and the guix
    container does not and should not have network access.
    
    Our current guix time-machine has 2.13, while bumping it would give us
    2.14, that seems to be problematic for other packages, see #36233
    and #35855. Instead this copies in the package for osslsigncode 2.14 from
    guix.
    6719f74a1e
  3. guix: Validate codesigned windows binaries
    `osslsigncode attach-signature` doesnot validate the signature at all,
    but we should be doing a signature check after applying to ensure that
    the signature itself is also valid.
    
    To avoid requiring the container to have network access, CRL checks are
    disabled.
    
    The package `nss-certs` is required so that a root CA file is available.
    9f109628c7
  4. achow101 added this to the milestone 32.0 on Sep 15, 2026
  5. DrahtBot added the label Build system on Sep 15, 2026
  6. DrahtBot commented at 1:55 AM on September 15, 2026: contributor

    <!--e57a25ab6845829454e8d69fc972939a-->

    The following sections might be updated with supplementary metadata relevant to reviewers and maintainers.

    <!--006a51241073e994b41acfe9ec718e94-->

    Code Coverage & Benchmarks

    For details see: https://corecheck.dev/bitcoin/bitcoin/pulls/36256.

    <!--021abf342d371248e50ceaed478a90ca-->

    Reviews

    See the guideline and AI policy for information on the review process.

    Type Reviewers
    Concept ACK hebasto

    If your review is incorrectly listed, please copy-paste <code>&lt;!--meta-tag:bot-skip--&gt;</code> into the comment that the bot should ignore.

    <!--5faf32d7da4f0f540f40219e4f7537a3-->

  7. Sjors commented at 9:38 AM on September 15, 2026: member

    My guix-codesign for v32.0rc1 also failed with:

    Use the "-CAfile" option to add one or more trusted CA certificates to verify the signature. Failed

    <details> <summary>Guix build for this PR:</summary>

    x86_64
    c0f02cc1c78c812bef7331352e6fa325369d5e0795e8b08d4292c3bd294e91fd  guix-build-9f109628c7bb/output/aarch64-linux-gnu/SHA256SUMS.part
    d7cc973bd07ccb141f6accf22d15596e6341eaf8bd6134a594db93c2e7707206  guix-build-9f109628c7bb/output/aarch64-linux-gnu/bitcoin-9f109628c7bb-aarch64-linux-gnu-debug.tar.gz
    6cee1098720067dcbcf0fe1e9076ad04246536a72dd1018865133859cdbc8e8e  guix-build-9f109628c7bb/output/aarch64-linux-gnu/bitcoin-9f109628c7bb-aarch64-linux-gnu.tar.gz
    31c381c6e6ef1819197c6ab663fdca39a793bc8739c2e43ff2effaf8678bddf1  guix-build-9f109628c7bb/output/arm-linux-gnueabihf/SHA256SUMS.part
    2d5809463039dbc89d92b9db64d82d13c80911f1f0c13fa6b45f12b21689b102  guix-build-9f109628c7bb/output/arm-linux-gnueabihf/bitcoin-9f109628c7bb-arm-linux-gnueabihf-debug.tar.gz
    14a601df6989f4b3d8dce942e647f681292cbb95fe46d2cf04e2e1e23d2bff19  guix-build-9f109628c7bb/output/arm-linux-gnueabihf/bitcoin-9f109628c7bb-arm-linux-gnueabihf.tar.gz
    5954cdadf141bf83f9a33b447c7428b2daeb359b66180690013f7d06a7b721b9  guix-build-9f109628c7bb/output/arm64-apple-darwin/SHA256SUMS.part
    9f75896ffc3452938274477a2eef0ec1b5cfda4af62a360237ad810124e9edb6  guix-build-9f109628c7bb/output/arm64-apple-darwin/bitcoin-9f109628c7bb-arm64-apple-darwin-codesigning.tar.gz
    6a088cdf10bcb58aec6d12300b0d0c0987ba4aaf3f6318a231d52a849f4cf713  guix-build-9f109628c7bb/output/arm64-apple-darwin/bitcoin-9f109628c7bb-arm64-apple-darwin-unsigned.tar.gz
    c3545e45dd615be8c52eb759dee75aab9c8b50cf9e83d845954ee709a60811ea  guix-build-9f109628c7bb/output/arm64-apple-darwin/bitcoin-9f109628c7bb-arm64-apple-darwin-unsigned.zip
    afc2c6c09f2e43bdcec2b16d4fc297898890afa312bc614b1fa22749ce5d706d  guix-build-9f109628c7bb/output/dist-archive/bitcoin-9f109628c7bb.tar.gz
    aecca0447f6cfb838d050077d6739a78f2fe73c7dcd052ca4e479482fa83f3fb  guix-build-9f109628c7bb/output/powerpc64-linux-gnu/SHA256SUMS.part
    6d7167ea5e1147c4791b0c0780efcbb975c04552f97f14c678f019ecabb0957b  guix-build-9f109628c7bb/output/powerpc64-linux-gnu/bitcoin-9f109628c7bb-powerpc64-linux-gnu-debug.tar.gz
    53bebb6f198ee39ad216036e277b61d6356e30eaee544aec3be1f9fb86c510be  guix-build-9f109628c7bb/output/powerpc64-linux-gnu/bitcoin-9f109628c7bb-powerpc64-linux-gnu.tar.gz
    fe015992a35270f6973a6502df0dfdc64f5543bb72b134440d5b699e0cdafc68  guix-build-9f109628c7bb/output/riscv64-linux-gnu/SHA256SUMS.part
    4648ecaa277019d4d119bc8570ff4819589267d984681886f38e3b8f8c90895f  guix-build-9f109628c7bb/output/riscv64-linux-gnu/bitcoin-9f109628c7bb-riscv64-linux-gnu-debug.tar.gz
    79ec1de1ad82f55451dd2584d184183c7f5e209e66f8de3bf2eecfae930b32a0  guix-build-9f109628c7bb/output/riscv64-linux-gnu/bitcoin-9f109628c7bb-riscv64-linux-gnu.tar.gz
    4fed8a9aff6484554eac3cab7471d74566e9db72cfaf553669c63c93a4d66c52  guix-build-9f109628c7bb/output/x86_64-apple-darwin/SHA256SUMS.part
    298421fd56aebb81e12e4a72829ef99a0430988e874a63bbdbf6d71fd0bc15f5  guix-build-9f109628c7bb/output/x86_64-apple-darwin/bitcoin-9f109628c7bb-x86_64-apple-darwin-codesigning.tar.gz
    1b044aa2928e8d97b0c5a0343a4b83c36c04283542b1d47ef8d80223ba386ec6  guix-build-9f109628c7bb/output/x86_64-apple-darwin/bitcoin-9f109628c7bb-x86_64-apple-darwin-unsigned.tar.gz
    7944476d60b37b027b823058f0ce8c2bf7a8f53a61b65cbccd53b7892805cbe8  guix-build-9f109628c7bb/output/x86_64-apple-darwin/bitcoin-9f109628c7bb-x86_64-apple-darwin-unsigned.zip
    c3244e01d99c88bdaff6394ece4a657b52b35b62551da9f089f16845bcbf3b93  guix-build-9f109628c7bb/output/x86_64-linux-gnu/SHA256SUMS.part
    463f2465b09744fc2793bab28303046780c0a28ad49876d8deb73221335841b6  guix-build-9f109628c7bb/output/x86_64-linux-gnu/bitcoin-9f109628c7bb-x86_64-linux-gnu-debug.tar.gz
    7a3e18d794563feb9c30508af462659fe22e1472c167af5d3562f8580713a080  guix-build-9f109628c7bb/output/x86_64-linux-gnu/bitcoin-9f109628c7bb-x86_64-linux-gnu.tar.gz
    a606787c1b8a2eb9bd5758045c3163068c0d99da2dcdbf3d1bbbec2960ed384b  guix-build-9f109628c7bb/output/x86_64-w64-mingw32/SHA256SUMS.part
    0e7aec5c238613751880e138552323be57a372f545210b345ce96eb0656a20a9  guix-build-9f109628c7bb/output/x86_64-w64-mingw32/bitcoin-9f109628c7bb-win64-codesigning.tar.gz
    0f20e02512a4e15fb98e2913e149f859a586f36ed8d42bd9b2c79fa83283eae9  guix-build-9f109628c7bb/output/x86_64-w64-mingw32/bitcoin-9f109628c7bb-win64-debug.zip
    4046975ddde76adfbbe4a5c25a576b099ca87b88b8081cf3a6e341b584d18fc5  guix-build-9f109628c7bb/output/x86_64-w64-mingw32/bitcoin-9f109628c7bb-win64-setup-unsigned.exe
    d5a84f7de8179e3a5e0043c9378dd27ac2ca8a36b8fa2d0bad07ad7ada0ae33e  guix-build-9f109628c7bb/output/x86_64-w64-mingw32/bitcoin-9f109628c7bb-win64-unsigned.zip
    

    </details>


    Claude suggests using inherit osslsigncode to shorten the patch and avoid adding modules:

    (define-public osslsigncode-2.14
      (package
        (inherit osslsigncode)
        (version "2.14")
        (source
         (origin
           (method git-fetch)
           (uri (git-reference
                 (url "https://github.com/mtrojnar/osslsigncode")
                 (commit version)))
           (file-name (git-file-name (package-name osslsigncode) version))
           (sha256
            (base32 "06ybcp9r8w0algxvvv0mz4h1cjw764b33s9b26n1dhvpl1dqc24c"))))))
    
  8. hebasto commented at 9:39 AM on September 15, 2026: member

    Concept ACK.

    #34948 missed the package nss-certs in splitting the codesigning to a separate guix manifest.

    I don't understand. There were no nss-certs before:https://github.com/bitcoin/bitcoin/blob/9c150222604478431669b66b2caa0d75e8324d4c/contrib/guix/manifest.scm#L430-L434

  9. in contrib/guix/manifest_codesign.scm:206 in 9f109628c7
     202 | @@ -203,7 +203,7 @@ signing and timestamping.  It is based on OpenSSL.")
     203 |          git-minimal)
     204 |    (let ((target (getenv "HOST")))
     205 |      (cond ((string-suffix? "-mingw32" target)
     206 | -           (list osslsigncode))
     207 | +           (list osslsigncode nss-certs))
    


    Sjors commented at 10:13 AM on September 15, 2026:
    HOST=x86_64-w64-mingw32 guix shell --manifest=contrib/guix/manifest_codesign.scm --dry-run -- true
    /home/guix/bitcoin/contrib/guix/manifest_codesign.scm:206:30: error: nss-certs: unbound variable
    hint: Did you forget `(use-modules (gnu packages nss))' or `#:use-module (gnu packages nss)'?
    
  10. pinheadmz commented at 11:07 AM on September 15, 2026: member

    Got the same error on 32.0rc1. Starting a windows only guix build on this branch to test sigs, $ HOSTS="x86_64-w64-mingw32" ./contrib/guix/guix-build


github-metadata-mirror

This is a metadata mirror of the GitHub repository bitcoin/bitcoin. This site is not affiliated with GitHub. Content is generated from a GitHub metadata backup.
generated: 2026-09-15 17:51 UTC

This site is hosted by @0xB10C
More mirrored repositories can be found on mirror.b10c.me