mleku
ea4a54c5e7
Add Cashu blind signature access tokens (NIP-XX draft)
Implements privacy-preserving bearer tokens for relay access control using
Cashu-style blind signatures. Tokens prove whitelist membership without
linking issuance to usage.
Features:
- BDHKE crypto primitives (HashToCurve, Blind, Sign, Unblind, Verify)
- Keyset management with weekly rotation
- Token format with kind permissions and scope isolation
- Generic issuer/verifier with pluggable authorization
- HTTP endpoints: POST /cashu/mint, GET /cashu/keysets, GET /cashu/info
- ACL adapter bridging ORLY's access control to Cashu AuthzChecker
- Stateless revocation via ACL re-check on each token use
- Two-token rotation for seamless renewal (max 2 weeks after blacklist)
Configuration:
- ORLY_CASHU_ENABLED: Enable Cashu tokens
- ORLY_CASHU_TOKEN_TTL: Token validity (default: 1 week)
- ORLY_CASHU_SCOPES: Allowed scopes (relay, nip46, blossom, api)
- ORLY_CASHU_REAUTHORIZE: Re-check ACL on each verification
Files:
- pkg/cashu/bdhke/: Core blind signature cryptography
- pkg/cashu/keyset/: Keyset management and rotation
- pkg/cashu/token/: Token format with kind permissions
- pkg/cashu/issuer/: Token issuance with authorization
- pkg/cashu/verifier/: Token verification with middleware
- pkg/interfaces/cashu/: AuthzChecker, KeysetStore interfaces
- pkg/bunker/acl_adapter.go: ORLY ACL integration
- app/handle-cashu.go: HTTP endpoints
- docs/NIP-XX-CASHU-ACCESS-TOKENS.md: Full specification
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-28 11:30:11 +02:00
..
2025-12-14 20:50:49 +01:00
2025-12-11 22:17:29 +01:00
2025-12-12 08:47:25 +01:00
2025-11-04 20:29:19 +00:00
2025-10-24 21:03:44 +01:00
2025-12-01 21:39:28 +00:00
2025-10-16 12:41:32 +01:00
2025-11-21 19:13:18 +00:00
2025-11-21 19:13:18 +00:00
2025-11-21 19:13:18 +00:00
2025-11-08 08:54:58 +00:00
2025-12-04 09:28:13 +00:00
2025-12-04 09:28:13 +00:00
2025-11-14 12:15:52 +00:00
2025-11-25 06:03:22 +00:00
2025-12-25 05:30:07 +01:00
2025-11-06 16:18:09 +00:00
2025-11-27 22:07:32 +00:00
2025-12-02 13:30:50 +00:00
2025-12-28 11:30:11 +02:00
2025-11-03 19:55:14 +00:00
2025-11-03 19:02:20 +00:00
2025-12-04 09:28:13 +00:00
2025-10-10 20:36:53 +01:00
2025-10-10 10:30:48 +01:00
2025-12-14 18:36:04 +01:00
2025-12-02 18:12:11 +00:00
2025-11-21 15:28:07 +00:00
2025-11-21 15:28:07 +00:00
2025-11-21 15:28:07 +00:00
2025-10-21 21:46:07 +01:00
2025-11-21 15:28:07 +00:00
2025-12-02 07:51:59 +00:00
2025-11-21 15:28:07 +00:00
2025-11-26 09:52:29 +00:00
2025-11-06 16:18:09 +00:00
2025-12-12 08:47:25 +01:00
2025-12-12 21:59:00 +01:00
2025-11-06 16:18:09 +00:00
2025-11-14 12:15:52 +00:00
2025-11-05 05:54:47 +00:00
2025-11-06 16:18:09 +00:00
2025-11-06 16:18:09 +00:00
2025-11-06 16:18:09 +00:00
2025-12-02 11:21:28 +00:00
2025-12-16 10:39:02 +01:00
2025-10-09 14:55:29 +01:00