Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CreateProxyHTTPClient ¶
func ValidateProxyURL ¶
Types ¶
type Contract ¶
type Contract struct {
Address string `json:"address"` // 合约地址
Code string `json:"contract"` // 合约代码
ABI string `json:"abi"` // 合约 ABI(JSON 字符串)
Balance string `json:"balance"` // 余额(以字符串保存以避免精度/类型问题)
IsOpenSource bool `json:"isOpenSource"` // 是否开源 (true/false 对应 1/0)
CreateTime time.Time `json:"createtime"` // 创建时间
CreateBlock uint64 `json:"createblock"` // 创建区块号
TxLast time.Time `json:"txlast"` // 最后一次交互时间
IsDecompiled bool `json:"isdecompiled"` //是否开源
DedCode string `json:"dedcode"` //伪代码
}
Contract 表示待扫描的合约基础信息,包含数据库表字段映射
type ProxyConfig ¶
type ProxyConfig struct {
URL string // 代理URL,例如 http://127.0.0.1:7897
Timeout time.Duration // 超时时间
}
type ProxyManager ¶
type ProxyManager struct {
// contains filtered or unexported fields
}
func NewProxyManager ¶
func NewProxyManager(proxyURL string, timeout time.Duration) (*ProxyManager, error)
func (*ProxyManager) CreateHTTPClient ¶
func (pm *ProxyManager) CreateHTTPClient(timeout time.Duration) *http.Client
func (*ProxyManager) CreateHTTPTransport ¶
func (pm *ProxyManager) CreateHTTPTransport() *http.Transport
func (*ProxyManager) GetProxyURL ¶
func (pm *ProxyManager) GetProxyURL() string
func (*ProxyManager) IsEnabled ¶
func (pm *ProxyManager) IsEnabled() bool
Click to show internal directories.
Click to hide internal directories.