Skip to content

Instantly share code, notes, and snippets.

@tuannvm
Created March 31, 2026 13:12
Show Gist options
  • Select an option

  • Save tuannvm/fe9214691b5cc88996c3f560eea31c70 to your computer and use it in GitHub Desktop.

Select an option

Save tuannvm/fe9214691b5cc88996c3f560eea31c70 to your computer and use it in GitHub Desktop.
Axios npm compromise scanner - checks for malicious versions 1.14.1 and 0.30.4, plain-crypto-js trojan, and C2 callbacks
#!/bin/bash
echo "=== Axios Compromise Scanner ==="
echo "Malicious versions: 1.14.1, 0.30.4"
echo "Checking..."
echo
find ~ -path "*/node_modules/axios/package.json" -type f 2>/dev/null | while read p; do
v=$(jq -r .version "$p" 2>/dev/null || grep -oP '"version":\s*"\K[^"]+' "$p" | head -1)
case "$v" in
1.14.1|0.30.4) echo "🚨 MALICIOUS: $(dirname $p) β†’ $v" ;;
*) echo "βœ“ Safe: $(dirname $p) β†’ $v" ;;
esac
done
echo
if find ~ -path "*/node_modules/plain-crypto-js" -type d 2>/dev/null | head -1 | grep -q .; then
echo "🚨 TROJAN FOUND: plain-crypto-js present"
else
echo "βœ“ No trojan package"
fi
echo
if find ~ -path "*/node_modules/axios/*" -name "*.js" -exec grep -l "sfrclak\.com" {} \; 2>/dev/null | head -1 | grep -q .; then
echo "🚨 C2 CALLBACK FOUND"
else
echo "βœ“ No C2 callbacks"
fi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment