
Research
/Security News
Weaponizing Discord for Command and Control Across npm, PyPI, and RubyGems.org
Socket researchers uncover how threat actors weaponize Discord across the npm, PyPI, and RubyGems ecosystems to exfiltrate sensitive data.
rsc-diagnostics
Advanced tools
🚨 Everybody hide! Here come the RSC police!
This is a package that helps indentify and diagnose the causes of large RSC payloads in Next.js. The goal is to avoid situations where users inadvertently DoW themselves due to unnecessary bandwidth usage.
When a large RSC payload is sent from the server to the client, it incurs bandwidth usage. This is tricky to detect, especially when you don't have access to the source code. Even when you do, dynamically generated RSC payloads are impossible to predict unless you know exactly what data will be used. Most of the time this comes from an upstream provider and most of the time it
It does not diagnose RSC payloads that are:
The package exports a binary rsc-diagnostics
that can be run as a postbuild script on Vercel or your CI provider. This command takes no options and emits a list of static RSC files with a size larger than the threshold defined in the staticRscPayload
configuration option.
It also exports a React higher order component withRscDiagnostics
that can be used to wrap a client component (specifically, one that acts as a client entry point, i.e has 'use client'
). It is a minimal shell that inspects each prop and outputs its size to the console if it exceeds the threshold set in
future (???):
VERCEL_ENV !== 'preview'
'use client'
directive, list them for the userFAQs
Utilities for diagnosing large RSC payloads
We found that rsc-diagnostics demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 0 open source maintainers collaborating on the project.
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 how threat actors weaponize Discord across the npm, PyPI, and RubyGems ecosystems to exfiltrate sensitive data.
Security News
Socket now integrates with Bun 1.3’s Security Scanner API to block risky packages at install time and enforce your organization’s policies in local dev and CI.
Research
The Socket Threat Research Team is tracking weekly intrusions into the npm registry that follow a repeatable adversarial playbook used by North Korean state-sponsored actors.