You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
arm64: Ensure execute-only permissions are not allowed without EPAN
Commit 18107f8 ("arm64: Support execute-only permissions with
Enhanced PAN") re-introduced execute-only permissions when EPAN is
available. When EPAN is not available, arch_filter_pgprot() is supposed
to change a PAGE_EXECONLY permission into PAGE_READONLY_EXEC. However,
if BTI or MTE are present, such check does not detect the execute-only
pgprot in the presence of PTE_GP (BTI) or MT_NORMAL_TAGGED (MTE),
allowing the user to request PROT_EXEC with PROT_BTI or PROT_MTE.
Remove the arch_filter_pgprot() function, change the default VM_EXEC
permissions to PAGE_READONLY_EXEC and update the protection_map[] array
at core_initcall() if EPAN is detected.
Signed-off-by: Catalin Marinas <[email protected]>
Fixes: 18107f8 ("arm64: Support execute-only permissions with Enhanced PAN")
Cc: <[email protected]> # 5.13.x
Acked-by: Will Deacon <[email protected]>
Reviewed-by: Vladimir Murzin <[email protected]>
Tested-by: Vladimir Murzin <[email protected]>
0 commit comments