WIP: feat: Support sending silent payments

bitcoin-core/gui-qml: PR #1141

4 minor findings · 4 suggestions

Earlier concerns neither republished nor resolved: 2 suggestions. See the Run archive for their assessments.

Findings

Link

[minor] · Optional sp instructions discard a previously usable on-chain fallback

Links with a valid on-chain address now fail when optional sp is invalid or the wallet cannot send silent payments, because the parser retains no fallback.

Location: qml/models/bitcoinuri.cpp:79 (head).

Details and suggested fix

Previously, BitcoinUri::Parse ignored the optional sp parameter and imported the path address. It now rejects an invalid value and overwrites result.address with a valid silent-payment instruction. SendCreate.qml applies that single address, after which prepareTransactionInternal rejects watch-only and external-signer wallets. Preserve both destinations and whether the instruction was req-sp, then offer the valid on-chain fallback explicitly when optional silent-payment instructions are unusable. Unusable required instructions should continue to fail rather than downgrade silently.


Link

[minor] · Restored silent-payment transactions can bypass safe fee bumping

The new send workflow exposes a backend limitation: after restoring a pre-payment backup, Speed up can add inputs without regenerating the silent-payment output, making the replacement undiscoverable by the recipient.

Location: qml/models/bumptransactionmodel.cpp:133 (head).

Details and suggested fix

Restore a backup taken before an unconfirmed silent payment and rediscover the transaction from the mempool. Its recipient records and rbf_needs_sp_outputs marker are absent, so the activity model offers Speed up and prepareFeeBumpInternal takes the ordinary path. Pinned Core then reconstructs fixed destinations from the existing scripts and permits additional inputs. If those inputs change the silent-payment derivation, the replacement retains an output the recipient cannot discover by scanning. Before enabling this workflow, require a backend solution for unknown silent-payment provenance or conservatively block affected replacements. Cover the backup, restore and input-changing bump sequence with an integration test.


Link

[minor] · Fee bumping erases the original transaction's silent-payment identity

After Speed up, the original transaction loses its silent-payment addresses from details and search, even if that original later confirms.

Location: qml/models/transactionactivitymodel.cpp:37 (head).

Details and suggested fix

SilentPaymentAddresses reads only CWalletTx::m_sprecipients, but Core treats these records as temporary RBF bookkeeping. A successful bump calls MarkReplaced, which clears the recipients, erases their stored record and emits CT_UPDATED. The activity model consequently replaces the original transaction's addresses with an empty list, and reloading cannot recover them. Store the transaction-to-silent-payment-address association as durable history metadata separate from RBF state, exposed through the wallet interface, or explicitly limit the advertised history feature to the lifetime of those records.


Link

[minor] · Use maximum eligibility failures do not explain how to recover

A silent-payment maximum preview can show an amount before preparation fails with a per-coin eligibility error, rather than directing the user to manual coin selection.

Location: qml/models/walletqmlmodel.cpp:329 (head).

Details and suggested fix

AvailableSendAllCoins disables m_silent_payments, and the preview skips CheckSilentPaymentsInput. Preparation later checks each otherwise available coin without has_key_cache and returns the first error, such as a missing private key for an outpoint. For automatic selection after unlock, use silent-payment-aware AvailableCoins and its shared key cache, then translate skipped_silent_payments_ineligible into an actionable coin-selection message. Continue refusing the sweep rather than silently leaving ineligible coins behind, as Core's sendall does. Mark a preview that cannot check keys as provisional.


Optional improvements

Link

[suggestion] · Tests do not exercise the new silent-payment authorization and construction paths

Existing bump fixtures skip silent-payment preparation, and the URI, review-matching and Use maximum tests do not cover the new silent-payment branches.

Location: test/test_bumptransactionmodel.cpp:113 (head).

Details and suggested fix

MakeBumpableWallet configures bumpability but supplies neither the silent-payment marker nor recipients, so the tests miss unlocking and signing during preparation, relocking before review, and committing without signing again. Add a marked fixture that checks password retry, no commit before confirmation, and exactly one commit of the prepared transaction and recipients. Also cover sp and req-sp with empty paths, fallbacks and duplicate instructions; silent-payment review matching with and without change_pos; and a real-wallet Use maximum transaction whose generated output the recipient can discover.


Link

[suggestion] · Silent-payment request labels and messages do not reach review

Silent-payment URI labels and messages remain outside the reviewed snapshot, so confirmation omits the payee's stated name and purpose while still showing the address and amount.

Location: qml/pages/wallet/SendCreate.qml:533 (head).

Details and suggested fix

applyPaymentRequest retains the URI label and message on SendRecipient, but paymentRequestNote deliberately does not copy them into the private note for silent payments. captureReviewedRecipients then copies only recipient->label() and the request flag, and the review row uses that private label as its title. Since silent-payment validation requires the note to be empty, review displays only a generic request badge instead of the supplied context. Carry the public label and message in separate review-only snapshot fields, clearly distinguished from the private note.


Link

[suggestion] · The standalone fee-rate overflow fix is blocked by the feature series

The final overflow-fix commit can land against the existing Core pin independently of the silent-payments draft and its upstream dependency.

Location: qml/models/walletqmlmodel.cpp:204 at 61de215abf63 (commit) (commit).

Details and suggested fix

61de215abf63a57b9bec3784ff9362bf43e5c38f adds only a bounds check before whole_part * FEE_RATE_BASIS_VBYTES; the affected parser already exists at base. It needs neither the Core adaptation in 228e69790b1c7d30b72355c3243e87d7c8cc3aac nor the sending feature in cccf5abb291acc275778da89dcc36bd7ef5735a9. Move the fix first or submit it separately so the signed-overflow correction can be reviewed and merged without waiting for the silent-payment dependency.


Link

[suggestion] · Fee-bump authorization is mixed into the broader sending feature

The unlock-and-sign-before-review transition can be reviewed independently, but currently shares a commit with URI parsing, history and send construction.

Location: qml/models/bumptransactionmodel.cpp:133 at cccf5abb291a (commit) (commit).

Details and suggested fix

228e69790b1c7d30b72355c3243e87d7c8cc3aac adapts BumpTransactionModel to the new Core signatures. cccf5abb291acc275778da89dcc36bd7ef5735a9 then adds preparation-time unlocking and signing, relocking before confirmation, and the corresponding SpeedUpOverlay password flow alongside the other silent-payment features. Extract the model, header and overlay authorization changes together into a commit immediately after the Core adaptation. This preserves their dependencies while making the preparation-versus-commit authorization boundary easier to validate and bisect; it is a series-organization suggestion, not a head defect.


Coverage details

Earlier concerns

Earlier reports raised these, with the titles and severities shown there. This review neither republished nor resolved them.

Background

Ralph's summary of historical context for the behaviour affected by this change. The historical record reviewed here is incomplete.

Documented decisions

Silent-payment instructions are intended to be reusable without encouraging reuse of a fixed on-chain destination. During BIP352 development, an author explicitly opposed using the spend public key as a conventional fallback address because it would encourage address reuse. The discussion also explains that silent payments avoid an additional notification transaction or extra notification data.

This explains why the GUI treats the original silent-payment address separately from the generated Taproot output address, and why payment-link fallback policy involves a privacy tradeoff rather than merely parser convenience. It does not establish that every conventional fallback has the same privacy consequences as the specifically proposed spend-key fallback.

Source 1 · Source 2

Silent-payment sending historically required changes to transaction construction and coin selection, not just recognition of a new address string. The earlier Core sending proposal explicitly excluded Taproot script-path spends and unknown-witness inputs. The parent proposal deferred external-signer support pending hardware-wallet support.

These constraints explain the affected GUI's local-private-key restriction and its need to adapt both ordinary transaction preparation and its GUI-owned Use maximum construction path. The historical exclusions describe that proposal's implementation scope, not a universal prohibition on future collaborative or hardware-assisted implementations.

Source 1 · Source 2

Preserving the ability to fee-bump safely is an explicit design constraint of the Core sending proposal. It persists original silent-payment destinations for RBF, prevents older software from replacing these transactions, and blocks operations—including PSBT creation—that would produce a silent-payment transaction unsafe to fee-bump later.

At the pinned base, fee bumping reconstructs recipients from existing output scripts. At the pinned head, Core recomputes silent-payment outputs from saved destinations and original inputs, explaining that an unchanged output may become undiscoverable by the recipient if inputs change. This directly explains the GUI's recipient-metadata plumbing, special preparation/unlock flow for speed-up, and disabled silent-payment PSBT export.

Source 1

BIP321's query-parameter approach was proposed to let new payment instructions coexist with older wallets and conventional on-chain addresses. Allowing an empty root address provides an eventual migration path when recipients no longer want a legacy fallback, without moving the newer instructions to another field.

The base GUI parser requires a conventional address in the URI path. The changed parser accepts silent-payment instructions in sp or req-sp parameters and permits an empty path when such instructions are present. The historical rationale explains both compatibility-oriented fallback and silent-payment-only links, without settling every error-handling rule.

Source 1

Sending and receiving support were deliberately separable adoption steps. In the earlier Core discussion, Luke Dashjr argued that widespread sending support would make receiving practical sooner; the parent proposal describes independent send and receive capabilities.

This explains the usefulness of adding silent payments to an existing send workflow without requiring the same GUI to provide silent-payment address generation or scanning.

Source 1 · Source 2

Ralph's inferences

The distinction between estimating an output's size and constructing its actual destination explains why silent-payment preparation can require private-key access before review. A fixed address can supply its script immediately; a silent-payment destination supplies only a Taproot-sized placeholder until transaction inputs and their eligible private keys are available.

The pinned Core PaymentDestination contract explicitly distinguishes fixed scripts from input-dependent scripts, and CreateSilentPaymentsOutputs accesses eligible input keys. The GUI therefore defers fixed-amount silent-payment fee calculation until preparation and unlocks during replacement preparation. This explains the different preparation boundary; it does not imply that preparation itself broadcasts a payment.

Original silent-payment identities need separate wallet metadata because their reusable instruction strings are not the fixed destinations encoded in transaction outputs.

This explains why the changed activity model reads stored silent-payment recipients to display and search original addresses rather than deriving them through ordinary output-address decoding. Core's documented purpose for this metadata is safe RBF; using it for GUI history is an additional application use, not evidence of a permanent archival-history guarantee.

Source 1