View Single Post
joerg_rw's Avatar
Posts: 2,222 | Thanked: 12,651 times | Joined on Mar 2010 @ SOL 3
#1
start xterm
become root (if you don't know how, then all this doesn't apply to you anyway)
make sure you have proper root password set!
run command:
Code:
sed -e "s/Defaults env_reset/Defaults env_reset\nDefaults targetpw/; \
 s+user ALL = NOPASSWD: /usr/sbin/gainroot+user ALL = PASSWD: \ /usr/sbin/gainroot+" -i  /etc/sudoers.d/01sudo

run update-sudoers, check there's no warnings or errors

if sudo gainroot still doesn't ask for password, it might be cached from previous entering it: sudo -k clears pw cache

Tested for PR1.2 with default rootsh installed, works for me. If you bork everything, a reinstall of rootsh package should get you out of quicksand

THIS IS ABOUT *ROOT* PASSWORD for root account, not about that silly Ubuntu idiocy to ask for user password to do root things

this is an excerpt of http://wiki.maemo.org/User:Joerg_rw/tools

If you feel this is a useful post, consider hitting the 'Thanks' button over ->there
__________________
Maemo Community Council member [2012-10, 2013-05, 2013-11, 2014-06 terms]
Hildon Foundation Council inaugural member.
MCe.V. foundation member

EX Hildon Foundation approved
Maemo Administration Coordinator (stepped down due to bullying 2014-04-05)
aka "techstaff" - the guys who keep your infra running - Devotion to Duty http://xkcd.com/705/

IRC(freenode): DocScrutinizer*
First USB hostmode fanatic, father of H-E-N

Last edited by joerg_rw; 2010-09-13 at 18:49.
 

The Following 8 Users Say Thank You to joerg_rw For This Useful Post: