Versions in this module Expand all Collapse all v0 v0.2.10 Feb 3, 2020 Changes in this version + const ConnectionRetryInterval + const DefaultMaxOrphanTxSize + const DefaultRequiredServices + const DefaultServices + const DefaultTargetOutbound + const GBTNonceRange + const GBTRegenerateSeconds + const JSONRPCSemverMajor + const JSONRPCSemverMinor + const JSONRPCSemverPatch + const JSONRPCSemverString + const MaxProtocolVersion + const RPCAuthTimeoutSeconds + const Uint256Size + const WebsocketSendBufferSize + var DefaultConnectTimeout = time.Second * 30 + var Dial = func(stateCfg *state.Config) func(addr net.Addr) (net.Conn, error) + var ErrClientQuit = errors.New("client quit") + var ErrRPCNoWallet = &btcjson.RPCError + var ErrRPCUnimplemented = &btcjson.RPCError + var ErrRescanReorg = btcjson.RPCError + var GBTCapabilities = []string + var GBTCoinbaseAux = &btcjson.GetBlockTemplateResultAux + var GBTMutableFields = []string + var GetworkDataLen = ... + var Hash1Len = ... + var HelpDescsEnUS = map[string]string + var Lookup = func(stateCfg *state.Config) func(host string) ([]net.IP, error) + var RPCAskWallet = map[string]struct + var RPCHandlers map[string]CommandHandler + var RPCHandlersBeforeInit = map[string]CommandHandler + var RPCLimited = map[string]struct + var RPCUnimplemented = map[string]struct + var ResultTypes = map[string][]interface + var TimeZeroVal = time.Time + var UserAgentName = "pod" + var UserAgentVersion = fmt.Sprintf("%d.%d.%d", version.AppMajor, version.AppMinor, version.AppPatch) + var WSHandlers map[string]WSCommandHandler + var WSHandlersBeforeInit = map[string]WSCommandHandler + func AddLocalAddress(addrMgr *addrmgr.AddrManager, addr string, services wire.ServiceFlag) error + func AddrStringToNetAddr(config *pod.Config, stateCfg *state.Config, addr string) (net.Addr, error) + func BigToLEUint256(n *big.Int) [Uint256Size]byte + func BlockDetails(block *util.Block, txIndex int) *btcjson.BlockDetails + func BuilderScript(builder *txscript.ScriptBuilder) []byte + func ChainErrToGBTErrString(err error) string + func CheckAddressValidity(addrs []string, params *netparams.Params) error + func CreateMarshalledReply(id, result interface{}, replyErr error) ([]byte, error) + func CreateTxRawResult(chainParams *netparams.Params, mtx *wire.MsgTx, txHash string, ...) (*btcjson.TxRawResult, error) + func CreateVinList(mtx *wire.MsgTx) []btcjson.Vin + func CreateVinListPrevOut(s *Server, mtx *wire.MsgTx, chainParams *netparams.Params, vinExtra bool, ...) ([]btcjson.VinPrevOut, error) + func CreateVoutList(mtx *wire.MsgTx, chainParams *netparams.Params, ...) []btcjson.Vout + func DecodeHexError(gotHex string) *btcjson.RPCError + func DecodeTemplateID(templateID string) (*chainhash.Hash, int64, error) + func DescendantBlock(prevHash *chainhash.Hash, curBlock *util.Block) error + func DeserializeOutpoints(serializedOuts []btcjson.OutPoint) ([]*wire.OutPoint, error) + func DisconnectPeer(peerList map[int32]*NodePeer, compareFunc func(*NodePeer) bool, ...) bool + func DynamicTickDuration(remaining time.Duration) time.Duration + func EncodeTemplateID(prevHash *chainhash.Hash, lastGenerated time.Time) string + func FetchInputTxos(s *Server, tx *wire.MsgTx) (map[wire.OutPoint]wire.TxOut, error) + func FetchMempoolTxnsForAddress(s *Server, addr util.Address, numToSkip, numRequested uint32) ([]*util.Tx, uint32) + func FileExists(name string) bool + func GenCertPair(certFile, keyFile string) error + func GetDifficultyRatio(bits uint32, params *netparams.Params, algo int32) float64 + func GetHasServices(advertised, desired wire.ServiceFlag) bool + func GetIsWhitelisted(statecfg *state.Config, addr net.Addr) bool + func HandleAddNode(s *Server, cmd interface{}, closeChan <-chan struct{}) (interface{}, error) + func HandleAskWallet(s *Server, cmd interface{}, closeChan <-chan struct{}) (interface{}, error) + func HandleCreateRawTransaction(s *Server, cmd interface{}, closeChan <-chan struct{}) (interface{}, error) + func HandleDecodeRawTransaction(s *Server, cmd interface{}, closeChan <-chan struct{}) (interface{}, error) + func HandleDecodeScript(s *Server, cmd interface{}, closeChan <-chan struct{}) (interface{}, error) + func HandleEstimateFee(s *Server, cmd interface{}, closeChan <-chan struct{}) (interface{}, error) + func HandleGenerate(s *Server, cmd interface{}, closeChan <-chan struct{}) (interface{}, error) + func HandleGetAddedNodeInfo(s *Server, cmd interface{}, closeChan <-chan struct{}) (interface{}, error) + func HandleGetBestBlock(s *Server, cmd interface{}, closeChan <-chan struct{}) (interface{}, error) + func HandleGetBestBlockHash(s *Server, cmd interface{}, closeChan <-chan struct{}) (interface{}, error) + func HandleGetBlock(s *Server, cmd interface{}, closeChan <-chan struct{}) (interface{}, error) + func HandleGetBlockChainInfo(s *Server, cmd interface{}, closeChan <-chan struct{}) (interface{}, error) + func HandleGetBlockCount(s *Server, cmd interface{}, closeChan <-chan struct{}) (interface{}, error) + func HandleGetBlockHash(s *Server, cmd interface{}, closeChan <-chan struct{}) (interface{}, error) + func HandleGetBlockHeader(s *Server, cmd interface{}, closeChan <-chan struct{}) (interface{}, error) + func HandleGetBlockTemplate(s *Server, cmd interface{}, closeChan <-chan struct{}) (interface{}, error) + func HandleGetBlockTemplateLongPoll(s *Server, longPollID string, useCoinbaseValue bool, closeChan <-chan struct{}) (interface{}, error) + func HandleGetBlockTemplateProposal(s *Server, request *btcjson.TemplateRequest) (interface{}, error) + func HandleGetBlockTemplateRequest(s *Server, request *btcjson.TemplateRequest, closeChan <-chan struct{}) (interface{}, error) + func HandleGetCFilter(s *Server, cmd interface{}, closeChan <-chan struct{}) (interface{}, error) + func HandleGetCFilterHeader(s *Server, cmd interface{}, closeChan <-chan struct{}) (interface{}, error) + func HandleGetConnectionCount(s *Server, cmd interface{}, closeChan <-chan struct{}) (interface{}, error) + func HandleGetCurrentNet(s *Server, cmd interface{}, closeChan <-chan struct{}) (interface{}, error) + func HandleGetDifficulty(s *Server, cmd interface{}, closeChan <-chan struct{}) (interface{}, error) + func HandleGetGenerate(s *Server, cmd interface{}, closeChan <-chan struct{}) (interface{}, error) + func HandleGetHashesPerSec(s *Server, cmd interface{}, closeChan <-chan struct{}) (interface{}, error) + func HandleGetHeaders(s *Server, cmd interface{}, closeChan <-chan struct{}) (interface{}, error) + func HandleGetInfo(s *Server, cmd interface{}, closeChan <-chan struct{}) (ret interface{}, err error) + func HandleGetMempoolInfo(s *Server, cmd interface{}, closeChan <-chan struct{}) (interface{}, error) + func HandleGetMiningInfo(s *Server, cmd interface{}, closeChan <-chan struct{}) (ret interface{}, err error) + func HandleGetNetTotals(s *Server, cmd interface{}, closeChan <-chan struct{}) (interface{}, error) + func HandleGetNetworkHashPS(s *Server, cmd interface{}, closeChan <-chan struct{}) (interface{}, error) + func HandleGetPeerInfo(s *Server, cmd interface{}, closeChan <-chan struct{}) (interface{}, error) + func HandleGetRawMempool(s *Server, cmd interface{}, closeChan <-chan struct{}) (interface{}, error) + func HandleGetRawTransaction(s *Server, cmd interface{}, closeChan <-chan struct{}) (interface{}, error) + func HandleGetTxOut(s *Server, cmd interface{}, closeChan <-chan struct{}) (interface{}, error) + func HandleGetWork(s *Server, cmd interface{}, closeChan <-chan struct{}) (interface{}, error) + func HandleGetWorkSubmission(s *Server, hexData string) (interface{}, error) + func HandleHelp(s *Server, cmd interface{}, closeChan <-chan struct{}) (interface{}, error) + func HandleLoadTxFilter(wsc *WSClient, icmd interface{}) (interface{}, error) + func HandleNode(s *Server, cmd interface{}, closeChan <-chan struct{}) (interface{}, error) + func HandleNotifyBlocks(wsc *WSClient, icmd interface{}) (interface{}, error) + func HandleNotifyNewTransactions(wsc *WSClient, icmd interface{}) (interface{}, error) + func HandleNotifyReceived(wsc *WSClient, icmd interface{}) (interface{}, error) + func HandleNotifySpent(wsc *WSClient, icmd interface{}) (interface{}, error) + func HandlePing(s *Server, cmd interface{}, closeChan <-chan struct{}) (interface{}, error) + func HandleRescan(wsc *WSClient, icmd interface{}) (interface{}, error) + func HandleRescanBlocks(wsc *WSClient, icmd interface{}) (interface{}, error) + func HandleRestart(s *Server, cmd interface{}, closeChan <-chan struct{}) (interface{}, error) + func HandleSearchRawTransactions(s *Server, cmd interface{}, closeChan <-chan struct{}) (interface{}, error) + func HandleSendRawTransaction(s *Server, cmd interface{}, closeChan <-chan struct{}) (interface{}, error) + func HandleSession(wsc *WSClient, icmd interface{}) (interface{}, error) + func HandleSetGenerate(s *Server, cmd interface{}, closeChan <-chan struct{}) (interface{}, error) + func HandleStop(s *Server, cmd interface{}, closeChan <-chan struct{}) (interface{}, error) + func HandleStopNotifyBlocks(wsc *WSClient, icmd interface{}) (interface{}, error) + func HandleStopNotifyNewTransactions(wsc *WSClient, icmd interface{}) (interface{}, error) + func HandleStopNotifyReceived(wsc *WSClient, icmd interface{}) (interface{}, error) + func HandleStopNotifySpent(wsc *WSClient, icmd interface{}) (interface{}, error) + func HandleSubmitBlock(s *Server, cmd interface{}, closeChan <-chan struct{}) (interface{}, error) + func HandleUnimplemented(s *Server, cmd interface{}, closeChan <-chan struct{}) (interface{}, error) + func HandleUptime(s *Server, cmd interface{}, closeChan <-chan struct{}) (interface{}, error) + func HandleValidateAddress(s *Server, cmd interface{}, closeChan <-chan struct{}) (interface{}, error) + func HandleVerifyChain(s *Server, cmd interface{}, closeChan <-chan struct{}) (interface{}, error) + func HandleVerifyMessage(s *Server, cmd interface{}, closeChan <-chan struct{}) (interface{}, error) + func HandleVersion(s *Server, cmd interface{}, closeChan <-chan struct{}) (interface{}, error) + func HandleWebsocketHelp(wsc *WSClient, icmd interface{}) (interface{}, error) + func InitListeners(config *pod.Config, activeNet *netparams.Params, aMgr *addrmgr.AddrManager, ...) ([]net.Listener, upnp.NAT, error) + func InternalRPCError(errStr, context string) *btcjson.RPCError + func JSONAuthFail(w http.ResponseWriter) + func MergeCheckpoints(defaultCheckpoints, additional []chaincfg.Checkpoint) []chaincfg.Checkpoint + func MessageToHex(msg wire.Message) (string, error) + func NewPeerConfig(sp *NodePeer) *peer.Config + func NewRedeemingTxNotification(txHex string, index int, block *util.Block) ([]byte, error) + func NoTxInfoError(txHash *chainhash.Hash) *btcjson.RPCError + func NormalizeAddress(addr, defaultPort string) string + func ParseListeners(addrs []string) ([]net.Addr, error) + func PeerExists(connMgr ServerConnManager, addr string, nodeID int32) bool + func QueueHandler(in <-chan interface{}, out chan<- interface{}, quit <-chan struct{}) + func RandomUint16Number(max uint16) uint16 + func RecoverFromReorg(chain *blockchain.BlockChain, minBlock, maxBlock int32, ...) ([]chainhash.Hash, error) + func RescanBlock(wsc *WSClient, lookups *RescanKeys, blk *util.Block) + func RescanBlockFilter(filter *WSClientFilter, block *util.Block, params *netparams.Params) []string + func ReverseUint32Array(b []byte) + func SetupRPCListeners(config *pod.Config, urls []string) ([]net.Listener, error) + func SoftForkStatus(state blockchain.ThresholdState) (string, error) + func TxHexString(tx *wire.MsgTx) string + func VerifyChain(s *Server, level, depth int32) error + func WitnessToHex(witness wire.TxWitness) []string + type BroadcastInventoryAdd RelayMsg + type BroadcastInventoryDel *wire.InvVect + type BroadcastMsg struct + ExcludePeers []*NodePeer + Message wire.Message + type CFHeaderKV struct + BlockHash chainhash.Hash + FilterHeader chainhash.Hash + type CheckpointSorter []chaincfg.Checkpoint + func (s CheckpointSorter) Len() int + func (s CheckpointSorter) Less(i, j int) bool + func (s CheckpointSorter) Swap(i, j int) + type CommandHandler func(*Server, interface{}, <-chan struct{}) (interface{}, error) + type ConnManager struct + func (cm *ConnManager) AddRebroadcastInventory(iv *wire.InvVect, data interface{}) + func (cm *ConnManager) BroadcastMessage(msg wire.Message) + func (cm *ConnManager) Connect(addr string, permanent bool) error + func (cm *ConnManager) ConnectedCount() int32 + func (cm *ConnManager) ConnectedPeers() []ServerPeer + func (cm *ConnManager) DisconnectByAddr(addr string) error + func (cm *ConnManager) DisconnectByID(id int32) error + func (cm *ConnManager) NetTotals() (uint64, uint64) + func (cm *ConnManager) PersistentPeers() []ServerPeer + func (cm *ConnManager) RelayTransactions(txns []*mempool.TxDesc) + func (cm *ConnManager) RemoveByAddr(addr string) error + func (cm *ConnManager) RemoveByID(id int32) error + type ConnectNodeMsg struct + Addr string + Permanent bool + Reply chan error + type DisconnectNodeMsg struct + Cmp func(*NodePeer) bool + Reply chan error + type GBTWorkState struct + Algo string + Config *pod.Config + LastGenerated time.Time + LastTxUpdate time.Time + MinTimestamp time.Time + NotifyMap map[chainhash.Hash]map[int64]chan struct{} + StateCfg *state.Config + Template *mining.BlockTemplate + TimeSource blockchain.MedianTimeSource + func NewGbtWorkState(timeSource blockchain.MedianTimeSource, algoName string) *GBTWorkState + func (state *GBTWorkState) BlockTemplateResult(useCoinbaseValue bool, submitOld *bool) (*btcjson.GetBlockTemplateResult, error) + func (state *GBTWorkState) NotifyBlockConnected(blockHash *chainhash.Hash) + func (state *GBTWorkState) NotifyLongPollers(latestHash *chainhash.Hash, lastGenerated time.Time) + func (state *GBTWorkState) NotifyMempoolTx(lastUpdated time.Time) + func (state *GBTWorkState) TemplateUpdateChan(prevHash *chainhash.Hash, lastGenerated int64) chan struct{} + func (state *GBTWorkState) UpdateBlockTemplate(s *Server, useCoinbaseValue bool) error + type GetAddedNodesMsg struct + Reply chan []*NodePeer + type GetConnCountMsg struct + Reply chan int32 + type GetOutboundGroup struct + Key string + Reply chan int + type GetPeersMsg struct + Reply chan []*NodePeer + type HelpCacher struct + func NewHelpCacher() *HelpCacher + func (c *HelpCacher) RPCMethodHelp(method string) (string, error) + func (c *HelpCacher) RPCUsage(includeWebsockets bool) (string, error) + type Node struct + ActiveNet *netparams.Params + AddrIndex *indexers.AddrIndex + AddrManager *addrmgr.AddrManager + Algo string + BanPeers chan *NodePeer + Broadcast chan BroadcastMsg + BytesReceived uint64 + BytesSent uint64 + CFCheckptCaches map[wire.FilterType][]CFHeaderKV + CFCheckptCachesMtx sync.RWMutex + CFIndex *indexers.CFIndex + CPUMiner *cpuminer.CPUMiner + Chain *blockchain.BlockChain + ChainParams *netparams.Params + Config *pod.Config + ConnManager *connmgr.ConnManager + DB database.DB + DonePeers chan *NodePeer + FeeEstimator *mempool.FeeEstimator + GenThreads uint32 + HashCache *txscript.HashCache + ModifyRebroadcastInv chan interface{} + NAT upnp.NAT + NewPeers chan *NodePeer + PeerHeightsUpdate chan UpdatePeerHeightsMsg + Query chan interface{} + Quit chan struct{} + RPCServers []*Server + RelayInv chan RelayMsg + Services wire.ServiceFlag + Shutdown int32 + ShutdownSched int32 + SigCache *txscript.SigCache + Started int32 + StartupTime int64 + StateCfg *state.Config + SyncManager *netsync.SyncManager + TimeSource blockchain.MedianTimeSource + TxIndex *indexers.TxIndex + TxMemPool *mempool.TxPool + WG sync.WaitGroup + func NewNode(config *pod.Config, stateCfg *state.Config, activeNet *netparams.Params, ...) (*Node, error) + func (s *Node) AddBytesReceived(bytesReceived uint64) + func (s *Node) AddBytesSent(bytesSent uint64) + func (s *Node) AddPeer(sp *NodePeer) + func (s *Node) AddRebroadcastInventory(iv *wire.InvVect, data interface{}) + func (s *Node) AnnounceNewTransactions(txns []*mempool.TxDesc) + func (s *Node) BanPeer(sp *NodePeer) + func (s *Node) BroadcastMessage(msg wire.Message, exclPeers ...*NodePeer) + func (s *Node) ConnectedCount() int32 + func (s *Node) HandleAddPeerMsg(state *PeerState, sp *NodePeer) bool + func (s *Node) HandleBanPeerMsg(state *PeerState, sp *NodePeer) + func (s *Node) HandleBroadcastMsg(state *PeerState, bmsg *BroadcastMsg) + func (s *Node) HandleDonePeerMsg(state *PeerState, sp *NodePeer) + func (s *Node) HandleQuery(state *PeerState, querymsg interface{}) + func (s *Node) HandleRelayInvMsg(state *PeerState, msg RelayMsg) + func (s *Node) HandleUpdatePeerHeights(state *PeerState, umsg UpdatePeerHeightsMsg) + func (s *Node) InboundPeerConnected(conn net.Conn) + func (s *Node) NetTotals() (uint64, uint64) + func (s *Node) OutboundGroupCount(key string) int + func (s *Node) OutboundPeerConnected(c *connmgr.ConnReq, conn net.Conn) + func (s *Node) PeerDoneHandler(sp *NodePeer) + func (s *Node) PeerHandler() + func (s *Node) PushBlockMsg(sp *NodePeer, hash *chainhash.Hash, doneChan chan<- struct{}, ...) error + func (s *Node) PushMerkleBlockMsg(sp *NodePeer, hash *chainhash.Hash, doneChan chan<- struct{}, ...) error + func (s *Node) PushTxMsg(sp *NodePeer, hash *chainhash.Hash, doneChan chan<- struct{}, ...) error + func (s *Node) RebroadcastHandler() + func (s *Node) RelayInventory(invVect *wire.InvVect, data interface{}) + func (s *Node) RelayTransactions(txns []*mempool.TxDesc) + func (s *Node) RemoveRebroadcastInventory(iv *wire.InvVect) + func (s *Node) ScheduleShutdown(duration time.Duration) + func (s *Node) Start() + func (s *Node) Stop() error + func (s *Node) TransactionConfirmed(tx *util.Tx) + func (s *Node) UPNPUpdateThread() + func (s *Node) UpdatePeerHeights(latestBlkHash *chainhash.Hash, latestHeight int32, updateSource *peer.Peer) + func (s *Node) WaitForShutdown() + type NodePeer struct + BanScore connmgr.DynamicBanScore + BlockProcessed chan struct{} + ConnReq *connmgr.ConnReq + ContinueHash *chainhash.Hash + DisableRelayTx bool + FeeFilter int64 + Filter *bloom.Filter + IsWhitelisted bool + KnownAddresses map[string]struct{} + Persistent bool + Quit chan struct{} + RelayMtx sync.Mutex + SentAddrs bool + Server *Node + TxProcessed chan struct{} + func NewServerPeer(s *Node, isPersistent bool) *NodePeer + func (sp *NodePeer) AddBanScore(persistent, transient uint32, reason string) + func (sp *NodePeer) AddKnownAddresses(addresses []*wire.NetAddress) + func (sp *NodePeer) EnforceNodeBloomFlag(cmd string) bool + func (sp *NodePeer) GetNewestBlock() (*chainhash.Hash, int32, error) + func (sp *NodePeer) IsAddressKnown(na *wire.NetAddress) bool + func (sp *NodePeer) IsRelayTxDisabled() bool + func (sp *NodePeer) OnAddr(_ *peer.Peer, msg *wire.MsgAddr) + func (sp *NodePeer) OnBlock(_ *peer.Peer, msg *wire.MsgBlock, buf []byte) + func (sp *NodePeer) OnFeeFilter(_ *peer.Peer, msg *wire.MsgFeeFilter) + func (sp *NodePeer) OnFilterAdd(_ *peer.Peer, msg *wire.MsgFilterAdd) + func (sp *NodePeer) OnFilterClear(_ *peer.Peer, msg *wire.MsgFilterClear) + func (sp *NodePeer) OnFilterLoad(_ *peer.Peer, msg *wire.MsgFilterLoad) + func (sp *NodePeer) OnGetAddr(_ *peer.Peer, msg *wire.MsgGetAddr) + func (sp *NodePeer) OnGetBlocks(_ *peer.Peer, msg *wire.MsgGetBlocks) + func (sp *NodePeer) OnGetCFCheckpt(_ *peer.Peer, msg *wire.MsgGetCFCheckpt) + func (sp *NodePeer) OnGetCFHeaders(_ *peer.Peer, msg *wire.MsgGetCFHeaders) + func (sp *NodePeer) OnGetCFilters(_ *peer.Peer, msg *wire.MsgGetCFilters) + func (sp *NodePeer) OnGetData(_ *peer.Peer, msg *wire.MsgGetData) + func (sp *NodePeer) OnGetHeaders(_ *peer.Peer, msg *wire.MsgGetHeaders) + func (sp *NodePeer) OnHeaders(_ *peer.Peer, msg *wire.MsgHeaders) + func (sp *NodePeer) OnInv(_ *peer.Peer, msg *wire.MsgInv) + func (sp *NodePeer) OnMemPool(_ *peer.Peer, msg *wire.MsgMemPool) + func (sp *NodePeer) OnRead(_ *peer.Peer, bytesRead int, msg wire.Message, err error) + func (sp *NodePeer) OnTx(_ *peer.Peer, msg *wire.MsgTx) + func (sp *NodePeer) OnVersion(_ *peer.Peer, msg *wire.MsgVersion) *wire.MsgReject + func (sp *NodePeer) OnWrite(_ *peer.Peer, bytesWritten int, msg wire.Message, err error) + func (sp *NodePeer) PreparePushAddrMsg(addresses []*wire.NetAddress) + func (sp *NodePeer) SetDisableRelayTx(disable bool) + type NotificationBlockConnected util.Block + type NotificationBlockDisconnected util.Block + type NotificationRegisterAddr struct + Addrs []string + WSC *WSClient + type NotificationRegisterBlocks WSClient + type NotificationRegisterClient WSClient + type NotificationRegisterNewMempoolTxs WSClient + type NotificationRegisterSpent struct + OPs []*wire.OutPoint + WSC *WSClient + type NotificationTxAcceptedByMempool struct + IsNew bool + Tx *util.Tx + type NotificationUnregisterAddr struct + Addr string + WSC *WSClient + type NotificationUnregisterBlocks WSClient + type NotificationUnregisterClient WSClient + type NotificationUnregisterNewMempoolTxs WSClient + type NotificationUnregisterSpent struct + OP *wire.OutPoint + WSC *WSClient + type OnionAddr struct + Addr string + func (oa *OnionAddr) Network() string + func (oa *OnionAddr) String() string + type ParsedRPCCmd struct + Cmd interface{} + Err *btcjson.RPCError + ID interface{} + Method string + func ParseCmd(request *btcjson.Request) *ParsedRPCCmd + type Peer NodePeer + func (p *Peer) GetBanScore() uint32 + func (p *Peer) GetFeeFilter() int64 + func (p *Peer) IsTxRelayDisabled() bool + func (p *Peer) ToPeer() *peer.Peer + type PeerState struct + Banned map[string]time.Time + InboundPeers map[int32]*NodePeer + OutboundGroups map[string]int + OutboundPeers map[int32]*NodePeer + PersistentPeers map[int32]*NodePeer + func (ps *PeerState) Count() int + func (ps *PeerState) ForAllOutboundPeers(closure func(sp *NodePeer)) + func (ps *PeerState) ForAllPeers(closure func(sp *NodePeer)) + type RelayMsg struct + Data interface{} + InvVect *wire.InvVect + type RemoveNodeMsg struct + Cmp func(*NodePeer) bool + Reply chan error + type RescanKeys struct + CompressedPubKeys map[[33]byte]struct{} + Fallbacks map[string]struct{} + PubKeyHashes map[[ripemd160.Size]byte]struct{} + ScriptHashes map[[ripemd160.Size]byte]struct{} + UncompressedPubKeys map[[65]byte]struct{} + Unspent map[wire.OutPoint]struct{} + func (r *RescanKeys) UnspentSlice() []*wire.OutPoint + type RetrievedTx struct + BlkHash *chainhash.Hash + Tx *util.Tx + TxBytes []byte + type Semaphore chan struct + func MakeSemaphore(n int) Semaphore + func (s Semaphore) Acquire() + func (s Semaphore) Release() + type Server struct + AuthSHA [sha256.Size]byte + Cfg ServerConfig + Config *pod.Config + GBTWorkState *GBTWorkState + HelpCacher *HelpCacher + LimitAuthSHA [sha256.Size]byte + NtfnMgr *WSNtfnMgr + NumClients int32 + Quit chan int + RequestProcessShutdown chan struct{} + Shutdown int32 + Started int32 + StateCfg *state.Config + StatusLines map[int]string + StatusLock sync.RWMutex + WG sync.WaitGroup + func NewRPCServer(config *ServerConfig, statecfg *state.Config, podcfg *pod.Config) (*Server, error) + func (s *Server) CheckAuth(r *http.Request, require bool) (bool, bool, error) + func (s *Server) DecrementClients() + func (s *Server) HTTPStatusLine(req *http.Request, code int) string + func (s *Server) HandleBlockchainNotification(notification *blockchain.Notification) + func (s *Server) IncrementClients() + func (s *Server) JSONRPCRead(w http.ResponseWriter, r *http.Request, isAdmin bool) + func (s *Server) LimitConnections(w http.ResponseWriter, remoteAddr string) bool + func (s *Server) NotifyNewTransactions(txns []*mempool.TxDesc) + func (s *Server) RequestedProcessShutdown() <-chan struct{} + func (s *Server) StandardCmdResult(cmd *ParsedRPCCmd, closeChan <-chan struct{}) (interface{}, error) + func (s *Server) Start() + func (s *Server) Stop() error + func (s *Server) WebsocketHandler(conn *websocket.Conn, remoteAddr string, authenticated bool, isAdmin bool) + func (s *Server) WriteHTTPResponseHeaders(req *http.Request, headers http.Header, code int, w io.Writer) error + type ServerConfig struct + AddrIndex *indexers.AddrIndex + Algo string + CPUMiner *cpuminer.CPUMiner + CfIndex *indexers.CFIndex + Chain *blockchain.BlockChain + ChainParams *netparams.Params + ConnMgr ServerConnManager + DB database.DB + FeeEstimator *mempool.FeeEstimator + Generator *mining.BlkTmplGenerator + Listeners []net.Listener + StartupTime int64 + SyncMgr ServerSyncManager + TimeSource blockchain.MedianTimeSource + TxIndex *indexers.TxIndex + TxMemPool *mempool.TxPool + type ServerConnManager interface + AddRebroadcastInventory func(iv *wire.InvVect, data interface{}) + BroadcastMessage func(msg wire.Message) + Connect func(addr string, permanent bool) error + ConnectedCount func() int32 + ConnectedPeers func() []ServerPeer + DisconnectByAddr func(addr string) error + DisconnectByID func(id int32) error + NetTotals func() (uint64, uint64) + PersistentPeers func() []ServerPeer + RelayTransactions func(txns []*mempool.TxDesc) + RemoveByAddr func(addr string) error + RemoveByID func(id int32) error + type ServerPeer interface + GetBanScore func() uint32 + GetFeeFilter func() int64 + IsTxRelayDisabled func() bool + ToPeer func() *p.Peer + type ServerSyncManager interface + IsCurrent func() bool + LocateHeaders func(locators []*chainhash.Hash, hashStop *chainhash.Hash) []wire.BlockHeader + Pause func() chan<- struct{} + SubmitBlock func(block *util.Block, flags blockchain.BehaviorFlags) (bool, error) + SyncPeerID func() int32 + type SimpleAddr struct + Addr string + Net string + func (a SimpleAddr) Network() string + func (a SimpleAddr) String() string + type SyncManager struct + func (b *SyncManager) IsCurrent() bool + func (b *SyncManager) LocateHeaders(locators []*chainhash.Hash, hashStop *chainhash.Hash) []wire.BlockHeader + func (b *SyncManager) Pause() chan<- struct{} + func (b *SyncManager) SubmitBlock(block *util.Block, flags blockchain.BehaviorFlags) (bool, error) + func (b *SyncManager) SyncPeerID() int32 + type UpdatePeerHeightsMsg struct + NewHash *chainhash.Hash + NewHeight int32 + OriginPeer *peer.Peer + type WSClient struct + Addr string + AddrRequests map[string]struct{} + Authenticated bool + Conn *websocket.Conn + Disconnected bool + FilterData *WSClientFilter + IsAdmin bool + NtfnChan chan []byte + Quit chan struct{} + SendChan chan WSResponse + Server *Server + ServiceRequestSem Semaphore + SessionID uint64 + SpentRequests map[wire.OutPoint]struct{} + VerboseTxUpdates bool + WG sync.WaitGroup + func NewWebsocketClient(server *Server, conn *websocket.Conn, remoteAddr string, authenticated bool, ...) (*WSClient, error) + func (c *WSClient) Disconnect() + func (c *WSClient) InHandler() + func (c *WSClient) IsDisconnected() bool + func (c *WSClient) NotificationQueueHandler() + func (c *WSClient) OutHandler() + func (c *WSClient) QueueNotification(marshalledJSON []byte) error + func (c *WSClient) SendMessage(marshalledJSON []byte, doneChan chan bool) + func (c *WSClient) ServiceRequest(r *ParsedRPCCmd) + func (c *WSClient) Start() + func (c *WSClient) WaitForShutdown() + type WSClientFilter struct + CompressedPubKeys map[[33]byte]struct{} + OtherAddresses map[string]struct{} + PubKeyHashes map[[ripemd160.Size]byte]struct{} + ScriptHashes map[[ripemd160.Size]byte]struct{} + UncompressedPubKeys map[[65]byte]struct{} + Unspent map[wire.OutPoint]struct{} + func NewWSClientFilter(addresses []string, unspentOutPoints []wire.OutPoint, params *netparams.Params) *WSClientFilter + func (f *WSClientFilter) AddAddress(a util.Address) + func (f *WSClientFilter) AddAddressStr(s string, params *netparams.Params) + func (f *WSClientFilter) AddUnspentOutPoint(op *wire.OutPoint) + func (f *WSClientFilter) ExistsAddress(a util.Address) bool + func (f *WSClientFilter) ExistsUnspentOutPoint(op *wire.OutPoint) bool + type WSCommandHandler func(*WSClient, interface{}) (interface{}, error) + type WSNtfnMgr struct + NotificationMsgs chan interface{} + NumClients chan int + QueueNotification chan interface{} + Quit chan struct{} + Server *Server + WG sync.WaitGroup + func NewWSNotificationManager(server *Server) *WSNtfnMgr + func (*WSNtfnMgr) AddAddrRequests(addrMap map[string]map[chan struct{}]*WSClient, wsc *WSClient, addrs []string) + func (*WSNtfnMgr) NotifyBlockConnected(clients map[chan struct{}]*WSClient, block *util.Block) + func (*WSNtfnMgr) NotifyBlockDisconnected(clients map[chan struct{}]*WSClient, block *util.Block) + func (*WSNtfnMgr) NotifyFilteredBlockDisconnected(clients map[chan struct{}]*WSClient, block *util.Block) + func (*WSNtfnMgr) RemoveAddrRequest(addrs map[string]map[chan struct{}]*WSClient, wsc *WSClient, addr string) + func (*WSNtfnMgr) RemoveSpentRequest(ops map[...]map[chan struct{}]*WSClient, wsc *WSClient, op *wire.OutPoint) + func (m *WSNtfnMgr) AddClient(wsc *WSClient) + func (m *WSNtfnMgr) AddSpentRequests(opMap map[...]map[chan struct{}]*WSClient, wsc *WSClient, ops []*wire.OutPoint) + func (m *WSNtfnMgr) GetNumClients() (n int) + func (m *WSNtfnMgr) GetSubscribedClients(tx *util.Tx, clients map[chan struct{}]*WSClient) map[chan struct{}]struct{} + func (m *WSNtfnMgr) NotificationHandler() + func (m *WSNtfnMgr) NotifyFilteredBlockConnected(clients map[chan struct{}]*WSClient, block *util.Block) + func (m *WSNtfnMgr) NotifyForNewTx(clients map[chan struct{}]*WSClient, tx *util.Tx) + func (m *WSNtfnMgr) NotifyForTx(ops map[wire.OutPoint]map[chan struct{}]*WSClient, ...) + func (m *WSNtfnMgr) NotifyForTxIns(ops map[...]map[chan struct{}]*WSClient, tx *util.Tx, block *util.Block) + func (m *WSNtfnMgr) NotifyForTxOuts(ops map[wire.OutPoint]map[chan struct{}]*WSClient, ...) + func (m *WSNtfnMgr) NotifyRelevantTxAccepted(tx *util.Tx, clients map[chan struct{}]*WSClient) + func (m *WSNtfnMgr) QueueHandler() + func (m *WSNtfnMgr) RegisterBlockUpdates(wsc *WSClient) + func (m *WSNtfnMgr) RegisterNewMempoolTxsUpdates(wsc *WSClient) + func (m *WSNtfnMgr) RegisterSpentRequests(wsc *WSClient, ops []*wire.OutPoint) + func (m *WSNtfnMgr) RegisterTxOutAddressRequests(wsc *WSClient, addrs []string) + func (m *WSNtfnMgr) RemoveClient(wsc *WSClient) + func (m *WSNtfnMgr) SendNotifyBlockConnected(block *util.Block) + func (m *WSNtfnMgr) SendNotifyBlockDisconnected(block *util.Block) + func (m *WSNtfnMgr) SendNotifyMempoolTx(tx *util.Tx, isNew bool) + func (m *WSNtfnMgr) Shutdown() + func (m *WSNtfnMgr) Start() + func (m *WSNtfnMgr) UnregisterBlockUpdates(wsc *WSClient) + func (m *WSNtfnMgr) UnregisterNewMempoolTxsUpdates(wsc *WSClient) + func (m *WSNtfnMgr) UnregisterSpentRequest(wsc *WSClient, op *wire.OutPoint) + func (m *WSNtfnMgr) UnregisterTxOutAddressRequest(wsc *WSClient, addr string) + func (m *WSNtfnMgr) WaitForShutdown() + type WSResponse struct + DoneChan chan bool + Msg []byte