AI Security Review
scanned 3h ago · by lpm-firewall-aiA nonessential install-time lifecycle hook executes npx sort-package-json. Source modules otherwise implement browser style helper functions with no confirmed malicious payload.
Static reason
One or more suspicious static signals were detected.
Trigger
npm install
Impact
Install-time execution and local package.json formatting risk; no evidence of exfiltration, persistence, or destructive behavior.
Mechanism
postinstall lifecycle invokes npx formatter
Rationale
The package has an unnecessary and risky install hook, but direct source inspection found only package-aligned formatting plus benign Lit style helper exports. This supports a warning rather than a publish block.
Evidence
package.jsonsrc/index.jssrc/getComponentSharedStyles.jssrc/setComponentSharedStyles.jssrc/setDocumentStyles.js
Decision evidence
public snapshotAI called this Suspicious at 82.0% confidence as Unknown with medium false-positive risk.
Evidence for warning
- package.json defines postinstall: npm run sort:package
- sort:package runs npx sort-package-json during install
- Install hook can rewrite package.json in the installed package directory
Evidence against
- src/index.js only re-exports style helper modules
- src/getComponentSharedStyles.js and src/setComponentSharedStyles.js only manage Lit CSSResult metadata
- src/setDocumentStyles.js only adopts/appends document styles in browser runtime
- No credential/env harvesting, child_process use, eval, dynamic import, or exfiltration endpoints found in package source
Behavioral surface
Source & flagged code
2 flagged · loading sourcepackage.jsonView file
•scripts.postinstall = npm run sort:package
High
Install Time Lifecycle Scripts
Package defines install-time lifecycle scripts.
package.jsonView on unpkg•scripts.postinstall = npm run sort:package
Medium
Ambiguous Install Lifecycle Script
Install-time lifecycle script is not statically allowlisted and needs review.
package.jsonView on unpkgFindings
1 High1 Medium1 Low
HighInstall Time Lifecycle Scriptspackage.json
MediumAmbiguous Install Lifecycle Scriptpackage.json
LowScripts Present