Difference between revisions of "Kernel Self Protection Project"

From Linux Kernel Security Subsystem
Jump to navigation Jump to search
Line 25: Line 25:
For kernel protections already in upstream (or under active development) that have specific documentation:
For kernel protections already in upstream (or under active development) that have specific documentation:


==== [https://github.com/torvalds/linux/blob/master/Documentation/security/self-protection.txt Self-Protection Guidelines] ====
==== [https://www.kernel.org/doc/html/latest/security/self-protection.html Self-Protection Guidelines] ====
==== [[Kernel_Protections/HARDENED_ATOMIC|refcount_t]] ====
==== [[Kernel_Protections/HARDENED_ATOMIC|refcount_t]] ====
: Kernel reference counter overflow protection
: Kernel reference counter overflow protection

Revision as of 05:18, 4 August 2017

Mission Statement

This project starts with the premise that kernel bugs have a very long lifetime, and that the kernel must be designed in ways to protect against these flaws. We must think of security beyond fixing bugs. As a community, we already find and fix individual bugs via static checkers (compiler flags, smatch, coccinelle, coverity) and dynamic checkers (kernel configs, trinity, KASan). Those efforts are important and on-going, but if we want to protect our billion Android phones, our cars, the International Space Station, and everything else running Linux, we must get proactive defensive technologies built into the upstream Linux kernel. We need the kernel to fail safely, instead of just running safely.

These kinds of protections have existed for years in the PaX and grsecurity patches, and in piles of academic papers. For various social, cultural, and technical reasons, they have not made their way into the upstream kernel, and this project seeks to change that. Our focus is on kernel self-protection, rather than kernel-supported userspace protections. The goal is to eliminate classes of bugs and eliminate methods of exploitation.

Principles

A short list of things to keep in mind when designing self-protection features:

  • Patience and an open mind will be needed. We're all trying to make Linux better, so let's stay focused on the results.
  • Upstream development is evolutionary, not revolutionary, which means it can sometimes take time for features to become fully realized.
  • Features will be more than finding bugs, and should be active at run-time to catch previously unknown flaws.
  • Features will not be developer-"opt-in". When a feature is enabled at build time, it should work for all code built into the kernel (which has the side-effect of also covering out-of-tree code, like in vendor forks).

Details

Specific details on the project:

Get Involved

Areas of Work Needed

Recommended Kernel Settings

Documentation

For kernel protections already in upstream (or under active development) that have specific documentation:

Self-Protection Guidelines

refcount_t

Kernel reference counter overflow protection