KUBSAN(4) | Device Drivers Manual | KUBSAN(4) |
kubsan
— kernel
undefined behavior sanitizer
option KUBSAN
kubsan
detects undefined behavior at
runtime inside the kernel. Detected undefined behavior is printed to the
system console, including the offending line in the source code.
By default, kubsan
is not enabled but
instead requires the following line to be present in the kernel
configuration:
option KUBSAN
The following undefined behavior is detected:
NULL
as the value for a function argument
annotated with __nonnull__
.__dead
.The kubsan
implementation is derived from
NetBSD and first appeared in
OpenBSD 6.5.
The kubsan
implementation was written by
Anton Lindqvist
<anton@openbsd.org>.
The kubsan
implementation is limited to
architectures using clang(1)
as their default compiler.
May 24, 2019 | OpenBSD-7.0 |