sudo-rs
sudo-rs copied to clipboard
`env_keep = KEY=value` preserves env var `KEY`
trafficstars
relevant test
https://github.com/memorysafety/sudo-rs/blob/719fcfe24401e7d71ec029ec799428702ae47a0e/test-framework/sudo-compliance-tests/src/sudoers/env_keep.rs#L344-L360
the observed ogsudo behavior is that the key-value syntax needs double quotes to work, that is env_keep = "KEY=value" triggers the key-value match semantics but env_keep = KEY=value does not. in the above test sudo-rs preserves KEY whereas ogsudo does not.
also see #344
NOTE: also affects env_check