Skip to content

feat(rfq): complete taker settlement authorization - #39

Open
tvolk131 wants to merge 1 commit into
codex/rfq-taker-clientfrom
codex/rfq-taker-wallet
Open

feat(rfq): complete taker settlement authorization#39
tvolk131 wants to merge 1 commit into
codex/rfq-taker-clientfrom
codex/rfq-taker-wallet

Conversation

@tvolk131

@tvolk131 tvolk131 commented Aug 28, 2026

Copy link
Copy Markdown
Contributor

Summary

  • add a keyless taker whole-PSET coordinator bound to the exact composed route, RFQ quote, settlement layout, and validated market
  • split caller-wallet work into blind-then-validate-then-sign capabilities, with exact provider/wallet mutation envelopes
  • validate authoritative market/chain state and prevouts, quote liveness/economics, confidential proofs and balance, owned-output openings, explicit-SIGHASH_ALL Taproot signatures, and fee/weight limits
  • add a durable redb execution journal for arm-before-dispatch, status-first byte-identical retry, restart recovery, and provider-signed result verification
  • carry and authenticate tree-less P2TR internal-key metadata from provider inventory through quotes and composition
  • extract shared Liquid settlement cryptography used by both provider and taker validation
  • update the README and liquidity roadmap to describe the implemented boundary and remaining production integrations

Safety boundaries

  • recovered quotes are recovery-only and cannot regain live settlement authority after restart
  • Execute accepts only durably armed attempts; post-dispatch failures remain explicitly uncertain
  • every retry checks authenticated status first and reuses the exact persisted bytes
  • provider blinding, taker blinding, and taker signing each have separately constrained mutation scopes
  • signing authority is exposed only after the fully blinded transaction passes disclosure, proof/balance, owned-opening, and fee checks
  • the launch profile is intentionally limited to one RFQ leg plus ordinary tree-less P2TR wallet inputs using explicit SIGHASH_ALL

A production taker wallet/source adapter, wallet input/change selection, broadcast, and confirmation monitoring remain follow-up work.

Verification

  • cargo fmt --all -- --check
  • cargo clippy --locked --offline --workspace --all-targets -- -D warnings
  • cargo test --locked --offline --workspace --all-targets -- --test-threads=1
  • cargo test --locked --offline --workspace --doc

A separate security review found no remaining launch-blocking issue in this slice.

Stack

This PR contains one commit on top of #38 (codex/rfq-taker-client). Retarget it to the eventual merged base after #38 lands.


View with [code]smith Autofix with [code]smith
Need help on this PR? Tag @codesmith-bot with what you need. Autofix is disabled.

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Aug 28, 2026

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review Completed 2026-08-28T23:57:04.807831Z 234334e PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 234334ebdb

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

pub id: u16,
pub outpoint: OutPoint,
pub witness_utxo: TxOutDto,
pub internal_key: FixedBytes32,

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Version the incompatible quote-input wire change

Adding this required field changes both the strict deny_unknown_fields JSON DTO and the signed canonical quote transcript, but SCHEMA_VERSION, ALPN, QUOTE_ATTESTATION_DOMAIN, and CanonicalFirmQuoteV1 remain at v1. During a mixed-version deployment, old clients reject new quotes as containing an unknown field and new clients cannot decode old quotes because the field is missing, even though both peers advertise the same protocol version; bump the wire/attestation version so this incompatibility is detected at negotiation rather than as a generic decode failure.

Useful? React with 👍 / 👎.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant