Skip to content

Document ML-DSA signature verification - #3187

Open
kaankacar wants to merge 2 commits into
mainfrom
3184-ml-dsa-signature-verification
Open

kaankacar wants to merge 2 commits into
mainfrom
3184-ml-dsa-signature-verification

Conversation

@kaankacar

Copy link
Copy Markdown
Contributor

Refs #3184

What

  • docs/learn/fundamentals/contract-development/authorization.mdx: add the section "ML-DSA and post-quantum signatures". It lists the three host functions, the key and signature sizes, the context argument, and the Rust SDK methods.
  • docs/build/guides/contract-accounts/smart-wallets.mdx: add a short section "ML-DSA on Stellar" that links to it.
  • docs/learn/fundamentals/fees-resource-limits-metering.mdx: point the ContractCostType link at the Protocol 30 XDR. That list has the ML-DSA cost types.

Verification

  • CAP-87: the host function names, the parameter set table, and the context rule (0 to 255 bytes).
  • rs-soroban-sdk v30.0.0-rc.1 soroban-sdk/src/crypto.rs: Crypto::ml_dsa_44_verify, ml_dsa_65_verify, and ml_dsa_87_verify. They panic on a signature that is not valid.
  • stellar-xdr v30.0 Stellar-contract-config-setting.x lines 116-318: ContractCostType, with the ML-DSA entries 86 to 94.
  • Horizon, 2026-11-23: Mainnet runs Protocol 30 from ledger 65633432.
  • pnpm check passes.

Notes

Protocol 30 (CAP-87) adds host functions that verify ML-DSA (FIPS 204)
signatures.

- authorization: add a section with the host functions, the key and
  signature sizes, and the Rust SDK methods.
- smart-wallets: add a short section that links to it.
- fees-resource-limits-metering: link ContractCostType at the Protocol 30
  XDR, which has the ML-DSA cost types.
@mintlify

mintlify Bot commented Nov 23, 2026 •

Copy link
Copy Markdown
Contributor

Preview deployment for your docs. Learn more about Mintlify Previews.

Project Status Preview Updated
stellar-docs 🟢 Ready View Preview Nov 23, 2026, 8:21 PM

@kaankacar

Copy link
Copy Markdown
Contributor Author

/triage

@stellar-doxie

stellar-doxie Bot commented Nov 23, 2026

Copy link
Copy Markdown
Contributor

🤖 Automated message from Doxie.

Reviewing because @kaankacar asked with /triage.

Verified: the names, sizes, context rule, and envelope scope match CAP-87 and soroban-sdk v30.0.0-rc.1. The anchor renders on the preview. I pushed one fix (53343b4): the fees page's other XDR link now uses the same v30.0 commit, with the type name and closing parenthesis corrected.

Ready to merge.

What I checked
  • Host functions, NIST categories, key and signature sizes, context of 0 to 255 bytes: stellar/stellar-protocol core/cap-0087.md (Specification and parameter set table). The same functions are in rs-soroban-env@v30.0.1 soroban-env-common/env.json:2825-2851.
  • "Does not change envelope signatures": CAP-87 Motivation ("does not change the transaction signature scheme ... which remains Ed25519").
  • SDK methods and panic behavior: rs-soroban-sdk@v30.0.0-rc.1 soroban-sdk/src/crypto.rs:193-300 (ed25519_verify also panics, :154). The methods are unchanged on main.
  • Versions: checked against soroban-sdk 30.0.0-rc.1 (crates.io, 2026-10-21). The newest stable, 29.0.1, has no ML-DSA, so the page names the rc on purpose.
  • Protocol 30 on Mainnet: horizon /ledgers/65633431 is protocol 29, /ledgers/65633432 is protocol 30.
  • ContractCostType link: stellar-xdr tag v30.0 = 4f524bba, L116-L318 is the full enum, with ML-DSA entries 86 to 94.
  • Pushed fix: line 163 linked ConfigSettingsEntry at the old commit e372df9 (L223-L226). It now links ConfigSettingEntry at v30.0 L430-L433, the same cost-param cases. This keeps one XDR tag on the page (maintainer-style.md, 📂 Separate ledgers page into entries and headers #2398).
  • Preview at 5038e32 and 53343b4: all three pages return 200, id="ml-dsa" exists, and the smart-wallets link targets it. checks passes at 53343b4, and mint broken-links reports none.
  • FIPS 204 PDF: GET returns 200 application/pdf. HEAD returns 404, which is a server quirk.
  • SWEEP: searched for ml-dsa, post-quantum, FIPS 204, the old XDR commit, and signature-scheme lists. No other page lists contract signature schemes as complete. The authorization.mdx XDR links use one commit (e372df9) consistently, and this PR adds none there.
  • Necessity: no page documented the CAP-87 host functions, so a reader could not find the post-quantum signer option.
  • Not run: no code or CLI commands are added.

@stellar-doxie stellar-doxie Bot added the bot:ready-to-merge Bot verified and approved; waiting for a maintainer to merge label Nov 23, 2026

@ElliotFriend ElliotFriend left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Looks good, checked against CAP-87 and the SDK source.

This branch was successfully deployed

1 active deployment
staging — 53343b46 Deployed Nov 23, 2026 by mintlify[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bot:ready-to-merge Bot verified and approved; waiting for a maintainer to merge

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants