CVE-2026-2241
📋 TL;DR
CVE-2026-2241 is an out-of-bounds read vulnerability in the os_strftime function of Janet programming language. This allows local attackers to read memory beyond allocated buffers, potentially exposing sensitive information. Only systems running vulnerable versions of Janet are affected.
💻 Affected Systems
- janet-lang janet
📦 What is this software?
Janet by Janet Lang
⚠️ Risk & Real-World Impact
Worst Case
Information disclosure of sensitive memory contents, potentially including credentials, cryptographic keys, or other application data
Likely Case
Application crash or denial of service due to invalid memory access
If Mitigated
No impact if proper input validation and memory protections are in place
🎯 Exploit Status
Exploit requires local access and manipulation of os_strftime function parameters
🛠️ Fix & Mitigation
✅ Official Fix
Patch Version: Versions after commit 0f285855f0e34f9183956be5f16e045f54626bff
Vendor Advisory: https://github.com/janet-lang/janet/issues/1701
Restart Required: Yes
Instructions:
1. Update Janet to version after commit 0f285855f0e34f9183956be5f16e045f54626bff
2. Recompile any applications using Janet
3. Restart affected services
🔧 Temporary Workarounds
Disable vulnerable function usage
allAvoid using os_strftime function in applications until patched
Memory protection controls
linuxEnable ASLR and other memory protection mechanisms
echo 2 > /proc/sys/kernel/randomize_va_space
🧯 If You Can't Patch
- Isolate systems running vulnerable Janet versions from untrusted users
- Implement strict access controls to limit local user privileges
🔍 How to Verify
Check if Vulnerable:
Check Janet version with 'janet -v' and verify if it's 1.40.1 or earlier
Check Version:
janet -v
Verify Fix Applied:
Verify Janet version is after commit 0f285855f0e34f9183956be5f16e045f54626bff or test os_strftime function with boundary inputs
📡 Detection & Monitoring
Log Indicators:
- Segmentation fault errors in application logs
- Memory access violation messages
Network Indicators:
- No network indicators - local exploit only
SIEM Query:
search 'segmentation fault' OR 'memory violation' in application logs where process contains 'janet'
🔗 References
- https://github.com/janet-lang/janet/
- https://github.com/janet-lang/janet/commit/0f285855f0e34f9183956be5f16e045f54626bff
- https://github.com/janet-lang/janet/issues/1701
- https://github.com/janet-lang/janet/issues/1701#event-4446770461
- https://github.com/oneafter/0123/blob/main/ja3/repro
- https://vuldb.com/?ctiid.344980
- https://vuldb.com/?id.344980
- https://vuldb.com/?submit.753156