summaryrefslogtreecommitdiff
path: root/Kernel/SanCov.cpp
AgeCommit message (Collapse)Author
2021-12-30Kernel: Add some implied auto qualifiersHendiadyoin1
2021-09-06Kernel/KCOV: Bring closer to typical SerenityOS coding styleAndreas Kling
- Remove a bunch of redundant `this->` - Make class data members private and provide accessors instead
2021-08-23Kernel: Convert Processor::in_irq() to static current_in_irq()Andreas Kling
This closes the race window between Processor::current() and a context switch happening before in_irq().
2021-08-01Kernel: Remove unused header includesBrian Gianforcaro
2021-07-26Kernel: Add option to build with coverage instrumentation and KCOVPatrick Meyer
GCC and Clang allow us to inject a call to a function named __sanitizer_cov_trace_pc on every edge. This function has to be defined by us. By noting down the caller in that function we can trace the code we have encountered during execution. Such information is used by coverage guided fuzzers like AFL and LibFuzzer to determine if a new input resulted in a new code path. This makes fuzzing much more effective. Additionally this adds a basic KCOV implementation. KCOV is an API that allows user space to request the kernel to start collecting coverage information for a given user space thread. Furthermore KCOV then exposes the collected program counters to user space via a BlockDevice which can be mmaped from user space. This work is required to add effective support for fuzzing SerenityOS to the Syzkaller syscall fuzzer. :^) :^)