Research
Security News
Quasar RAT Disguised as an npm Package for Detecting Vulnerabilities in Ethereum Smart Contracts
Socket researchers uncover a malicious npm package posing as a tool for detecting vulnerabilities in Etherium smart contracts.
github.com/marknown/oredis
oredis is a init for redigo with pool
type Config struct {
Network string // TCP
Host string
Port int
Password string
DB int
Timeout int
MaxActive int // 最大连接数,即最多的tcp连接数
MaxIdle int // 最大空闲连接数,即会有这么多个连接提前等待着
MaxIdleTimeout int // 空闲连接超时时间
Wait bool // 如果超过最大连接,是报错,还是等待。true 为等待,false为报错
}
example
config := &Config{
Network : "tcp",
Host : "127.0.0.1",
Port : 6379,
Password : "",
DB : 0,
Timeout : 5,
MaxActive : 100,
MaxIdle : 50,
MaxIdleTimeout: 5,
Wait : true
}
func GetInstance(config Config) redis.Conn {
}
redis := oredis.GetInstance(config)
FAQs
Unknown package
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
Security News
Socket researchers uncover a malicious npm package posing as a tool for detecting vulnerabilities in Etherium smart contracts.
Security News
Research
A supply chain attack on Rspack's npm packages injected cryptomining malware, potentially impacting thousands of developers.
Research
Security News
Socket researchers discovered a malware campaign on npm delivering the Skuld infostealer via typosquatted packages, exposing sensitive data.