Documentation ¶
Index ¶
- Constants
- Variables
- func PermissionedWalletAPI(a lapi.Wallet) lapi.Wallet
- type WalletStruct
- func (s *WalletStruct) WalletDelete(p0 context.Context, p1 address.Address) error
- func (s *WalletStruct) WalletExport(p0 context.Context, p1 address.Address) (*types.KeyInfo, error)
- func (s *WalletStruct) WalletHas(p0 context.Context, p1 address.Address) (bool, error)
- func (s *WalletStruct) WalletImport(p0 context.Context, p1 *types.KeyInfo) (address.Address, error)
- func (s *WalletStruct) WalletList(p0 context.Context) ([]address.Address, error)
- func (s *WalletStruct) WalletNew(p0 context.Context, p1 types.KeyType) (address.Address, error)
- func (s *WalletStruct) WalletSign(p0 context.Context, p1 address.Address, p2 []byte, p3 api.MsgMeta) (*crypto.Signature, error)
Constants ¶
View Source
const ( PermRead auth.Permission = "read" // default PermWrite auth.Permission = "write" PermSign auth.Permission = "sign" // Use wallet keys for signing PermAdmin auth.Permission = "admin" // Manage permissions )
Variables ¶
View Source
var AllPermissions = []auth.Permission{PermRead, PermWrite, PermSign, PermAdmin}
View Source
var DefaultPerms = []auth.Permission{PermRead}
Functions ¶
Types ¶
type WalletStruct ¶
type WalletStruct struct { Internal struct { WalletDelete func(p0 context.Context, p1 address.Address) error `perm:"admin"` WalletExport func(p0 context.Context, p1 address.Address) (*types.KeyInfo, error) `perm:"admin"` WalletHas func(p0 context.Context, p1 address.Address) (bool, error) `perm:"read"` WalletImport func(p0 context.Context, p1 *types.KeyInfo) (address.Address, error) `perm:"write"` WalletList func(p0 context.Context) ([]address.Address, error) `perm:"read"` WalletNew func(p0 context.Context, p1 types.KeyType) (address.Address, error) `perm:"write"` WalletSign func(p0 context.Context, p1 address.Address, p2 []byte, p3 api.MsgMeta) (*crypto.Signature, error) `perm:"sign"` } }
func (*WalletStruct) WalletDelete ¶
func (s *WalletStruct) WalletDelete(p0 context.Context, p1 address.Address) error
func (*WalletStruct) WalletExport ¶
func (*WalletStruct) WalletHas ¶
func (s *WalletStruct) WalletHas(p0 context.Context, p1 address.Address) (bool, error)
func (*WalletStruct) WalletImport ¶
func (*WalletStruct) WalletList ¶
func (s *WalletStruct) WalletList(p0 context.Context) ([]address.Address, error)
Click to show internal directories.
Click to hide internal directories.