summaryrefslogtreecommitdiffstats
path: root/internal/auth/credentials.go
Commit message (Collapse)AuthorAgeFilesLines
* refactor: migrate nostr dependency to code.northwest.iobndw22 hours1-1/+1
| | | | Updated all import references from northwest.io/nostr to code.northwest.io/nostr and removed the local replace directive from go.mod. The module is now resolved from the published repository.
* refactor: remove frivolous comments from auth validation/credentialsbndw3 days1-32/+3
| | | | Also removed internal/nostr package - now using northwest.io/nostr library.
* feat: implement NIP-98 HTTP auth for gRPCbndw3 days1-0/+116
Add comprehensive NIP-98 authentication support following the standard gRPC credentials.PerRPCCredentials pattern. Client-side: - NostrCredentials implements PerRPCCredentials interface - Automatically signs each request with kind 27235 event - Drop-in replacement for OAuth2/JWT in gRPC clients Server-side: - Unary and stream interceptors for validation - Extracts and validates NIP-98 events from Authorization headers - Configurable options (timestamp window, whitelists, skip methods) - Adds authenticated pubkey to request context Security features: - Replay protection via timestamp validation - Optional payload hash verification - Signature verification using schnorr - TLS requirement option Includes comprehensive test coverage and detailed README with usage examples and security considerations.