Fix suid and sudo function names

This commit is contained in:
Andrea Cardaci 2022-09-08 21:11:17 +02:00
parent 8795efe357
commit 5071cb555e
2 changed files with 4 additions and 4 deletions

View File

@ -4,6 +4,6 @@ functions:
- code: tmate -c /bin/sh
sudo:
- code: sudo tmate -c /bin/sh
suid-limited:
limited-suid:
- code: ./tmate -c /bin/sh
---

View File

@ -37,10 +37,10 @@ Before sending a pull request of a new binary or function, ensure the following:
1. Verify the function works on at least one type of modern Unix system.
2. Classifying SUID-related functions is tricky because they depend on the default shell (i.e. Debian `/bin/sh` doesn't drop the privileges, other Linux default shells do it) and on how the external command is called (i.e. `exec()` family vs. `system()` calls). Here an helpful check:
- The function is `suid-enabled` if runs external commands on Ubuntu Linux maintaining the SUID privileges.
- The function is `suid-limited` if runs external commands on Debian maintaining the SUID privileges, but it drops them on Ubuntu Linux.
- The function is `suid` if runs external commands on Ubuntu Linux maintaining the SUID privileges.
- The function is `limited-suid` if runs external commands on Debian maintaining the SUID privileges, but it drops them on Ubuntu Linux.
- The function is not `suid-*` flagged if drops the privileges in Debian Linux.
3. Verify `sudo-enabled` function runs external commands under the `sudo` privileged context.
3. Verify `sudo` function runs external commands under the `sudo` privileged context.
Pull requests adding new functions in [`_data/functions.yml`] are allowed and subjected to project maintainers vetting.