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/ma314smith/go-wsfed
The wsfed
package provides functionality for:
go get github.com/ma314smith/go-wsfed
config = wsfed.Config{}
// set the metatdata url for the IDP (alternatively set the IDPEndpoint)
config.MetadataURL = "https://idp.example.com/wsfederation/metadata"
// trust the certs in the metadata (alternatively set the TrustedCerts)
config.MetadataCertsAreTrusted = true
// poll the metadata once a week to check for any new certificates.
// the default is 0 seconds, which never refreshes after the initial poll
config.MetadataRefreshIntervalSeconds = 604800
// set your realm
config.Realm = "http://realm.example.com"
// use your config to create a new WSFed object
sso = wsfed.New(&config)
// get the default request parameters (wa, wtrealm, wct) or create your own
rp := sso.GetDefaultRequestParameters()
// pass the RequestParameters to GetRequestURL
url, err := sso.GetRequestURL(rp)
// get the wresult parameter from the IDP POST
wresult := r.PostFormValue("wresult")
// pass the wresult to ParseResponse
claims, err := sso.ParseResponse(wresult)
Contributions are welcome. Just fork the repo and send a pull request.
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.