Your RSA-2048 keys break in 2030. Find every one of them before attackers do.
Malicious package

mathepyPyPI

Malicious code in mathepy (PyPI) Remove it immediately and rotate any exposed credentials.

MAL-2026-4755
Immediate action
Remove the package, then rotate any secrets the build/runtime could reach.
pip uninstall mathepy

What this malware does

Package metadata advertises mathepy as a 'Module for Quick Calculations', but the package's importable init.py exposes ~13 top-level functions (ask_llm, pink, america, iran, momo, dropnull, code, sf, abc, liti, bcd, lc, init, koko) whose bodies each construct a Groq client with a hardcoded gsk_* API key and forward the caller-supplied prompt argument to api.groq.com's chat-completions endpoint. For example, src/mathepy/ai_helper.py:4 instantiates Groq(api_key="gsk_m7BJ...") and ask_llm posts the caller's prompt to client.chat.completions.create; analogous code is present in pink.py, america.py, iran.py, momo.py, dropnull.py, code.py, sf.py, abc.py, liti.py, bcd.py, lc.py, koko.py, and init.py, each with a distinct hardcoded gsk_* key. Callers have no way to opt out, the destination is unconfigurable, and the README does not disclose that input is sent to a third-party LLM service. Any developer who imports mathepy and invokes one of these functions silently routes their inputs through the author's Groq account. This is the silent-relay supply-chain shape: a package's advertised API hides a hardcoded outbound destination that exfiltrates caller-supplied data. The hardcoded keys themselves are author-self-harm (anyone can extract and burn the author's Groq quota), but the relay channel they enable is the installer-facing harm.

Malicious versions

14 flagged
1.0.01.2.02.2.02.5.03.5.04.5.05.5.05.6.06.6.06.7.06.8.07.8.07.9.08.0.0

Indicators of compromise (SHA-256)

02b6bdc1d574730d17402a0de0a723bde9a9eae564236b977d64c76669f297d5
f6c753ce19473103600325f51274a7190eee54e48be1e19c828f2af105eca173
febe3de1c0fc94c227cd37d422989e447bbaf1cc519dda7979036661bf58f0e2
10141229d153545990ab1d358689df6c1c927e43195ac5e3c0101caab3179a55
268eeb8db2d704a5b34b2007a25477fdd9f2de3525462f3dd78192aa5d2f95a1
41ae6d35f231dc4e14d7c6d44fd6d4a74b65ef671893d798837d3821da3cf9af
4e6882d2388d4a50651f1522ff880cb1084aaff474f04b1255e6261d0d886df5
518048c89b6bba58b224d7f191fa7c68e9e31d8b6376b82794aed6f53a86e52c
83747496974b4c8d5bc9d26f06416df48689cd4ca4793d2a5df8648279647174
862033605e990d5a982099b7d0cc47621c9df572b2df9a1e20c5a95df787c7f6
8cd074d98a1fad36ae5f2bc78749db55c19d9cdbdae37aa14b0a766b344b775d
a3a09863fd16dad4603c0e3f0e1ea20200dd068faf851e261e8609f067cfd7dc
b27de99c93386ef2a08633856bd7c51215f1de908c4fddbd40fb3797f12f687e
f3e83054932030531e5716a59985c086e357d4aa8ee1760ce890449f66d864f1

Detection & response playbook

Credential / info stealer
  1. Find it

    Scan your lockfiles (package-lock.json, pnpm-lock.yaml, yarn.lock, requirements.txt, poetry.lock, etc.) and build artifacts for mathepy (14 malicious versions). O3 Security's supply-chain scanner checks every dependency against known-malicious package intelligence at install time and in CI, flagging mathepy across your stack and pipelines.

  2. If you installed it — respond

    mathepy is built to steal secrets, so assume every credential the build or runtime could read is compromised. Remove it from your project and lockfile, then rotate ALL exposed secrets — npm/registry tokens, cloud keys, CI/CD secrets, SSH keys, and any .env values — from a known-clean machine. Audit logs for unauthorized use of those credentials.

  3. Did it already run?

    If mathepy was ever installed, its post-install/runtime payload may have already executed. O3's L7 egress monitoring and runtime eBPF sensors detect the credential exfiltration or command-and-control callback after install and block the malicious outbound channel, so you catch and contain the actual compromise — not just the presence of the package.

  4. How O3 protects you

    O3 blocks mathepy before install through its supply-chain scanner, and if it has already run, detects and severs the exfiltration or C2 callback at runtime through L7 egress monitoring and eBPF.

Frequently asked questions

No. mathepy on PyPI has been identified as a malicious package (versions 1.0.0, 1.2.0, 2.2.0, 2.5.0, 3.5.0, 4.5.0, 5.5.0, 5.6.0, and 6 more flagged). It should be removed immediately — do not install or keep it in your dependency tree.

Campaign

IN-MAL-2026-004062IN-MAL-2026-004105IN-MAL-2026-004102IN-MAL-2026-004103IN-MAL-2026-004732IN-MAL-2026-004728IN-MAL-2026-004066IN-MAL-2026-004778IN-MAL-2026-004733IN-MAL-2026-004101IN-MAL-2026-004097IN-MAL-2026-004104IN-MAL-2026-004762IN-MAL-2026-004777

References

Credits

  • Amazon Inspector · finder

Detect & block this

O3 blocks mathepy-class packages before install and in CI — and if it already ran, its runtime egress monitoring catches the credential exfiltration and severs the channel.

mathepy (PyPI) malicious package — MAL-2026-4755 | O3 Security