Skip to main content

Boteraser | Website and Server Security Solutions

🛡️ MAL-2026-4231 — pylogfmt

⚪ Unknown ✅ No Known Exploit OSV
N/A
CVSS Score
0 Low4 Medium7 High9 Critical10

Description

Malicious code in pylogfmt (PyPI)

Source: amazon-inspector

On import pylogfmt, the package's __init__.py spawns a detached background subprocess (subprocess.Popen([sys.executable, '_check.py'], stdout=DEVNULL, stderr=DEVNULL)) that runs an infinite loop POSTing the package install path to https://pypkg.dev/project/pylogfmt/json every 60 seconds with TLS verification explicitly disabled. The HTTP response body is base64-decoded and dispatched to a worker thread (threading.Thread(target=check, args=(package_list.decode(),))), which is the canonical remote-payload-dispatcher shape — the operator controls returned bytes and the client decodes and feeds them into a handler. The destination domain pypkg.dev is a lookalike of pypi.org/pypa with no relation to the package's declared logging-library purpose. Output suppression (DEVNULL on both streams), undocumented behavior (README advertises only a logging helper), TLS bypass, and lookalike C2 destination together are unambiguous attack signals. Any consumer that imports pylogfmt as a library leaks their install path to attacker infrastructure on a 60-second polling interval and is one server-side change away from arbitrary remote code execution.

Source: kam193

Package silently executes remote code during import.

Category: MALICIOUS - The campaign has clearly malicious intent, like infostealers.

Campaign: 2026-05-lognest

Reasons (based on the campaign):

  • Downloads and executes a remote malicious script.

Affected software

MAL-2026-4231 is recorded against 1 package.

  • pylogfmt

Timeline and source

Published on 22 May 2026 and last revised on 26 May 2026. No public exploit is currently recorded for this entry. Record sourced from OSV.

Indicators of compromise

Domains: pypkg.dev
URLs: https://pypkg.dev/project/logger/json

References

bad-packages.kam193.eu (Web)
pypi.org (Package)

Details

Severity Unknown
CVSS Score N/A
CVSS Vector N/A
CWE N/A
Public Exploit ✅ No
Source OSV
Published 2026-05-22
Updated 2026-08-20
Modified 2026-05-26
Fix URL N/A

Affected Packages

Software From version Fixed in
pylogfmt

Free Vulnerability Check

Is your site affected by MAL-2026-4231?

BotEraser helps you identify potentially vulnerable plugins and themes by checking your installation against MAL-2026-4231 and other known CVE records.

Scan My Site Free →

No credit card required  ·  Results in minutes

ⓘ Data Notice: The information presented above has been compiled from publicly available internet sources. Boteraser aggregates this data solely for informational purposes and does not independently classify, evaluate, or endorse any findings about the vulnerabilities listed. The accuracy and completeness of this information is the sole responsibility of the original publishers. Boteraser and its operators accept no liability for any decisions made based on this data.

Browse related advisories

All advisoriesMalicious packagesMalicious packages 2026