Bugzilla – Bug 363
unwanted characters in filename when using include directive
Last modified: 2009-07-29 10:46:35 MDT
I am trying to utilize the include directive within the sudoers configuration file. I am using the syntax: #include /etc/sudoers.%h This appears on a line all by itself and it starts in the first position of the line of the sudoers config file (/usr/local/etc/sudoers) The file that gets generated has the following name (listed with non-printable characters displayed): sol3d# ls -b /etc/sudoers.* /etc/sudoers.sol3d\012 somehow the %h is including a carriage return at the end of the filename. The file is being created this way when using visudo to edit the config files.
Created attachment 262 [details] fix for %h interpolation
I've attached a patch which should fix the issue
Created attachment 263 [details] complete fix for %h interpolation
fixed in sudo 1.7.2p1