mirror of
https://github.com/apache/nuttx.git
synced 2026-08-17 17:43:22 +08:00
Adds a pre-load permission check in exec_internal() to verify the calling task has the required execute (x) bits for the target file. Properly evaluates root (euid == 0), owner, group, and other permissions. This ensures POSIX compliance and cleanly rejects unauthorized files with -EACCES before they reach the ELF loader, preventing unnecessary memory allocation and downstream hardware execution faults. Signed-off-by: Abhishek Mishra <mishra.abhishek2808@gmail.com>