Bugzilla – Bug 123
no passwd request if run sudo via script
Last modified: 2004-01-09 05:33:40 MST
i was visudo as root and add lkm380z ALL=/sbin/shutdown it request passwd when i type: $sudo -u root /sbin/shutdown -h now but not request when i run via a script (let call it's ssdown) i create the ssdown as: $touch ssdown $chmod 0700 ssdown $vi ssdown ----> what i type in vi #!/bin/sh sudo -u root /sbin/sudo it's work without passwd, please help, i think it's bug, and i was try with FreeBSD-4.8, hehe, also allow me to shutdown without passwd. i'm newbie (9mths linux, 2weeks freebsd), please forgive me if i submit something wrong. thanks!
sorry! #!/bin/sh sudo -u root /sbin/shutdown -h now sorry for the wrong typing...
hi! i shutdown the pc... restart the pc... now sudo do ask my passwd as what it should, i think it might be some "memory cache"? sorry... false alarm...
Sudo keeps a timestamp of the last time you authenticated and doesn't prompt for a password if you've successfully authenticated within the last N minutes where N is 5 by default. This is configurable via the timestamp_timeout Defaults option in sudoers. See the sudoers man page for details.