
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.
connect-categorizr
Advanced tools
Connect middleware that provides device detection, based on Brett Jankord's Categorizr.
npm install connect-categorizr
useSession
: Store the device type in the session for quicker lookups on subsequent requests. Defaults to true
.var connect = require('connect'),
categorizr = require('connect-categorizr');
var app = connect();
app.use(categorizr());
The middleware will add the following immutable properties to the req
object:
deviceType
: String containing the matched device type (mobile
, tablet
, desktop
or tv
)isMobile
: true
if the device is a phoneisTablet
: true
if the device is a tabletisDesktop
: true
if the device is a desktop browserisTV
: true
if the device is a TVFirst, install the test dependencies
npm install -d
and then run the tests
make test
FAQs
Connect middleware for device detection based on Categorizr
The npm package connect-categorizr receives a total of 87 weekly downloads. As such, connect-categorizr popularity was classified as not popular.
We found that connect-categorizr demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer 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.