Skip to content
  • Kees Cook's avatar
    usercopy: Allow strict enforcement of whitelists · 2d891fbc
    Kees Cook authored
    
    
    This introduces CONFIG_HARDENED_USERCOPY_FALLBACK to control the
    behavior of hardened usercopy whitelist violations. By default, whitelist
    violations will continue to WARN() so that any bad or missing usercopy
    whitelists can be discovered without being too disruptive.
    
    If this config is disabled at build time or a system is booted with
    "slab_common.usercopy_fallback=0", usercopy whitelists will BUG() instead
    of WARN(). This is useful for admins that want to use usercopy whitelists
    immediately.
    
    Suggested-by: default avatarMatthew Garrett <mjg59@google.com>
    Signed-off-by: default avatarKees Cook <keescook@chromium.org>
    2d891fbc