diff options
| author | Mark Johnston <markj@FreeBSD.org> | 2026-09-28 22:00:38 +0000 |
|---|---|---|
| committer | Mark Johnston <markj@FreeBSD.org> | 2026-09-29 01:29:22 +0000 |
| commit | 5799049178b68f546c40555f732eef34428f0890 (patch) | |
| tree | 130f211636fceb827a26d4cb1aafd51e1c0b7333 | |
| parent | a76e986470f86731dd3a5f9eeae1ba28b8b160fb (diff) | |
exec: Remove an unneeded capability mode check
The subsequent namei() call is relative to AT_FDCWD, and such lookups
are always disallowed in capability mode.
No functional change intended.
Reviewed by: emaste
Differential Revision: https://reviews.freebsd.org/D59888
| -rw-r--r-- | sys/kern/imgact_elf.c | 9 |
1 files changed, 0 insertions, 9 deletions
diff --git a/sys/kern/imgact_elf.c b/sys/kern/imgact_elf.c index c2be0a6706f6..2dd12d64b5bb 100644 --- a/sys/kern/imgact_elf.c +++ b/sys/kern/imgact_elf.c @@ -803,15 +803,6 @@ __elfN(load_interp_file)(struct thread *td, const char *file, u_long *addr, u_long base_addr = 0; int error; -#ifdef CAPABILITY_MODE - /* - * XXXJA: This check can go away once we are sufficiently confident - * that the checks in namei() are correct. - */ - if (IN_CAPABILITY_MODE(td)) - return (ECAPMODE); -#endif - tempdata = malloc(sizeof(*tempdata), M_TEMP, M_WAITOK | M_ZERO); nd = &tempdata->nd; attr = &tempdata->attr; |
