Expand description
Permission checks at some path using access_syscall.
Having permission of reading, writing, executing or deleting a file does not guarantee success in doing so, it is unlikely but IO can fail.
Also be careful with TOCTOU race conditions, when you have outdated file
system information that has changed since the last check.
Modules§
- consts
- Bitflags definitions used in the
access_syscallbitfield.
Functions§
- access_
syscall - Safe wrapper to the
libc::accesssyscall. - is_
creatable - Check if current process has permission to create file.
- is_
executable - Check if current process has permission to execute.
- is_
readable - Check if current process has permission to read.
- is_
removable - Check if current process has permission to remove file.
- is_
writable - Check if current process has permission to write.