Skip to content

Feat/miden to evm private notes - #7

Open
Man-Jain wants to merge 2 commits into
mainfrom
feat/miden-to-evm-private-notes
Open

Feat/miden to evm private notes#7
Man-Jain wants to merge 2 commits into
mainfrom
feat/miden-to-evm-private-notes

Conversation

@Man-Jain

Copy link
Copy Markdown
Contributor

No description provided.

Lets the sponsor choose whether the P2IDE note backing a Miden→EVM intent is
private or public, and threads the choice through the note factory to the SDK.

useMidenPrivateNotesSupport reads midenPrivateNotesSupported from
GET /miden-recipient and disables the option when the allocator does not
advertise it. It blocks rather than silently downgrading to public: a private
note whose body the allocator cannot accept can be neither validated nor
consumed, and a private P2IDE whose body is lost can never be reclaimed either
— the serial number is random and reclaiming means consuming. An allocator that
omits the flag reads as unsupported.
…w tab

Adds a "Payout note visibility" selector to the EVM→Miden withdraw flow and the
two ways a user gets the note body back.

Private is opt-in, never inherited: the note publishes only a commitment, so
its body is the only thing that can consume it. Changing the selection clears
any pending quote, since the choice is part of the signed mandate and a stale
quote would carry the claim hash for the other visibility.

WithdrawNoteFileCard hands the body over at settlement — download as the exact
binary a wallet imports, or copy the base64.

RecoverNotesCard covers the case that cannot be solved on the device: the
intent nonce lives only in the browser and is not on-chain, so a user on a new
machine cannot ask for their own note. One signature lists their past intents
and re-downloads any private body. Sign-out revokes the session server-side —
clearing local state alone would leave a valid bearer session for its full life.

All of it goes through the SDK rather than raw fetch. The EIP-4361 message has
to byte-match the allocator, and an app-local copy is a landmine for anyone
integrating from this codebase.

Copy states plainly that this hides the payout from other chain observers, not
from Epoch, which mints it.
@vercel

vercel Bot commented Aug 19, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
miden-integration-example Error Error Aug 19, 2026 6:11am

@github-actions

Copy link
Copy Markdown

React Doctor found no new issues. 🎉

Reviewed by React Doctor for commit b48d219.

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.

2 participants