{
 "number": 36534,
 "input_hash": "10b0cd95d061d240",
 "model": "ledger",
 "prompt_hash": null,
 "created": "2026-11-02T01:11:44+00:00",
 "result": {
  "summary": "Move compiler and linker hardening flags into a dedicated CMake interface library (`hardening_interface`) linked by `core_interface`, and pass those flags down to the secp256k1 subtree build.",
  "problem": "The secp256k1 subtree does not inherit flags from `core_interface`, so its objects are built without hardening flags such as FORTIFY, stack protection, stack clash protection, and branch/control-flow protection unless compiler defaults provide them. Because linkers drop binary-wide control-flow protection markers (like AArch64 BTI/PAC/GCS or x86_64 CET) if any linked object lacks them, the unhardened secp256k1 objects cause the final executable to lose hardware control-flow protections.",
  "card": "This pull request passes Bitcoin Core's compiler and linker hardening flags to the embedded libsecp256k1 subtree build by re-introducing a `hardening_interface` CMake target. Previously, secp256k1 objects were built without flags like stack protection and branch protection. Because linkers drop binary-wide control-flow integrity flags if even a single linked object lacks them, secp256k1 objects stripped control-flow markers from release binaries on toolchains that do not enable them by default. Testing on Ubuntu 26.04 with GCC 15 confirms this change restores the `AArch64 feature: BTI, PAC, GCS` elf note on bitcoind.",
  "evidence": [
   "Author notes: 'On aarch64 Ubuntu 26.04 with GCC 15 this also costs the whole binary its control flow property: master\\'s bitcoind has no AArch64 feature note, and the three secp256k1 objects are the only ones in the build tree without it.'",
   "Author verifies: 'With it, the same build shows AArch64 feature: BTI, PAC, GCS on bitcoind.'"
  ],
  "scope_notes": "Small build-system change reverting commit 77e553ab6a to re-introduce `hardening_interface` and forward its options to `cmake/secp256k1.cmake`.",
  "changed_since_previous": "Diff provided; the implementation matches the previous description.",
  "thread": {
   "last_event_at": "2026-11-01T18:50:06Z",
   "events": 2,
   "head_sha": "08bd06ccd488d5a40b1b29b0a3052663668c8f52",
   "schema_floor": 2,
   "schema": 2
  },
  "waiting_on": [
   {
    "at": "2026-11-01",
    "id": "c:6562328475",
    "on": "reviewer",
    "url": "https://github.com/bitcoin/bitcoin/pull/36534#issuecomment-6562328475",
    "what": "hebasto to review the update in 08bd06ccd4 addressing Ralph's feedback"
   },
   {
    "at": "2026-11-01",
    "id": "c:6562328475",
    "on": "reviewer",
    "url": "https://github.com/bitcoin/bitcoin/pull/36534#issuecomment-6562328475",
    "what": "hebasto to check the update addressing Ralph's feedback"
   }
  ],
  "risk": {
   "level": "medium",
   "touches": [
    "build"
   ],
   "why": "Passing additional compiler and linker flags to libsecp256k1 could cause build failures on esoteric platforms or toolchain configurations."
  },
  "discussion": {
   "author_status": "last statement processed 2026-11-01",
   "open_concerns": [],
   "resolved_concerns": [
    "hebasto: address Ralph's feedback (fixed by fametrano 2026-11-01)"
   ]
  },
  "reviewability": {
   "state": "Ready",
   "label": "Ready",
   "reason": "Nothing known that would invalidate a review now."
  },
  "agreement": {
   "state": "Crickets",
   "summary": "Crickets: no substantive comment either way",
   "reason": "Initial record. hebasto asked that Ralph's feedback be addressed; fametrano pushed commit 08bd06ccd4 to check hardening flags with the C compiler and replied. / Initial record. hebasto noted that Ralph's feedback should be addressed; fametrano pushed an update addressing it.",
   "evidence": [],
   "objections": [
    {
     "reviewer": "hebasto",
     "association": "MEMBER",
     "type": "suggestion",
     "kind": "approach",
     "harm": "",
     "request": "address Ralph's feedback",
     "question": "",
     "text": "address Ralph's feedback",
     "clears_with": "answer",
     "blocking": false,
     "status": "fixed",
     "status_note": "author pushed commit 08bd06ccd4 checking hardening flags with the C compiler",
     "cleared": true,
     "author_replied": true,
     "others_replied": false,
     "fix_pushed": true,
     "replies": [
      "c:6562328475"
     ],
     "evidence": "2026-10-27: 'I think that Ralph's feedback should be addressed.'",
     "url": "https://github.com/bitcoin/bitcoin/pull/36534#issuecomment-6444090309",
     "id": "c:6444090309",
     "at": "2026-10-27",
     "status_at": "2026-11-01",
     "status_by": "fametrano",
     "resolution_evidence": "2026-11-01: fametrano: 'Ralph's finding is addressed in 08bd06ccd4'",
     "pin": null,
     "from_schema": 2
    }
   ],
   "support": [],
   "participants": [
    {
     "login": "hebasto",
     "stance": "neutral",
     "note": "asked to address Ralph's feedback",
     "association": "MEMBER",
     "comments": 1,
     "first": "2026-10-27",
     "last": "2026-10-27"
    }
   ],
   "derivation": "no substantive comment either way",
   "model_state": null,
   "corrections": [],
   "notes": "Initial record. hebasto asked that Ralph's feedback be addressed; fametrano pushed commit 08bd06ccd4 to check hardening flags with the C compiler and replied. / Initial record. hebasto noted that Ralph's feedback should be addressed; fametrano pushed an update addressing it."
  },
  "dependencies": {
   "depends_on": [],
   "enables": []
  },
  "categories": [
   {
    "name": "build",
    "member": true,
    "evidence": "Carries the 'Build system' label and modifies CMakeLists.txt and cmake/secp256k1.cmake to manage compiler flags passed to secp256k1.",
    "band": "P2",
    "reason_tag": "bug fix",
    "score": 0.7,
    "factors": {
     "bug_severity": 2,
     "leverage": 0,
     "performance": 0,
     "security_stability": 2,
     "user_value": 0
    },
    "rationale": "Fixes a regression where secp256k1 objects omit hardening flags, causing linkers to drop binary-wide hardware control-flow protections (like AArch64 BTI/PAC/GCS or x86_64 CET) from bitcoind. As the author notes, 'the unhardened secp256k1 objects cause the final executable to lose hardware control-flow protections' on master."
   }
  ],
  "confidence": "high",
  "uncertainties": [],
  "needs": []
 },
 "cost_usd": 0.0,
 "source": {
  "record": "2026-11-02T01:11:44+00:00",
  "code": "2026-10-17T01:21:25+00:00",
  "judgments": 1
 }
}