added code for token issuance and verification

This commit is contained in:
2025-01-31 04:06:03 +09:00
parent b7992a0bb7
commit 8bee855aa8
8 changed files with 144 additions and 48 deletions

View File

@ -1,6 +1,7 @@
package hodu
import "context"
import "crypto/rsa"
import "crypto/tls"
import "errors"
import "fmt"
@ -49,6 +50,7 @@ type ServerAuthConfig struct {
Realm string
Creds ServerAuthCredMap
TokenTtl time.Duration
TokenRsaKey *rsa.PrivateKey
}
type ServerConfig struct {