IT lexicon › Security › Memory safety

Memory safety

Security På svenska → Updated: 2026-11-15

The property that a program cannot read or write arbitrary memory, regardless of input or timing.

Memory safety prevents buffer overflows, use-after-free, and data races. C and C++ don't enforce it—the burden is on the programmer. Rust guarantees memory safety via compile-time borrow checking without a garbage collector. Runtime-enforced languages like Java, Python, and Go achieve it via bounds checks and managed allocation.

← Back to the lexicon