You're right that a package that depends on literally everything would absolutely have a score of 0 in our system.
48,015 karma · joined September 1, 2009
Stanford visiting lecturer, CS 253 Web Security <https://cs253.stanford.edu> – Principles of web security, attacks and countermeasures, and more...
Open source maintainer – 100+ open source packages on npm, including WebTorrent <https://webtorrent.io>, StandardJS <https://standardjs.com>, BitMidi <https://bitmidi.com>, simple-peer <https://github.com/feross/simple-peer>, and more <https://socket.dev/npm/user/feross>.
You can reach me at {my username}@feross.org, or find out more on my website: https://feross.org/resume
[ my public key: https://keybase.io/feross; my proof: https://keybase.io/feross/sigs/gO6pVIJ1DXdy9Y21yil6nlyk_by5BE_GaaWOOQJ5PvQ ]
You're right that a package that depends on literally everything would absolutely have a score of 0 in our system.
Reminds me of an idea I had a while back: create a VM running Windows XP (without service packs, and crawl the web downloading and executing every .exe file that is found. Wait and see what happens to the machine.
Socket is designed to work without the need to analyze, upload, or share your source code. The only data we collect from your repository are the manifest files (package.json, package-lock.json, yarn.lock, etc.).
We use the dependency snapshot to determine the list of packages used by your repository, perform our open source risk analysis, and produce a report.
More info here: https://docs.socket.dev/docs/faq
We don't currently detect 'implicit dependencies' loaded via CDN URLs, though we'll look into what it would take to support this.
I'll see if we can write up a bit about how it works in a future blog post.
You can see npm provenance in action on this npm package page [2] if you scroll to the very bottom and look under the "Provenance" heading.
This is what Socket AI produces when given @ledgerhq/connect-kit 1.1.7 to analyze:
> The obfuscated code block is highly suspicious and likely contains malicious behavior. The presence of obfuscation and the unclear purpose of the code raise significant red flags.
Feeling very proud of our team right now as this validates that our static analysis + LLM approach works well on novel malicious dependencies. If you're interested, we maintain a listing of malicious packages detected by this system [3].
Small plug: If you’d like real-time protection against attacks like this, you can install Socket for GitHub to automatically scan every PR in your repo. The free plan is incredibly generous. If you do decide to install it, it’s important that you enable the ‘AI Detected Security Risk’ alert type in your Security Policy to activate this protection.
[1]: https://socket.dev
[2]: https://socket.dev/blog/introducing-socket-ai-chatgpt-powere...
https://socket.dev/npm/package/shineouts/files/1.12.16-beta....
https://socket.dev/npm/package/@dynamic-form-components/shin...
https://socket.dev/npm/package/eslint-plugin-shein-soc-raw/f...
https://socket.dev/npm/package/@spgy/eslint-plugin-spgy-fe/f...
If you're curious to see more examples of the kind of malicious stuff that is posted regularly to package registries, we have a live updating list here: https://socket.dev/npm/issue/gptSecurity
[Disclosure: I'm founder of Socket]
If you specialize in making computers do things they’re not supposed to do, please drop us a line.
Socket's mission is to help developers and security teams to ship faster and spend less time on security busywork. Thousands of organizations use Socket to safely discover, audit, and manage their open source code. Our customers – from Figma to Vercel – absolutely love Socket (just read their tweets to see for yourself! [1])
The company was founded by Feross Aboukhadijeh [2], who has worked in open source software for 10+ years writing software that receives more than a billion downloads per month. We have raised $25M in funding [3] from the best angel investors, operators, and security leaders in the industry.
We're a small team (~15) but we're already depended on by top companies like Figma, Vercel, Brave, Replit, Expo, Metamask, a massive telecom in Canada, as well as three massive AI companies that you've definitely heard of ;)
See all job openings here: https://socket.dev/careers
Source code: https://github.com/feross/TheAnnoyingSite.
We use LLMs both for detecting threats as well as explaining the output of traditional static analysis in a way that makes the findings understandable to the average developer.
The idea behind the extension is that it integrates directly into the developer workflow so you don’t have to remember to check a separate website.
The issue is caused by a disparity between a package's manifest and its tarball contents, which npm does not enforce are consistent. And unfortunately, a lot of data – such as the dependencies, install scripts, license, etc. – is duplicated between the package.json in the tarball and the metadata served by registry.npmjs.org. And every tool uses a different source of truth.
Socket (disclosure: my startup), I'm proud to say, has been using the correct manifest file - the package.json inside the tarball - for all security analysis, which aligns with the installation behavior of every major package manager. This means any attempt to exploit this technique would not have evaded Socket’s analysis. We wrote more about manifest confusion here: https://socket.dev/blog/manifest-confusion
Not impressed by the basic factual errors in this article. $487 billion ≠ $487 million. https://variety.com/2023/digital/news/roku-svb-failed-silico...
EDIT: I just noticed another disappointing factual error, bordering on disinformation. They say:
> On October 14, 2022, Sacks tweeted, “The idea that the American government, the American taxpayer, or any American company is obligated to provide support is pre entitlement.” That was before the SVB collapse. On March 10, 2023, Sacks sang a different tune: “Where is Powell? Where is Yellen? Stop the crisis NOW. Announce that all depositors will be safe.”
I'm no Sacks apologist, but they took his first quote completely out-of-context, making it sound like he was saying the US government shouldn't support failing companies, when he was in fact talking about the US supporting Ukraine. See: https://twitter.com/DavidSacks/status/1634357137873969152
Today, I am incredibly excited to announce that Socket now supports Python!
Python is one of the most popular programming languages in the world, with millions of developers using it for everything from data science to web development. However, like all open source software, Python packages are vulnerable to supply chain attacks.
Most "vulnerability scanning" tools merely look up the packages you're using to see if any vulnerabilities have been reported to public CVE databases, an approach that is noisy and riddled with false positives.
Socket takes an entirely new approach. Socket uses "deep package inspection" to peel back the layers of a dependency and characterize its actual behavior. This allows us to detect and block likely supply chain attacks before they strike, mitigating the worst consequences.
With Socket, you don't have to worry about alert fatigue or wasting time sifting through piles of meaningless alerts. By default, Socket only alerts you on the most critical security issues – potential supply chain attacks, known malware, typosquats, and other similarly severe issues.
This means you can focus on what matters most – building great software – while Socket takes care of the security side of things. Let me know if you have questions and I'll be happy to answer them.
We flag anything a package introduces new install scripts, network, etc.
We show alerts in GitHub pull requests, or the CLI, if you add a dependency with a supply chain risk.
Disclosure: worked on WebTorrent and Wormhole.app
Disclosure: I’m the original author of WebTorrent