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
we're getting the stat of the file, and check the mode for S_IRUSR bit being set.
from the glibc docs:
S_IREAD
Read permission bit for the owner of the file. On many systems this bit is 0400.
S_IREAD is an obsolete synonym provided for BSD compatibility.
so we only check whether the owner of the file can read the file.
this check returns true, say for a file with mode 0400 and owner root:root, but cannot be read by a non-root user.
The text was updated successfully, but these errors were encountered:
util_file_readable uses
util_entry_readable
(andutil_is_file
, not focussed on here) - that function, util_entry_readable, looks as follows:we're getting the stat of the file, and check the mode for
S_IRUSR
bit being set.from the glibc docs:
so we only check whether the owner of the file can read the file.
this check returns true, say for a file with mode 0400 and owner
root:root
, but cannot be read by a non-root user.The text was updated successfully, but these errors were encountered: