Documentation ¶
Index ¶
- type Manager
- func (sm *Manager) AuthWithWalletHandleToken(walletHandleToken []byte) (wallet.Wallet, int64, error)
- func (sm *Manager) InitWalletHandle(w wallet.Wallet, pw []byte) ([]byte, error)
- func (sm *Manager) ReleaseWalletHandle(walletHandleToken []byte) error
- func (sm *Manager) RenewWalletHandleToken(walletHandleToken []byte) (wallet.Wallet, int64, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Manager ¶
type Manager struct { Initialized bool Kill context.CancelFunc // contains filtered or unexported fields }
Manager allows users to initialize wallets by knowing their passwords, and stores the initialized wallets in memory where the user can access them by an ephemeral wallet handle token
func MakeManager ¶
MakeManager initializes and returns a *Manager using the kmd global configuration
func (*Manager) AuthWithWalletHandleToken ¶
func (sm *Manager) AuthWithWalletHandleToken(walletHandleToken []byte) (wallet.Wallet, int64, error)
AuthWithWalletHandleToken parses an untrusted walletHandle []byte and returns the Wallet it corresponds to + seconds until expiration if and only if the walletHandle was valid.
func (*Manager) InitWalletHandle ¶
InitWalletHandle attempts to init the wallet using the passed password, generates a wallet handle token, and adds the session to the memory store
func (*Manager) ReleaseWalletHandle ¶
ReleaseWalletHandle deletes the wallet handle if it exists