Bug 827

Summary: Allow selection of temporary directory for sudoedit
Product: Sudo Reporter: Chiraag Nataraj <chiraag.nataraj>
Component: SudoAssignee: Todd C. Miller <Todd.Miller>
Status: RESOLVED FIXED    
Severity: enhancement    
Priority: low    
Version: 1.8.21   
Hardware: PC   
OS: Linux   

Description Chiraag Nataraj 2018-03-29 07:52:22 MDT
It would be useful to be able to set the temporary directory used by sudoedit (e.g. through a setting in sudoers). Namely, this came up in the context of sandboxing an application where /var/tmp read/write access was not given by default (a tmpfs was mounted there) and there was no option to change the temporary directory used by sudo to /tmp (where the application _does_ have access).

Sincerely,

Chiraag
Comment 1 Todd C. Miller 2018-04-04 20:27:53 MDT
sudoedit will choose /tmp if /var/tmp is missing but doesn't currently check for writability.  Adding an explicit access check should solve this without needing an extra configuration option.
Comment 2 Todd C. Miller 2018-04-05 08:57:22 MDT
I believe this should be addressed by https://www.sudo.ws/repos/sudo/rev/1e29ade3f4b2
Comment 3 Todd C. Miller 2018-05-01 07:05:25 MDT
sudo 1.8.23 checks for writability of the temp dir, not just existence.