linux/tools/testing/selftests/sgx
Dave Hansen 4896df9d53 selftests/sgx: remove checks for file execute permissions
The SGX selftests can fail for a bunch of non-obvious reasons
like 'noexec' permissions on /dev (which is the default *EVERYWHERE*
it seems).

A new test mistakenly also looked for +x permission on the
/dev/sgx_enclave.  File execute permissions really only apply to
the ability of execve() to work on a file, *NOT* on the ability
for an application to map the file with PROT_EXEC.  SGX needs to
mmap(PROT_EXEC), but doesn't need to execve() the device file.

Remove the check.

Fixes: 4284f7acb7 ("selftests/sgx: Improve error detection and messages")
Reported-by: Tim Gardner <tim.gardner@canonical.com>
Cc: Jarkko Sakkinen <jarkko@kernel.org>
Cc: Reinette Chatre <reinette.chatre@intel.com>
Cc: Dave Hansen <dave.hansen@linux.intel.com>
Cc: Shuah Khan <shuah@kernel.org>
Cc: linux-sgx@vger.kernel.org
Cc: linux-kselftest@vger.kernel.org
Cc: linux-kernel@vger.kernel.org
Tested-by: Reinette Chatre <reinette.chatre@intel.com>
Signed-off-by: Dave Hansen <dave.hansen@linux.intel.com>
Reviewed-by: Jarkko Sakkinen <jarkko@kernel.org>
Signed-off-by: Shuah Khan <skhan@linuxfoundation.org>
2021-06-23 18:38:04 -06:00
..
.gitignore
call.S selftests/sgx: Rename 'eenter' and 'sgx_call_vdso' 2021-06-15 16:21:23 -06:00
defines.h selftests/sgx: Refine the test enclave to have storage 2021-06-15 16:27:23 -06:00
load.c selftests/sgx: remove checks for file execute permissions 2021-06-23 18:38:04 -06:00
main.c selftests/sgx: Refine the test enclave to have storage 2021-06-15 16:27:23 -06:00
main.h selftests/sgx: Rename 'eenter' and 'sgx_call_vdso' 2021-06-15 16:21:23 -06:00
Makefile
sign_key.pem
sign_key.S
sigstruct.c
test_encl_bootstrap.S
test_encl.c selftests/sgx: Refine the test enclave to have storage 2021-06-15 16:27:23 -06:00
test_encl.lds selftests/sgx: Refine the test enclave to have storage 2021-06-15 16:27:23 -06:00