承接 sunnysideup/scan-for-bad-npm-packages 相关项目开发

从需求分析到上线部署,全程专人跟进,保证项目质量与交付效率

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

sunnysideup/scan-for-bad-npm-packages

最新稳定版本:1.1.0

Composer 安装命令:

composer require sunnysideup/scan-for-bad-npm-packages

包简介

Scans for Shai Hulud and other bad npm packages. USE AT YOUR OWN RISK!

README 文档

README

this is just a bit of a hack right now, Nothing useful yet. Please use at your own risk!!!!!!!!!!!!!

tl;dr

Scans for possible “shai hulud” attacks using an external source for list of possible attack strings (file or URL) via --list <path|url>.

Scans recursively for package.json (excluding node_modules) and checks:

  • Installed version in node_modules
  • Requested spec in package.json (strips ^/~)
  • Lockfiles in the same project dir: package-lock.json, npm-shrinkwrap.json, yarn.lock (classic & berry), pnpm-lock.yaml

Outputs TSV: STATUS PACKAGE@VERSION PATH.

how to run

check first

run first (CAREFUL!!!!)

# clean npm cache
npm cache clean --force
# remove all existing node_modules folders changed since september
sudo find / -type d -name 'node_modules' \
  -exec bash -c '
    if find "$1" -type f -newermt "2025-09-01" -quit | grep -q .; then
      rm -rf "$1"
      echo "Deleted: $1"
    fi
  ' _ {} \;

scan your computer

# Ensure temp dir exists
mkdir -p /var/www/tmp

cd /var/www/tmp
# Clone repository (remove old copy first)
rm -rf scan-for-bad-npm-packages
git clone https://github.com/sunnysideup/scan-for-bad-npm-packages.git scan-for-bad-npm-packages

sudo bash scan-for-bad-npm-packages/run.sh

Ideally, you would run this on your whole machine.

Also do

Check your github account for any untoward changes.

Also see

统计信息

  • 总下载量: 0
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 0
  • 点击次数: 0
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 0
  • Watchers: 0
  • Forks: 0
  • 开发语言: Shell

其他信息

  • 授权协议: MIT
  • 更新时间: 2025-09-19