Clear and Blind Auth #510
No reviewers
Labels
No labels
DB & Storage
Deployment
Error Handling & Logging
Maintenance
Payment Backend
backport
backport v0.13.x
backport v0.14.x
backport v0.15.x
bindings
blocked
bug
cdk-sql
ci
cli
deps
documentation
duplicate
enhancement
good first issue
help wanted
invalid
keep-open
ldk-node-ui
migrations
mint
mutation-testing
needs rebase
needs review
new nut
nut change
question
ready
rust-version
rustfmt
stacked hold
stale
testing
wallet
weekly-report
wontfix
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
cashubtc/cdk!510
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "auth"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Description
closes #69
Notes to the reviewers
Suggested CHANGELOG Updates
CHANGED
ADDED
REMOVED
FIXED
Checklist
just final-checkbefore committingDoes this need to be a separate DB?
It makes DB backup and restore more complicated (2 files to backup or restore, on restore the correct pair of files has to be used).
@ -0,0 +1,413 @@use cdk_common::{CurrencyUnit, MintKeySet};Perhaps
is_protectedis better?nutxxcan be renamed tonut21nutxx1can be renamed tonut22It makes sense to have two separate databases since, while there is large overlap between them, they serve different purposes. For example, the auth database may grow faster as keysets are likely to be rotated more frequently. This separation also helps with separation of concerns between the auth stuff and ecash stuff.
I don't think an extra file adds too much complexity. The auth database is also less critical to back up since if it's lost, the mint can simply create new auth keysets, require everyone to reauth, and generate new tokens.
21
21
@ -0,0 +289,4 @@}/// Auth for request#[instrument(skip(self))]Depending on final wording of spec we should error here or allow proofs without a dleq proof.
Found a few NITs, but generally looks good.
@ -0,0 +1,369 @@//! 22 Blind AuthSimpler way to write it.
#[serde(default)]falls back toDefault, for which the value is0(equivalent todefault_input_fee_ppk).So I think this completely covers
deserialize_input_fee_ppkdefault_input_fee_ppkso they can both be removed too.
@ -0,0 +1,196 @@use std::path::Path;@ -0,0 +1,140 @@use std::path::Path;@ -0,0 +1,866 @@use std::env;Looks like some old unused test code.
@ -0,0 +1,150 @@use std::sync::Arc;I thought this too but doing this fails the test on line 502, which is how nutshell responds with auth keysets.
I see, you're right.
@ -510,0 +574,4 @@/// Clear Auth RequiredClearAuthRequired,/// Clear Auth FailedClearAuthFailed,Use the correct error codes from spec