build: Phase 3 of UPnP hardening — drop miniupnpc from depends/ + finish Windows CI alignment [post-Codex] #19
Labels
No labels
enhancement
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
SubGeniusFinance/Offerings-to-Cthulhu#19
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Follow-up to #10. Phase 3 of the UPnP-hardening plan. Phase 1 (release-notes recommendation in v2.0.4/v2.0.5) and Phase 2 (runtime default flip via #14, squash
63626e76) are done; this is the cleanup pass.Surprise finding during scoping
Auditing the tree showed Phase 3 is much smaller than the parent issue suggested. Linux is already there. Only the Windows Qt release still bundles miniupnpc:
--without-miniupnpcper the build recipelinux-build-depends.yml:100)--without-miniupnpcwindows-build-depends.yml)So Phase 3 is really "finish the Windows side and remove the dependency tree."
Scope — single bundled PR, post-Codex
Two layers, landing together rather than as two separate PRs:
Layer 1 — build-system (
+1 / −28LOC)--without-miniupnpcto the Windows CI configure invocation.github/workflows/windows-build-depends.ymlminiupnpcfrom the depends package listdepends/packages/packages.mk:19(upnp_packages=miniupnpc)depends/packages/miniupnpc.mkLayer 2 — source strip (
~−200 LOC)MapPort/ThreadMapPortUPnP wrapper codesrc/net.cpp(under#ifdef USE_UPNP)-upnphelp-text + SoftSetBoolArg plumbingsrc/init.cppfUseUPnPQSettings entry + optionsdialog UPnP checkboxsrc/qt/optionsmodel.cpp,src/qt/forms/optionsdialog.uiconfigure.ac:53-55, 398-403, 590-614Net change: ~
+1 / −230LOC across the combined PR.Scope decision: why bundled, why post-Codex
The original draft of this issue split Layer 1 (minimum-viable, "arguably safe pre-Codex") from Layer 2 (aggressive, hard-freeze). On reflection that split is the wrong shape:
-Wa,-mbig-objsaga, the TOUCHINPUT/Jammy pin). A red CI run on the wrong day adds noise to a window that should stay boring.So: land both layers together as a single PR after block 1,050,667 (Codex window close + safety margin).
Side-effects of the bundled change
Offeringsd -upnp=1on the resulting binary becomes a silent no-op (the arg isn't recognized —init.cppno longer registers it)upnp=1inOfferings.confknow to remove itReversibility
Trivial —
git revertthe PR. The earlier "irreversible without re-adding the recipe" framing was overstated; even Layer 2's ~200 LOC of UPnP wrapper code is fully recoverable from git history.Trade-offs / What this isn't
References
depends/packages/packages.mk:19—upnp_packages=miniupnpcdepends/packages/miniupnpc.mk— 27-line recipe to delete.github/workflows/windows-build-depends.yml— needs--without-miniupnpcadded.github/workflows/linux-build-depends.yml:100— pattern to copy (already has--without-miniupnpc)configure.ac:53-55, 398-403, 590-614— UPnP detection + macro definition logicsrc/net.cpp,src/init.cpp,src/qt/optionsmodel.cpp— source-side#ifdef USE_UPNPguards to strip63626e76)bitcoin/bitcoin#23956(2021, removed miniupnpc from depends in Bitcoin Core)The Slumbering Lord no longer carries unused trinkets in His pockets. Iä Iä.
Superseded by #37.
Scope widened from "strip miniupnpc, replace with nothing" to "strip miniupnpc, replace with libnatpmp." Reasoning: the strip-only plan would leave home/desktop users with no auto-port-forwarding at all, which is fine for VPS-hosted nodes but a real UX regression for the end-user surface that the Electrum / mobile-extension work in #36 targets.
The Layer 1 (depends/ + CI) and Layer 2 (source rewrite) breakdown carries over to #37 unchanged in shape; only the destination library differs. Post-Codex landing decision (post block 1,050,667) carries over too.
Closing as superseded (this exact scope) rather than completed.