Documentation ¶
Overview ¶
Package implements a private key management facility.
This abstracts part of a user's interaction with an account she controls.
Index ¶
- Variables
- type Account
- type Manager
- func (am *Manager) Accounts() ([]Account, error)
- func (am *Manager) AddressByIndex(index int) (addr string, err error)
- func (am *Manager) DeleteAccount(address common.Address, auth string) error
- func (am *Manager) Export(path string, addr common.Address, keyAuth string) error
- func (am *Manager) HasAccount(addr common.Address) bool
- func (am *Manager) Import(path string, keyAuth string) (Account, error)
- func (am *Manager) ImportPreSaleKey(keyJSON []byte, password string) (acc Account, err error)
- func (am *Manager) NewAccount(auth string) (Account, error)
- func (am *Manager) Sign(a Account, toSign []byte) (signature []byte, err error)
- func (am *Manager) TimedUnlock(addr common.Address, keyAuth string, timeout time.Duration) error
- func (am *Manager) Unlock(addr common.Address, keyAuth string) error
- func (am *Manager) Update(addr common.Address, authFrom, authTo string) (err error)
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrLocked = errors.New("account is locked") ErrNoKeys = errors.New("no keys in store") )
Functions ¶
This section is empty.
Types ¶
type Manager ¶
type Manager struct {
// contains filtered or unexported fields
}
func NewManager ¶
func (*Manager) AddressByIndex ¶ added in v0.9.36
func (*Manager) DeleteAccount ¶ added in v0.9.17
func (*Manager) Export ¶ added in v0.9.17
USE WITH CAUTION = this will save an unencrypted private key on disk no cli or js interface
func (*Manager) HasAccount ¶ added in v0.9.17
func (*Manager) ImportPreSaleKey ¶ added in v0.9.17
func (*Manager) NewAccount ¶ added in v0.9.17
func (*Manager) TimedUnlock ¶ added in v0.9.17
Unlock unlocks the account with the given address. The account stays unlocked for the duration of timeout it timeout is 0 the account is unlocked for the entire session
Click to show internal directories.
Click to hide internal directories.