Versions in this module Expand all Collapse all v0 v0.0.3 Oct 22, 2024 v0.0.2 Oct 22, 2024 v0.0.1 Oct 22, 2024 Changes in this version + const P1DeriveKeyFromCurrent + const P1DeriveKeyFromMaster + const P1DeriveKeyFromParent + const Scheme + var DerivationSignatureHash = sha256.Sum256(common.Hash{}.Bytes()) + var ErrAlreadyOpen = errors.New("smartcard: already open") + var ErrPINNeeded = errors.New("smartcard: pin needed") + var ErrPINUnblockNeeded = errors.New("smartcard: pin unblock needed") + var ErrPairingPasswordNeeded = errors.New("smartcard: pairing password needed") + var ErrPubkeyMismatch = errors.New("smartcard: recovered public key mismatch") + type Hub struct + func NewHub(daemonPath string, scheme string, datadir string) (*Hub, error) + func (hub *Hub) Subscribe(sink chan<- accounts.WalletEvent) event.Subscription + func (hub *Hub) Wallets() []accounts.Wallet + type SecureChannelSession struct + PairingIndex uint8 + PairingKey []byte + func NewSecureChannelSession(card *pcsc.Card, keyData []byte) (*SecureChannelSession, error) + func (s *SecureChannelSession) Open() error + func (s *SecureChannelSession) Pair(pairingPassword []byte) error + func (s *SecureChannelSession) Unpair() error + type Session struct + Channel *SecureChannelSession + Wallet *Wallet + type Wallet struct + Hub *Hub + PublicKey []byte + func NewWallet(hub *Hub, card *pcsc.Card) *Wallet + func (w *Wallet) Accounts() []accounts.Account + func (w *Wallet) Close() error + func (w *Wallet) Contains(account accounts.Account) bool + func (w *Wallet) Derive(path accounts.DerivationPath, pin bool) (accounts.Account, error) + func (w *Wallet) Initialize(seed []byte) error + func (w *Wallet) Open(passphrase string) error + func (w *Wallet) SelfDerive(bases []accounts.DerivationPath, chain ethereum.ChainStateReader) + func (w *Wallet) SignData(account accounts.Account, mimeType string, data []byte) ([]byte, error) + func (w *Wallet) SignDataWithPassphrase(account accounts.Account, passphrase, mimeType string, data []byte) ([]byte, error) + func (w *Wallet) SignText(account accounts.Account, text []byte) ([]byte, error) + func (w *Wallet) SignTextWithPassphrase(account accounts.Account, passphrase string, text []byte) ([]byte, error) + func (w *Wallet) SignTx(account accounts.Account, tx *types.Transaction, chainID *big.Int) (*types.Transaction, error) + func (w *Wallet) SignTxWithPassphrase(account accounts.Account, passphrase string, tx *types.Transaction, ...) (*types.Transaction, error) + func (w *Wallet) Status() (string, error) + func (w *Wallet) URL() accounts.URL + func (w *Wallet) Unpair(pin []byte) error