The automatic install hook normally downloads the package's platform binary, but its fallback trusts a registry-provided tarball host and uses a weak substring check before attaching NPM_TOKEN. This is a conditional credential-handling vulnerability, so it warrants a warning rather than a malicious verdict.
Static reason
One or more suspicious static signals were detected.
Trigger
The postinstall hook runs when the package is installed; the risky request occurs if the optional platform binary is missing and NPM_TOKEN is set.
Impact
A crafted metadata URL such as a hostname ending in npmjs.org can receive the Bearer token, exposing the user's npm credential.
Mechanism
The script takes the tarball URL from npm registry metadata and attaches NPM_TOKEN whenever the hostname contains npmjs.org, using a substring check rather than validating the exact registry host.
Evidence
package.jsoninstall.jsbin/droid
Network endpoints2
registry.npmjs.orgHost from the package tarball URL in registry metadata, accepted when its hostname contains npmjs.org