Research
Security News
Malicious npm Packages Inject SSH Backdoors via Typosquatted Libraries
Socket’s threat research team has detected six malicious npm packages typosquatting popular libraries to insert SSH backdoors.
github.com/rapid7/go-get-proxied
Go code (golang) package which facilitates the retrieval of system proxy configurations.
go get github.com/rapid7/go-get-proxied
go get github.com/rapid7/go-get-proxied
, and use dep ensure
to include it in your packagepackage main
import (
"fmt"
"github.com/rapid7/go-get-proxied/proxy"
)
func main() {
p := proxy.NewProvider("").Get("https", "https://rapid7.com")
if p != nil {
fmt.Printf("Found proxy: %s\n", p)
}
}
> ./go-get-proxied -h
Usage of ./go-get-proxied:
-c string
Optional. Path to configuration file.
-j Optional. If a proxy is found, write it as JSON instead of a URL.
-l Optional. If set, a list of proxy will be returned.
-p string
Optional. The proxy protocol you wish to lookup. Default: https (default "https")
-t string
Optional. Target URL which the proxy will be used for. Default: *
-v Optional. If set, log content will be sent to stderr.
> netsh winhttp set proxy testProxy:8999
Current WinHTTP proxy settings:
Proxy Server(s) : testProxy:8999
Bypass List : (none)
> ./go-get-proxied
//testProxy:8999
> ./go-get-proxied -j
{
"host": "testProxy",
"password": null,
"port": 8999,
"protocol": "",
"src": "WinHTTP:WinHttpDefault",
"username": null
}
> echo '{"https":"http://testProxy:8999"}' > proxy.config
> ./go-get-proxied -c proxy.config
http://testProxy:8999
> ./go-get-proxied -c proxy.config -j
{
"host": "testProxy",
"password": null,
"port": 8999,
"protocol": "http",
"src": "ConfigurationFile",
"username": null
}
The priority of retrieval is the following.
HTTPS_PROXY
, HTTP_PROXY
, FTP_PROXY
, or ALL_PROXY
. NO_PROXY
is respected.WPAD
)PAC
)netsh winhttp
)HTTPS_PROXY
, HTTP_PROXY
, FTP_PROXY
, or ALL_PROXY
. NO_PROXY
is respected.HTTPS_PROXY
, HTTP_PROXY
, FTP_PROXY
, or ALL_PROXY
. NO_PROXY
is respected.scutil
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’s threat research team has detected six malicious npm packages typosquatting popular libraries to insert SSH backdoors.
Security News
MITRE's 2024 CWE Top 25 highlights critical software vulnerabilities like XSS, SQL Injection, and CSRF, reflecting shifts due to a refined ranking methodology.
Security News
In this segment of the Risky Business podcast, Feross Aboukhadijeh and Patrick Gray discuss the challenges of tracking malware discovered in open source softare.