| 1 | # Changelog |
| 2 | |
| 3 | ## [0.2.14] - 2026-06-23 |
| 4 | |
| 5 | ### Added |
| 6 | - Support for `Defaults runcwd` (#1448) |
| 7 | - Experimental support for receiving a sudoers configuration over a socket. |
| 8 | To enable, build with with `--features unstable-remote-sudoers`; this will |
| 9 | allow configuring the `@socket` directive in `/etc/sudoers`. |
| 10 | - Spanish, German and Simplified Chinese translations |
| 11 | |
| 12 | ### Changed |
| 13 | - `su` will allow changing to an account that has no password set, like util-linux |
| 14 | and FreeBSD `su`. Also, minor fixes in `su` documentation (#1516) |
| 15 | - PAM account modules now also run for sudoedit (#1612) |
| 16 | - Reserved keywords are now rejected as alias names (#700) |
| 17 | - Password feedback is more thoroughly cleared from the TTY (#1599) |
| 18 | |
| 19 | ### Fixed |
| 20 | - Groups with many users were not loaded properly (#1572) |
| 21 | - Suspended processes would not always be properly resumed (#1527, #1598) |
| 22 | - `PAM_TTY` was not always properly computed (#1593) |
| 23 | - sudo would refuse to run if `no_new_privs` is set but caller is root (#1581) |
| 24 | - Erroneous parse error if line continuations were used inside the argument list |
| 25 | of a /etc/sudoers rule (#1571) |
| 26 | - `visudo` gave incorrect syntax errors for relative @include paths (#1524) |
| 27 | - Minor parse errors in host-specific Defaults and uid/gids (#1509, #1602) |
| 28 | - Papercuts in the TAB shortcut used to disable pwfeedback (#1504, #1514) |
| 29 | |
| 30 | ## [0.2.13] - 2026-03-10 |
| 31 | |
| 32 | ### Added |
| 33 | - In `pwfeedback` mode, pressing TAB will turn off the visual feedback (#1487) |
| 34 | - To allow specifying partial arguments (such as subcommands) in /etc/sudoers |
| 35 | rules, a standalone `*` as the last argument can now be used to denote "zero |
| 36 | or more following arguments". Attempts to use wildcards in other positions |
| 37 | will now result in an explicit parse error with `visudo`. (#1455) |
| 38 | - A Polish translation of the command line interface |
| 39 | |
| 40 | ### Changed |
| 41 | - `Defaults pwfeedback` is now on by default! (#1300) |
| 42 | - UX improvements in the password prompt: it can be suspended/resumed (#1499), |
| 43 | and backspace supports multibyte characters (#1451) |
| 44 | - sudoedit now also checks ACLs for misconfigurations (#1477) |
| 45 | - Better error message if sudo-rs is being run in a container that has |
| 46 | `no_new_privs` enabled. (#1164) |
| 47 | - IPv4-like hostnames in `/etc/sudoers` are now explicitly rejected (#1466) |
| 48 | - sudo-rs now requires at least Rust 1.85 to compile |
| 49 | |
| 50 | ### Fixed |
| 51 | - When using `-i / --login`, the HOME, SHELL, USER and LOGNAME are now always |
| 52 | set to the target user, even if they are part of the `env_keep` list. (#1335) |
| 53 | - Arguments in `SUDO_EDITOR` were not supported (#1491) |
| 54 | - `sudo --bell` did not work with PAM fingerprint module (#1180) |
| 55 | - Host-specific `Defaults` could result in an erroneous parse error (#1468) |
| 56 | - Command arguments containing non-UTF8 characters were rejected (#1413) |
| 57 | - `lecture` setting is now correctly ignored (#1481) |
| 58 | |
| 59 | ## [0.2.12] - 2026-02-09 |
| 60 | |
| 61 | ### Added |
| 62 | - Support for `-b / --background` to run commands in the background |
| 63 | |
| 64 | ### Changed |
| 65 | - visudo will now complain about unsupported command tags (#1401) |
| 66 | |
| 67 | ### Fixed |
| 68 | - When run in a pipe from ksh with `use_pty` would put the |
| 69 | TTY in an unusable state (#1417, introduced in 0.2.11) |
| 70 | - When run as the last command in a pipe with `use_pty`, sudo-rs would not |
| 71 | grant the executed command access to the TTY (#1263) |
| 72 | - Documentation didn't explicitly mention `-A` (#1431) |
| 73 | |
| 74 | ## [0.2.11] - 2025-12-16 |
| 75 | |
| 76 | ### Added |
| 77 | - Support for `-A / --askpass` to enable using an external askpass program |
| 78 | under control of the `SUDO_ASKPASS` environment variable. |
| 79 | - Functional support for localisation. This can be enabled by building sudo-rs |
| 80 | with the `gettext` feature and installing a `sudo-rs.mo` in the correct |
| 81 | LC_MESSAGES folder. Since we have no translations yet this is off by default. |
| 82 | |
| 83 | ### Changed |
| 84 | - sudo is always built with sudoedit functionality |
| 85 | - sudo no longer sets the archaic `MAIL` environment variable |
| 86 | - timestamps format has been changed to always check for session pid (#1132). |
| 87 | As a consequence, timestamps created by earlier versions of sudo-rs are |
| 88 | invalidated after upgrading to this version. |
| 89 | - The folder containing zoneinfo is detected at runtime; `build.rs` was removed |
| 90 | - The default value of `Defaults editor` has been changed on Linux to remove the |
| 91 | dependence on Debian-specific `/usr/bin/editor`. |
| 92 | |
| 93 | ### Fixed |
| 94 | - `sudo -i` made `root` as owner of the pty instead of the login user (#1333) |
| 95 | - visudo usability improvements (#1388, #1394) |
| 96 | - Mistakes in the man pages (#1338, #1362, #1387) |
| 97 | - Better error message when /etc/sudoers contains regular expressions (#1352) |
| 98 | - Better error message when /etc/sudoers is missing (#1368) |
| 99 | - Redirecting input/output to another TTY was not recognized as redirection; |
| 100 | this fix originated from Todd Miller's sudo (#1380) |
| 101 | |
| 102 | ## [0.2.10] - 2025-11-10 |
| 103 | |
| 104 | ### Changed |
| 105 | - Message shown at password timeout has been made nicer (#1171) |
| 106 | - Interrupting a PAM module that handles its own input such as `fprintd` |
| 107 | will not prevent other authentication modes from being tried. (#1308) |
| 108 | |
| 109 | ### Fixed |
| 110 | - Some formatting mistakes in the man pages (#1285) |
| 111 | - Unhandled exception if user would attempt to execute a folder (#1298) |
| 112 | - `Defaults passwd_tries=0` effectively disabled the limit on password tries |
| 113 | rather than setting the limit to zero (#1313) |
| 114 | - sudoedit ignored supplementary groups when checking writability (#1321) |
| 115 | - A partially typed password would be output to standard input if a timeout |
| 116 | occurred when `Defaults pwfeedback` was not enabled (GHSA-q428-6v73-fc4q). |
| 117 | - Timestamp files did not take into account the setting of the |
| 118 | `Defaults targetpw` and `Defaults rootpw` (GHSA-c978-wq47-pvvw) |
| 119 | - Minor tokenization error in /etc/sudoers processing (#1296) |
| 120 | |
| 121 | ## [0.2.9] - 2025-10-03 |
| 122 | |
| 123 | ### Added |
| 124 | - `SUDO_HOME` variable will now be set to the invoking user's home directory |
| 125 | |
| 126 | ### Changed |
| 127 | - `Defaults noninteractive_auth` now controls whether PAM authentication |
| 128 | modules are allowed to attempt authentication when `sudo --non-interactive` is |
| 129 | being used (new default: off). Previous versions had this as always-on |
| 130 | to allow fully automatic authentication methods to succeed. |
| 131 | |
| 132 | ### Fixed |
| 133 | - Two bugs in managing the PTY connected to the child process that negatively |
| 134 | impacted interactive usability (#1130, #1264) |
| 135 | - `visudo --help` showed command flags that were removed (#1239) |
| 136 | - Format flags in `SUDO_PROMPT` were not expanded (#1252) |
| 137 | - `sudo` would abort with an unhandled exception instead if an attempt was |
| 138 | was made to match a "netgroup", instead of ignoring these (#1262) |
| 139 | - A few tokenizer errors in /etc/sudoers processing (#1273, #1274, #1283) |
| 140 | - Some formatting mistakes in the man pages (#1285) |
| 141 | |
| 142 | ## [0.2.8] - 2025-08-04 |
| 143 | |
| 144 | ### Added |
| 145 | - `sudo -e`, `sudoedit` to safely edit files as another user. |
| 146 | |
| 147 | ### Fixed |
| 148 | - `NOEXEC:` could not be used to prevent all shell escapes on multi-architecture |
| 149 | installations (#1229) |
| 150 | - `sudo --list` would not show `NOEXEC`, `SETENV` and `APPARMOR_PROFILE` (#1228) |
| 151 | - Skip paths not accessible by the target user during command resolution (#1234) |
| 152 | |
| 153 | ## [0.2.7] - 2025-07-01 |
| 154 | |
| 155 | ### Added |
| 156 | - Linux kernels older than 5.9 are now supported. |
| 157 | - Support for `Defaults noexec`/`NOEXEC:` on Linux systems based on seccomp |
| 158 | filtering to prevent shell escapes in wide range of cases. This should also |
| 159 | work on programs not written in C and statically linked executables. |
| 160 | - Support for `passwd_timeout` |
| 161 | - Support for `umask` and `umask_override` |
| 162 | - `--preserve-env=VAR` is now supported to preserve selected environment |
| 163 | variables in a more convenient way |
| 164 | |
| 165 | ### Changed |
| 166 | - sudo-rs now uses CLOEXEC to close open file descriptors in the child process |
| 167 | - Relative paths like `./` in `secure_path`/`PATH` are now ignored. |
| 168 | - `apparmor.so` is dynamically loaded by sudo itself, as-needed |
| 169 | |
| 170 | ### Fixed |
| 171 | - Usernames that start with `_` or have non-western characters were not supported |
| 172 | as a valid username in /etc/sudoers (#1149) |
| 173 | - Other usability improvements in /etc/sudoers (#1117, #1126, #1134, #1157) |
| 174 | |
| 175 | ## [0.2.6] - 2025-05-06 |
| 176 | |
| 177 | ### Added |
| 178 | - Support for `Defaults setenv` |
| 179 | - Support for the `list` pseudocommand to control `sudo -U` |
| 180 | - Support for switching AppArmor profiles though `Defaults apparmor_profile` and |
| 181 | the `APPARMOR_PROFILE` command modifier. To enable this, build sudo-rs with |
| 182 | the apparmor feature enabled. |
| 183 | |
| 184 | ### Changed |
| 185 | - Added a check against PAM modules changing the user during authentication (#1062) |
| 186 | - `list` pseudocommand now controls whether a password is required for `sudo -l -U` |
| 187 | |
| 188 | ### Fixed |
| 189 | - Usernames commonly used by Active Directory were not parsed correctly (#1064) |
| 190 | - Test compilation was broken on 32-bit systems (#1074) |
| 191 | - `pwfeedback` was ignored for `sudo --list` and `sudo --validate` (#1092) |
| 192 | - Compilation with musl instead of glibc on Linux was not possible (#1084) |
| 193 | - `sudo --list` now does more checking before reporting errors or listing the |
| 194 | rights of a user, fixing two security bugs (CVE-2025-46717 and CVE-2025-46718) |
| 195 | |
| 196 | ## [0.2.5] - 2025-04-01 |
| 197 | |
| 198 | ### Added |
| 199 | - `sudo visudo` will protect you from accidentally locking yourself out |
| 200 | - Support for `--prompt` and `SUDO_PROMPT` environment variable |
| 201 | - Support for `Defaults targetpw` |
| 202 | - Support for `VAR=VALUE` matching in `Defaults env_keep/env_check` |
| 203 | - Support for `--bell` |
| 204 | |
| 205 | ### Changed |
| 206 | - Portability: sudo-rs supports FreeBSD! |
| 207 | - `sudo -v` will only ask for a password if the policy requires it |
| 208 | |
| 209 | ### Fixed |
| 210 | - Manual wrongly claimed `timestamp_timeout` supported negative values (#1032) |
| 211 | - `timestamp_timeout` in excess of 292 billion years were not rejected (#1048) |
| 212 | - Usernames in /etc/sudoers can contain special characters by using double |
| 213 | quotes or escaping them (#1045) |
| 214 | |
| 215 | ## [0.2.4] - 2025-02-25 |
| 216 | |
| 217 | ### Added |
| 218 | - Support for `SETENV:` and corresponding `sudo VAR=value command` syntax |
| 219 | - Support for `Defaults rootpw` |
| 220 | - Support for `Defaults pwfeedback` |
| 221 | - Support for host/user/runas/command-specific `Defaults` |
| 222 | |
| 223 | ### Changed |
| 224 | - Portability: sudo-rs now has experimental support for FreeBSD! |
| 225 | - `pam-login` feature now controls if PAM service name 'sudo-i' is used |
| 226 | |
| 227 | ### Fixed |
| 228 | - Bug in syslog writer could cause sudo to hang (#856) |
| 229 | - SHELL was not canonicalized when using `sudo -s` or `sudo -i` (#962) |
| 230 | - RunAs_Spec was not carried over on the same /etc/sudoers line (#974) |
| 231 | - sudo --list did not unfold multiple-level aliases (#978) |
| 232 | - The man page for sudoers was missing (#943) |
| 233 | |
| 234 | ### Other |
| 235 | - sudo-rs copyright changed to Trifecta Tech Foundation |
| 236 | |
| 237 | ## [0.2.3] - 2024-07-11 |
| 238 | |
| 239 | ### Changed |
| 240 | - Portability: sudo-rs now is compatible with s390x-unknown-linux-gnu |
| 241 | - Removed unneeded code & fix hints given by newer Rust version |
| 242 | |
| 243 | ### Fixed |
| 244 | - `visudo` would not properly truncate a `sudoers` file |
| 245 | - high CPU load when child process did not terminate after closure of a terminal |
| 246 | |
| 247 | ## [0.2.2] - 2024-02-02 |
| 248 | |
| 249 | ### Changed |
| 250 | - Several changes to the code to improve type safety |
| 251 | - Improved error message when a PTY cannot be opened |
| 252 | - Improved portability of the PAM bindings |
| 253 | - su: improved parsing of su command line options |
| 254 | - Add path information to parse errors originating from included files |
| 255 | |
| 256 | ### Fixed |
| 257 | - Fixed a panic with large messages written to the syslog |
| 258 | - sudo: respect `--login` regardless of the presence of `--chdir` |
| 259 | |
| 260 | ## [0.2.1] - 2023-09-21 |
| 261 | |
| 262 | ### Changed |
| 263 | - Session records/timestamps are now stored in files with uids instead of |
| 264 | usernames, fixing a security bug (CVE-2023-42456) |
| 265 | - `visudo` will now resolve `EDITOR` via `PATH` |
| 266 | - Input/output errors while writing text to the terminal no longer cause sudo to |
| 267 | exit immediately |
| 268 | - Switched several internal API calls from libc to Rust's std library |
| 269 | - The `%h` escape sequence in sudoers includes directives is not supported in |
| 270 | sudo-rs, this now gives a better diagnostic and no longer tries to include the |
| 271 | file |
| 272 | - Our PAM integration was hardened against allocation failures |
| 273 | - An attempt was made to harden against rowhammer type attacks |
| 274 | - Release builds no longer include debugging symbols |
| 275 | |
| 276 | ### Fixed |
| 277 | - Fixed an invalid parsing when an escaped null byte was present in the sudoers |
| 278 | file |
| 279 | - Replaced informal error message in `visudo` with a proper error message |
| 280 | |
| 281 | |
| 282 | ## [0.2.0] - 2023-08-29 |
| 283 | |
| 284 | ### Added |
| 285 | - `visudo` can set/fix file permissions using the `--perms` CLI flag |
| 286 | - `visudo` can set/fix the file owner using the `--owner` CLI flag |
| 287 | - Read `env_editor` from sudoers file for visudo |
| 288 | - Add basic support for `--list` in sudo |
| 289 | |
| 290 | ### Changed |
| 291 | - `visudo` now uses a random filename for the temporary file you are editing |
| 292 | - `su` now runs with a PTY by default |
| 293 | - Included files with relative paths in the sudoers file are imported relative |
| 294 | from the sudoers file |
| 295 | - `sudo` now checks if ownership and setuid bits have been set correctly on |
| 296 | its binary |
| 297 | - When syslog messages are too large they will be split between multiple |
| 298 | messages to prevent message truncation |
| 299 | - We now accept a wider range of dependencies |
| 300 | - Our MSRV (minimum supported rust version) has been set at 1.70.0 |
| 301 | |
| 302 | ### Fixed |
| 303 | - Set arg0 to the non-resolved filename when running a command, preventing |
| 304 | issues with symlinks when commands rely on link filenames |
| 305 | |
| 306 | ## [0.2.0-dev.20230711] - 2023-07-11 |
| 307 | |
| 308 | ### Added |
| 309 | - Add initial `visudo` implementation |
| 310 | - Add support for `~` in `--chdir` |
| 311 | - Log commands that will be executed in the auth syslog |
| 312 | - Add a manpage for the `sudo` command |
| 313 | |
| 314 | ### Changed |
| 315 | - The SUDO_RS_IS_UNSTABLE environment variable is no longer required |
| 316 | - Sudo-rs will now read `/etc/sudoers-rs` or `/etc/sudoers` if the former is |
| 317 | not available. We no longer read `/etc/sudoers.test` |
| 318 | - Removed signal-hook and signal-hook-registry dependencies |
| 319 | - Improved error handling when `--chdir` is passed but not allowed |
| 320 | - Properly handle `SIGWINCH` when running commands with a PTY |
| 321 | |
| 322 | ### Fixed |
| 323 | - Only call ttyname and isatty on character devices |
| 324 | - Fixed a bug in syslog FFI |
| 325 | |
| 326 | ## [0.2.0-dev.20230703] - 2023-07-03 |
| 327 | |
| 328 | ### Added |
| 329 | - Add `timestamp_timeout` support in sudoers file |
| 330 | - Add ability to disable `use_pty` in the sudoers file |
| 331 | |
| 332 | ### Changed |
| 333 | - Set the TTY name for PAM sessions on a TTY |
| 334 | - Set the requesting user for PAM sessions |
| 335 | - Simplified some error messages when a command could not be executed |
| 336 | - Reveal less about what caused a command not to be executable |
| 337 | - Continued rework of the pty exec |
| 338 | |
| 339 | ### Fixed |
| 340 | - Fixed exit codes for `su` |
| 341 | - Fixed environment filtering for `su` |
| 342 | - Fixed `SHELL` handling for `su` |
| 343 | |
| 344 | ## [0.2.0-dev.20230627] - 2023-06-27 |
| 345 | |
| 346 | ### Added |
| 347 | - Add `passwd_tries` support in sudoers file |
| 348 | - Add developer logs (only enabled with the `dev` feature) |
| 349 | |
| 350 | ### Changed |
| 351 | - Only use a PTY to spawn the process if a TTY is available |
| 352 | - Continued rework of the pty exec |
| 353 | - Aliasing is now implemented similarly to the original sudo |
| 354 | - You can no longer define an `ALL` alias in the sudoers file |
| 355 | - Use canonicalized paths for the executed binaries |
| 356 | - Simplified CLI help to only display supported actions |
| 357 | |
| 358 | [0.2.3]: https://github.com/trifectatechfoundation/sudo-rs/compare/v0.2.2...v0.2.3 |
| 359 | [0.2.2]: https://github.com/trifectatechfoundation/sudo-rs/compare/v0.2.1...v0.2.2 |
| 360 | [0.2.1]: https://github.com/trifectatechfoundation/sudo-rs/compare/v0.2.0...v0.2.1 |
| 361 | [0.2.0]: https://github.com/trifectatechfoundation/sudo-rs/compare/v0.2.0-dev.20230711...v0.2.0 |
| 362 | [0.2.0-dev.20230711]: https://github.com/trifectatechfoundation/sudo-rs/compare/v0.2.0-dev.20230703...v0.2.0-dev.20230711 |
| 363 | [0.2.0-dev.20230703]: https://github.com/trifectatechfoundation/sudo-rs/compare/v0.2.0-dev.20230627...v0.2.0-dev.20230703 |
| 364 | [0.2.0-dev.20230627]: https://github.com/trifectatechfoundation/sudo-rs/compare/v0.1.0-dev.20230620...v0.2.0-dev.20230627 |