@or-sdk/library-types-v2@9.0.3
Malicious code in @or-sdk/library-types-v2 (npm)
Analysis
@or-sdk/library-types-v2@9.0.3, a package that otherwise ships only TypeScript type definitions, declares a preinstall hook (node setup.mjs) that downloads the Bun JavaScript runtime from the official oven-sh/bun GitHub release and then executes a bundled 727KB file (math_init.js) with it. math_init.js is a fully obfuscated payload encoded with a custom base-N alphabet decoder; its logic, network destinations, and any data it collects are not readable from the source. A package whose stated purpose is pure type definitions has no legitimate reason to download a runtime and execute an opaque 727KB payload at install time. The payload's behaviour and any C2 endpoints are concealed by the encoding and could not be recovered from static analysis.
- analyzed by
- Leitwacht
- first seen
- Aug 4, 2026, 12:38 PM
- analyzed
- Aug 4, 2026, 02:26 PM
- weekly installs
- 187
Related advisories
- @or-sdk/base@0.44.6
- @or-sdk/sdk-api@0.29.4
- @or-sdk/providers@0.3.8
- @servicetitan/startup-mfe-compat@0.5.3
- @or-sdk/hitl@0.41.2
- @servicetitan/carto-charts-core@0.0.6
- @onereach/step-run-snowflake-query@0.1.3
- @onereach/postcss-scoped-selector@1.2.3
Independently detected by the Leitwacht supply-chain probe. IOCs are defanged. Published CC0. Think this is a mistake? See the dispute policy.