Rux is currently in its 0.x initial development phase. Security fixes are provided for the latest 0.1.x release line:
| Version | Supported |
|---|---|
0.1.x |
Yes |
< 0.1.0 |
No |
Please do not report security vulnerabilities through public GitHub Issues, pull requests, or discussions.
Instead, please report suspected security issues privately using GitHub Security Advisories (the Security → Advisories → Report a vulnerability workflow in the repository).
When reporting a vulnerability, please include as much of the following as possible:
- Affected Rux version, host OS, and target triple (
x86_64-windows,x86_64-linux,aarch64-linux,aarch64-macos, orjit) - Minimal
.rssource reproducer or binary/LSP input triggering the issue - Exact CLI invocation (e.g.,
rux run,rux build,rux lsp) and observed behavior - Potential security impact (e.g., arbitrary memory read/write, W^X violation, sandbox/bounds-check bypass, or soundness bug in borrow checking)
- Maintainers aim to acknowledge receipt of private advisories promptly, assess severity and scope, and coordinate a fix before public disclosure.
- Once a patch is available, a security advisory and release note will be published crediting the reporter unless anonymity is requested.
Rux is a native systems compiler with several low-level unsafe boundaries that warrant heightened scrutiny:
- Host W^X In-Memory JIT (
src/emit/jit.rs):- Allocates virtual memory pages (
VirtualAllocon Windows,mmap/mprotecton Unix), writes machine code while non-executable, transitions pages to read-execute (RX) before transferring control, and executes compiled code in-process with the same OS privileges as theruxprocess. - Important:
rux runexecutes untrusted code natively without OS sandboxing. Do not run untrusted.rsprograms withrux rununless wrapped in an external OS sandbox or container.
- Allocates virtual memory pages (
- Read-Only OS
mmapSnapshots (src/core/mmap.rs):.ruxastbinary AST snapshots are validated by header magic (RUXAST01), counts, and offsets before reading. Treating externally modified or concurrently truncated snapshot files as trusted input can cause OSSIGBUS/SEH faults; only map snapshots owned by the current workspace or trusted build cache.
- Lock-Free Slab Arena (
src/core/slab_arena.rs):- Relies on atomic chunk initialization and strict
WritePhase→ReadPhasetransition (seal_for_reading) to preserve memory safety without locks.
- Relies on atomic chunk initialization and strict
- Zero-CRT Generated Binaries (
src/link/runtime.rs,src/emit/{pe,elf,macho}.rs):- Emitted binaries keep
.textstrictly read-execute (RX) and allocate temporary I/O state on the thread stack (rsp/sp). - Read-only byte slices (
&[u8]) enforce unsigned bounds checks (cmp idx, len), rejecting negative and out-of-range indices.
- Emitted binaries keep
- LSP Server (
src/service/lsp.rs):- Designed for local editor stdio transport (
Content-Lengthframed JSON-RPC 2.0) and should not be exposed directly to untrusted network sockets.
- Designed for local editor stdio transport (