Del.icio.us
Digg
Furl
Google
Simpy
Spurl
Y! MyWeb
How to protect the LILO boot loader in Linux with a password
What is this Tip?

Rating: 2.7/5 (7 votes cast)

You can configure LILO to ask for a password before any arguments are added from the LILO boot: prompt by adding a password entry in to the global section of the LILO configuration file. This can prevent casual users from booting into the single mode from the LILO boot: prompt.
How to implement this Tip?

1. From your Linux machine access a terminal window and open /etc/lilo.conf file for edit.

2. Find the image stanza in that file and just below that type in the two lines given below.



password=xyzxyz

restricted



Where xyzxyz is the password of your choice. Save the lilo.conf file.

3. Now at the terminal type in the below given line to make the changes made in lilo.conf file effective

/sbin/lilo -v

4. The lilo.conf is a world readable file – i.e all the users can have a peek at the contents of this file – and since we are storing the LILO password as plain text file we have to make this file readable by the root user only by running the below given command.

chmod 600 /etc/lilo.conf

5. Now your LILO boot: prompt will ask for a password if any user tries to pass any parameter while booting.