Repository navigation
[Review] Merge bitcoin/bitcoin#36838: guix: backport oscrypto PBKDF2 timing fix - #10
Conversation
1575462b22b8584a49103eee7ad5a7ccf3289c4b guix: backport oscrypto PBKDF2 timing fix (Sjors Provoost) Pull request description: With substitutes disabled, `guix-codesign` can fail when building [oscrypto](https://pypi.org/project/oscrypto/) 1.3.0. The `test_dump_private` test raises `ZeroDivisionError`. The Guix time-machine bump in bitcoin#36233 (merged after the 32.x branch-off) pulls in OpenSSL 3.5.5, which can finish oscrypto's initial PBKDF2 benchmark in under a millisecond. oscrypto truncates this duration to zero and then divides by it. This was fixed upstream in wbond/oscrypto@144c121 This PR adds the fix to `contrib/guix/patches`. It can be dropped once a new oscrypto release includes the fix and a Guix time machine bump includes it. ACKs for top commit: fanquake: ACK 1575462b22b8584a49103eee7ad5a7ccf3289c4b Tree-SHA512: 6a9e5bccb3d239d1638cc4005445359d1674e7b3a5dfc037d9cac92757047068db154d5574b382e90ac2995d8ebdf8f15551021ad399683b8a5d92f1bd6965a2 Cherry-picked-from: bitcoin/bitcoin@5c4e837
1. SummaryThis merge backports upstream Effect scope, verified: the only manifest consumer is Motivation (from the PR description): after the time-machine bump in #36233 pulled in OpenSSL 3.5.5, oscrypto 1.3.0's PBKDF2 calibration can complete in under a millisecond; the duration was truncated to zero and subsequently used as a divisor, crashing 2. Consensus & ValidationNone. No 3. Security, P2P & DoSNone for Bitcoin Core runtime. I read all 33 lines of
4. Concurrency & LockingNone. No C++ code, mutexes, or lock annotations involved. 5. Code Quality & Test Coverage
6. Cross-Audit Reconciliation & Post-Merge VerdictConfirmed by both auditors and re-verified here: the manifest wiring and all three manifest-level consumers ( Checked by one auditor and verified: Checked by one auditor and dropped/downgraded: the claimed Could not verify from this repo (inherent): that the patch applies cleanly to the exact oscrypto 1.3.0 sdist used by the pinned Guix, and that the caller in Overall risk: low — build-only change, benign arithmetic, fail-closed on patch mismatch. Key lines to re-check in review: Triage: routine 📊 Token Usage & Review Stats
|
Upstream commit: bitcoin/bitcoin@5c4e837
1575462b22b8584a49103eee7ad5a7ccf3289c4b guix: backport oscrypto PBKDF2 timing fix (Sjors Provoost)
Pull request description:
With substitutes disabled,
guix-codesigncan fail when building oscrypto 1.3.0. Thetest_dump_privatetest raisesZeroDivisionError.The Guix time-machine bump in bitcoin/bitcoin#36233 (merged after the 32.x branch-off) pulls in OpenSSL 3.5.5, which can finish oscrypto's initial PBKDF2 benchmark in under a millisecond. oscrypto truncates this duration to zero and then divides by it. This was fixed upstream in wbond/oscrypto@144c121
This PR adds the fix to
contrib/guix/patches. It can be dropped once a new oscrypto release includes the fix and a Guix time machine bump includes it.ACKs for top commit:
fanquake:
ACK 1575462b22b8584a49103eee7ad5a7ccf3289c4b
Tree-SHA512: 6a9e5bccb3d239d1638cc4005445359d1674e7b3a5dfc037d9cac92757047068db154d5574b382e90ac2995d8ebdf8f15551021ad399683b8a5d92f1bd6965a2