Malicious code in @hrmony/benefit-essenszuschuss (npm)
Description
On module import, top-level code in this package harvests cloud and container secrets and posts them to a hardcoded attacker-controlled endpoint. It queries the AWS Instance Metadata Service (IMDSv2 token via PUT to /latest/api/token, then /iam/security-credentials/ and identity-credentials/ec2) to retrieve IAM role credentials, serializes the full process.env, and recursively reads /var/run/secrets/ to capture Kubernetes service-account tokens and mounted secret material. The collected data is POSTed as JSON to hrnmn.dd.h4x.tv/
Any computer that has this package installed or running should be considered fully compromised. All secrets and keys stored on that computer should be rotated immediately from a different computer. The package should be removed, but as full control of the computer may have been given to an outside entity, there is no guarantee that removing the package will remove all malicious software resulting from installing it.