On Tue, Aug 12, 2008 at 6:15 PM, Robert Millan <[EMAIL PROTECTED]> wrote: > On Tue, Aug 12, 2008 at 05:38:16PM +0800, Bean wrote: >> On Tue, Aug 12, 2008 at 4:52 PM, Robert Millan <[EMAIL PROTECTED]> wrote: >> > Notice there's already an implementation of a lock command: >> > >> > http://www.mail-archive.com/[email protected]/msg05350.html >> > >> > which, I think, even without password it would satisfy most of the users >> > who >> > want lock/password. I recommend you read that thread before venturing into >> > implement it (Okuji didn't like my initial proposal, and I run out of time >> > to find/implement another approach). >> >> Hi, >> >> I notice an issue with that implementation. For example, if >> menu_lock=1, how do you unlock it ? Remember that "Unlock the menu" is >> an menu item as well, so you can't get to it in the first place, >> unless you also specify text of menu somewhere, or use another >> variable, for example: >> >> set menu_lock=1 >> set menu_unlock_menu=Unlock the menu >> >> Besides, we might need to fine tune auth with scripting, like >> protecting only some of the commands. > > My idea was to implement unlock in scripting. So you could do something like: > > menuentry unlock { > echo Password: > read user_pass > if [ $user_pass = foo ] ; then > unset menu_lock > fi > } > > but Okuji had some objections to this (see the thread I pasted)
Hi, I know that, but isn't "unlock" another menu item which would normally be locked by menu_lock ? You can hard coded it to ignore the "unlock" menu, but what if user want to use another name. -- Bean _______________________________________________ Grub-devel mailing list [email protected] http://lists.gnu.org/mailman/listinfo/grub-devel
