Skip to content

feat: implement Nano (XNO) off-chain message signing (ORIS-001)#217

Open
cbrunnkvist wants to merge 9 commits into
open-wallet-standard:mainfrom
OpenRai:feat/nano-sign-message
Open

feat: implement Nano (XNO) off-chain message signing (ORIS-001)#217
cbrunnkvist wants to merge 9 commits into
open-wallet-standard:mainfrom
OpenRai:feat/nano-sign-message

Conversation

@cbrunnkvist
Copy link
Copy Markdown
Contributor

@cbrunnkvist cbrunnkvist commented Apr 25, 2026

Summary

Implement Nano Off-chain Message Standard to support the sign_message interface for the Nano (XNO) chain.
Example CLI output:

% cargo run -p ows-cli -- sign message --wallet test --message 'I am me.' --chain nano
3de8620fb30967916d3dc36cd09eba9a633d1678b986fbc31b70ae2834db25a898085bbce32b744aef42ed56b5c001ffebd5516e78c9f22c678dde2d8bdc150a

Implementation note

Raw byte signing is deliberately unsupported for Nano off-chain messages in order to prevent protocol confusion between block signatures and general signatures; the "NOMS" specification implemented by the PR is designed precisely to safely wrap off-chain text.

What this means for OWS

The standard OWS sign_message & CLI behaves identically to other chains for the end-user while securely conforming to the domain-separated Nano standard internally!

Technical notes

  • Adheres strictly to the format set forward by ORIS-001, which serendipitously happens to comply with the guidelines proposed in PR docs: clarify sign_message contract across chains #185 ...
  • No new cryptographic dependencies — reuses blake2 and ed25519-dalek (hazmat) from the original implementation.
  • Handles padding boundaries, ensuring the maximum message length complies with the uint32 specification before yielding a SignerError (a potential source of bugs otherwise).

Testing

  • Replaces the "unsupported" error-test with test_sign_message_noms
  • All workspace tests pass (cargo test --workspace 268 total tests).

@vercel
Copy link
Copy Markdown

vercel Bot commented Apr 25, 2026

@cbrunnkvist is attempting to deploy a commit to the MoonPay Team on Vercel.

A member of the Team first needs to authorize it.

@cbrunnkvist cbrunnkvist marked this pull request as ready for review April 25, 2026 07:50
@cbrunnkvist cbrunnkvist requested a review from njdawn as a code owner April 25, 2026 07:50
@cbrunnkvist
Copy link
Copy Markdown
Contributor Author

done-done ™

@cbrunnkvist
Copy link
Copy Markdown
Contributor Author

cbrunnkvist commented May 1, 2026

image

Well since you ask... 🧐 nope, that didn't work.

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