Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type FilClient ¶
type FilClient interface { io.Closer VerifyBidder(bidderSig []byte, bidderID peer.ID, minerAddr string) (bool, error) GetChainHeight() (uint64, error) }
FilClient provides functionalities to verify bidders.
type LotusFilClient ¶
type LotusFilClient struct {
// contains filtered or unexported fields
}
LotusFilClient is a FilClient backed by Lotus.
func New ¶
func New(lotusGatewayURL string, fakeMode bool) (*LotusFilClient, error)
New returns a new LotusFilClient.
func (*LotusFilClient) GetChainHeight ¶
func (fc *LotusFilClient) GetChainHeight() (uint64, error)
GetChainHeight returns the current chain height in epochs.
func (*LotusFilClient) VerifyBidder ¶
func (fc *LotusFilClient) VerifyBidder(bidderSig []byte, bidderID peer.ID, minerAddrStr string) (bool, error)
VerifyBidder ensures that the wallet address authorized the use of bidder peer.ID to make bids. Miner's authorize a bidding peer.ID by signing it with a wallet address private key.
Click to show internal directories.
Click to hide internal directories.