jerpelea opened a new pull request, #21259:
URL: https://github.com/apache/nuttx/pull/21259
## Summary
Two defects in chmod():
v9fs_client_chstat() converts st_mode with v9fs_map_open_flags(), which
maps the O_* flags of open(). chmod() on a v9fs file sets a wrong mode: 755
gives 701, 644 gives 600 and 777 gives 700. The first commit sends the
permission bits of st_mode.
chmod(), lchmod() and fchmod() mask the mode with 0777, so a program
cannot set S_ISUID, S_ISGID or S_ISVTX, although exec() of a binary with
S_ISUID sets the effective user ID. The second commit masks the mode with 07777.
## Impact
RELEASE
## Testing
CI
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]