LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Security
User Name
Password
Linux - Security This forum is for all security related questions.
Questions, tips, system compromises, firewalls, etc. are all included here.

Notices


Reply
  Search this Thread
Old 10-13-2003, 02:48 PM   #1
guardian653
Member
 
Registered: Oct 2003
Distribution: Gentoo
Posts: 79

Rep: Reputation: 15
Exclamation When rebooting bash appears with ROOT access!?!?


Hey, just got my linux system up at school not too long ago and didn't secure it being as it took forever to install redhat on it (redhat 9 on a pentium 133 12x cdrom)

The question is: I setup a "guest" account for some people in class who want to do some programming stuff on it. it was just a normal user account that didn't belong to anything. The next day I find that some of the settings are changed. I fixed them, but when rebooting to apply the changes... It switches to INIT 6 and the bash prompt appears! I type whoami and it shows ROOT!! The system does not reboot! (It also appears that it switches to single user mode if I remember right0

How did this happen!? And how can I prevent from this happening again!!!
Any links to a HOWTO on how to do what they did (so I can learn from it >_<) would be appericated.

Thanks
 
Old 10-13-2003, 07:35 PM   #2
Capt_Caveman
Senior Member
 
Registered: Mar 2003
Distribution: Fedora
Posts: 3,658

Rep: Reputation: 69
Try looking at your /etc/inittab file. It's likely some wise-arse thought it would be funny to change your default runlevel to 6, thinking that it would be amusing to watch you struggle helplessly as your machine reboots over and over. Fortunately for you, that person also doesn't know how to read the man pages or they would realize that if init detects that it has rebooted 10 times in 2 minutes, then it will stop rebooting and give an error (man init if you want specifics).

So check /etc/inittab and look to see if the line:
id:3:initdefault:

has been editted to:
id:6:initdefault:

All those shenanigans aside, whoever changed that setting had to be root. So you need to be aware that more changes may have been made including new users with a UID of 0, rootkits installed, etc. There are plenty of threads, including the one at the top of the forum on doing forensic analysis of compromised machine.

As far as keeping it from happening again, tell the people in class to get their own machines from now on (see how funny they think that is). If that's not an option, you might want to look at chrooting users into their home directories.

Last edited by Capt_Caveman; 10-13-2003 at 07:36 PM.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Bash script to access all files in a directory shinni Programming 5 04-24-2009 03:46 PM
bash: su - changes directory to /root arpi Linux - Software 2 06-11-2004 08:19 PM
Root Bash Error Appleman1234 Linux - General 2 01-23-2004 06:33 PM
cannot log in as root in bash .? Alt-F4witty Linux - Laptop and Netbook 4 01-05-2004 11:59 AM
Bash promt for root? merkka Linux - Newbie 1 11-14-2003 01:13 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Security

All times are GMT -5. The time now is 05:30 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration