Skip to content

Commit 4fd5f70

Browse files
keesPeter Zijlstra
authored andcommitted
x86/Kconfig: Enable kernel IBT by default
The kernel IBT defense strongly mitigates the common "first step" of ROP attacks, by eliminating arbitrary stack pivots (that appear either at the end of a function or in immediate values), which cannot be reached if indirect calls must be to marked function entry addresses. IBT is also required to be enabled to gain the FineIBT feature when built with Kernel Control Flow Integrity. Additionally, given that this feature is runtime enabled via CPU ID, it clearly should be built in by default; it will only be enabled if the CPU supports it. The build takes 2 seconds longer, which seems a small price to pay for gaining this coverage by default. Suggested-by: Sami Tolvanen <[email protected]> Signed-off-by: Kees Cook <[email protected]> Signed-off-by: Peter Zijlstra (Intel) <[email protected]> Link: https://lkml.kernel.org/r/[email protected]
1 parent b32fd8a commit 4fd5f70

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

arch/x86/Kconfig

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1856,7 +1856,7 @@ config CC_HAS_IBT
18561856

18571857
config X86_KERNEL_IBT
18581858
prompt "Indirect Branch Tracking"
1859-
bool
1859+
def_bool y
18601860
depends on X86_64 && CC_HAS_IBT && HAVE_OBJTOOL
18611861
# https://github.com/llvm/llvm-project/commit/9d7001eba9c4cb311e03cd8cdc231f9e579f2d0f
18621862
depends on !LD_IS_LLD || LLD_VERSION >= 140000

0 commit comments

Comments
 (0)