Malicious code in besk (crates.io)
- GHSA-59c6-w34f-h244
Description
The crate ships a user-run binary whose main entry awaits parse::bs() and test::dat(). These routines use dirs::home_dir and WalkDir to enumerate the user's home directory, match wallet/keystore files, compress them with ZipWriter, and transmit them to attacker-controlled destinations: a hardcoded Telegram chat id 7304091279 via the toxtg crate, and the Groq LLM API at api.groq.com/openai/v1 using an in-source gsk_ bearer key. parse.rs and test.rs each embed the live Groq API key and Telegram chat id as const strings. The dependency set additionally stages keystroke capture (rdev 0.5.3, evdev 0.12) and Windows registry access (winreg 0.50 under cfg(windows)), invoked from the same test module. The payload is buried inside ~40-60 KB of nonsense padding functions with randomized identifiers (apply_twice_torvak_78, mix_mirmir_240, Modemir65::Umbfel67, etc.) wrapping the small active block around lines 1230-1540 of parse.rs and test.rs, consistent with deliberate obfuscation to defeat casual review. The package's Russian self-description as a 'cybersecurity learning project' does not match its behavior. --- Credit: [OpenSSF](https://github.com/ossf/malicious-packages) ([source](https://github.com/ossf/malicious-packages/blob/578f7ed6729f819c9e2443c259e30f7e08545d99/osv/malicious/crates.io/besk/MAL-2026-20253.json))
Text from the GitHub Advisory record.
Recommendation
Remove the package and rotate any secret the machine that installed it could reach. There is no version to update to.
Affected
beskcrates.io
No versions listed
Timeline
- Published
Related news
No article from the followed outlets names this vulnerability.