Skip to content

Add offline Cashu V3 decoding for Mission 84 - #99

Open
Nitjsefnie wants to merge 3 commits into
Jolah1:mainfrom
Nitjsefnie-OSC:84-offline-cashu-decoder
Open

Add offline Cashu V3 decoding for Mission 84#99
Nitjsefnie wants to merge 3 commits into
Jolah1:mainfrom
Nitjsefnie-OSC:84-offline-cashu-decoder

Conversation

@Nitjsefnie

@Nitjsefnie Nitjsefnie commented Aug 25, 2026

Copy link
Copy Markdown
Contributor

Summary

Adds a hands-on Mission 84 exercise that decodes a bundled Cashu V3 sample entirely in the browser and reports its mint URL, amount, and proof count. The token remains local; malformed or unsupported input is rejected before the mission can complete.

Related Issues and Pull Requests

Relates to #84

This implements the issue's self-contained Mission 84 path. The umbrella issue's other proposed hands-on missions remain open.

Changes

  • Added lesson copy and an official bundled V3 sample for the offline decoding exercise.
  • Added base64url, UTF-8, and JSON decoding with validation for proof amount, V1 keyset ID, secret, and compressed secp256k1 point metadata.
  • Added canonical completion facts and server-side checks without submitting the raw token.
  • Added browser and API coverage for valid, malformed, unsupported, and later-proof inputs.

Testing

  • Exact-candidate run 32870646593 tested c0fb6d6e72827d4d6d8773118d5a735957c39c9e; all 66 focused browser assertions passed after a locked frontend install, backend release build, Vite launch, and Chrome execution.
  • Test-first run 32870302111 failed the five expected zero-completion assertions before implementation.
  • Isolated mutations for generic keyset IDs, empty secrets, and generic point hex were rejected by runs 32870986920, 32870990374, and 32870993369.

Bugs Discovered

Follow-ups / Known Limitations

  • This exercise validates supported V3 metadata offline; it does not contact the mint or verify proof signatures against mint keys.
  • V4/CBOR cashuB tokens are not decoded by this exercise and receive a focused explanation.

Dependencies

  • Promoted @noble/curves to a direct production dependency at the already locked version 1.9.7; its resolved version and integrity entry are unchanged.

Generated by GPT-5.6 Sol (brief, implementation, testing, review, verification)

Nitjsefnie and others added 3 commits August 25, 2026 16:39
Co-Authored-By: GPT-5.6 Sol <noreply@openai.com>
Co-Authored-By: GPT-5.6 Sol <noreply@openai.com>
Co-Authored-By: GPT-5.6 Sol <noreply@openai.com>
@vercel

vercel Bot commented Aug 25, 2026

Copy link
Copy Markdown

@Nitjsefnie is attempting to deploy a commit to the jolah1's projects Team on Vercel.

A member of the Team first needs to authorize it.

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