<br><br><div class="gmail_quote">2009/3/20 David Lutterkort <span dir="ltr"><<a href="mailto:lutter@redhat.com">lutter@redhat.com</a>></span><br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<div class="im">On Fri, 2009-03-20 at 20:06 +0100, Raphaël Pinson wrote:<br>
<br>
<br>
> OK. That would have us parse the contents of each parameter in<br>
> Defaults, though, and in my man sudoers, I can count 31 flags, 1<br>
> integer, 4 integer/boolean, 10 strings, 17 strings/boolean, 3<br>
> lists/boolean.<br>
<br>
</div>I think we only need three differnt lenses to pick Defaults values<br>
apart: flag, simple value, and list.<br>
<br>
The lens would of course have to know what parameters are legal and what<br>
'type' they have, which would make it more sensitive to changes in the<br>
sudoers config file format. But that shouldn't keep us from producing<br>
the most useful tree from the file.<br>
<div class="im"><br>
> That makes quite a bit of work, although it surely add nice<br>
> functionality.<br>
<br>
</div>Yes, I think it would make it much nicer to use, since you can then<br>
query the tree to see if PS1 is exported with a fairly simple path<br>
expression. Or at the very least find all places where PS1 is mentioned<br>
in the config.</blockquote><div><br>Not sure it would always be possible to find PS1 in this case, if env_keep can take wildcards, such as LC_* (like sshd_config does).<br><br> </div><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
> It could also make the lens much slower.<br><div class="im">
<br>
</div>Typechecking will definitely become slower, though that's not that much<br>
of a concern since it doesn't affect normal operation, and affects<br>
mostly test runs.<br>
<br>
I doubt that it will have a noticable effect on parsing the config file.<br>
<font color="#888888"></font></blockquote><div><br><br>Most sudoers files are quite simple, which is quite surprising when you consider that theorically, sudoers are supposed to be written for a whole production.<br><br>
<br><br>Raphaël<br><br><br></div></div><br>