Skip to content

Commit

Permalink
Add RISC-V checks
Browse files Browse the repository at this point in the history
  • Loading branch information
bcoles committed Dec 27, 2024
1 parent 8a6d919 commit b82f8dc
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions kernel_hardening_checker/checks.py
Original file line number Diff line number Diff line change
Expand Up @@ -63,10 +63,10 @@ def add_kconfig_checks(l: List[ChecklistObjType], arch: str) -> None:
KconfigCheck('self_protection', 'kspp', 'GCC_PLUGIN_STRUCTLEAK_BYREF_ALL', 'y')))]
l += [OR(KconfigCheck('self_protection', 'defconfig', 'CPU_MITIGATIONS', 'y'),
KconfigCheck('self_protection', 'defconfig', 'SPECULATION_MITIGATIONS', 'y'))]
if arch in ('X86_64', 'ARM64', 'X86_32'):
if arch in ('X86_64', 'ARM64', 'X86_32', 'RISCV'):
l += [KconfigCheck('self_protection', 'defconfig', 'RANDOMIZE_BASE', 'y')]
vmap_stack_is_set = KconfigCheck('self_protection', 'defconfig', 'VMAP_STACK', 'y')
if arch in ('X86_64', 'ARM64', 'ARM'):
if arch in ('X86_64', 'ARM64', 'ARM', 'RISCV'):
l += [vmap_stack_is_set]
if arch in ('X86_64', 'X86_32'):
l += [KconfigCheck('self_protection', 'defconfig', 'DEBUG_WX', 'y')]
Expand Down

0 comments on commit b82f8dc

Please sign in to comment.