LinuxQuestions.org
Share your knowledge at the LQ Wiki.
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 02-08-2005, 05:54 AM   #1
yesterdays
LQ Newbie
 
Registered: Feb 2005
Posts: 6

Rep: Reputation: 0
Unhappy root not working???


Hello,
I am a newbie. I have two problems one with the root user and one with vnc.
I am using mandrake 10.1

root problem.
I want to login as root. So I logout as me, get a GUI login prompt and type root (all lower case) and the password. It returns with make sure you are typing the user name and password correctly etc...
So I logged back in as me and then tried to run something which required root permissions. It asked me for the password of root and I typed it in exactly the same as before and it worked. I also checked in the user administration to see if "root" was "Root" or "ROOT" but it is not. It's just plain old "root". I changed the password of root to "password" (all lower case) I logged off and tried again but I still get the same problem saying I typed the username or password incorrect.
I was running in secure mode and thought that was the problem but after a reboot and running linux in "linux" mode instead of "linux secure" I still get the same problem. I have checked and double checked that capslock is not on etc..
Any Ideas


VNC problem
I can vnc to my windows machine from my linux machine no problem. but when I try from the windows to linux it get the message "Server closed connection unexpectedly". I have run the vncserver on the linux machine. In windows I am using the ip address (which is correct and I have checked it) with the process number so it looks like this 10.10.10.35:1 what am I doing wrong. I am running the vncserver as myself. should it be as root.
Any Ideas

Cheers Yesterdays

Last edited by yesterdays; 02-08-2005 at 06:02 AM.
 
Old 02-08-2005, 07:52 AM   #2
marghorp
Senior Member
 
Registered: Jan 2004
Location: Slovenia
Distribution: Slackware 10.1, SLAX to the MAX :)
Posts: 1,040

Rep: Reputation: 45
First try su command and see if you can login that way to root from a normal user. Then check the /etc/passwd file to see if root line has anything strange with it.

then try to login as root from the console: press ALT+CTRL+F1 and login.

Post here which of these work for you.
 
Old 02-08-2005, 10:21 AM   #3
yesterdays
LQ Newbie
 
Registered: Feb 2005
Posts: 6

Original Poster
Rep: Reputation: 0
Quote:
First try su command and see if you can login that way to root from a normal user. Then check the /etc/passwd file to see if root line has anything strange with it.
Hi
I tried the su command and that works fine I can access the root folder etc.. I checked the passwd file and it looked fine here is the line "root:x:0:0:root:/root:/bin/bash"
any ideas?
 
Old 02-08-2005, 10:35 AM   #4
Matir
LQ Guru
 
Registered: Nov 2004
Location: San Jose, CA
Distribution: Debian, Arch
Posts: 8,507

Rep: Reputation: 128Reputation: 128
If you can su but not log in, perhaps root login is disabled. Very often root login is disabled on the GUI, and sometimes (rarely) consoles as well. I believe /etc/securetty is the configuration file for this.
 
Old 02-08-2005, 11:46 AM   #5
yesterdays
LQ Newbie
 
Registered: Feb 2005
Posts: 6

Original Poster
Rep: Reputation: 0
That file has nothing in it?
is it the right file?

cheers yesterdays
 
Old 02-08-2005, 12:10 PM   #6
KimVette
Senior Member
 
Registered: Dec 2004
Location: Lee, NH
Distribution: OpenSUSE, CentOS, RHEL
Posts: 1,794

Rep: Reputation: 46
Re: root not working???

Quote:
Originally posted by yesterdays
Hello,
I am a newbie.
Welcome to Linux! You'll find that once you get all of your hardware working (can't in my case, ATI AiW 8500DV and ATI Radeon 7500PCI in Xinerama mode - no TV tuner possible in this configuration) you won't be going back to Windows.

Quote:

"Root" or "ROOT" but it is not. It's just plain old "root". I changed the password of root to "password" (all lower case) I logged off and tried again but I still get the same problem saying I typed the username or password incorrect.
This goes without saying, but I'll say it anyhow: If your computer is connected to the Internet (or any public network) in ANY way, be it dialup, broadband, or T-1, never, never, never, NEVER give root a simple password. I'm a fan of taking multiple words from multiple languages, concatenating them together, and putting punctuation or numerals into the mix - not between the words, but IN the chosen words. I also recommend disabling the 8-character limit on passwords if that "feature" is enabled on your system - security is more important than backwards compatibility in this case.

I believe Matir posted what you're looking for, BTW - you may need to dig a little because some distributions rename or even move otherwise-standard configuration files - I am unfamiliar with Mandrake so I can't tell you where they actually put the real file, but that setting is very likely the cause of your problem.

Last edited by KimVette; 02-08-2005 at 12:12 PM.
 
Old 02-08-2005, 02:27 PM   #7
yesterdays
LQ Newbie
 
Registered: Feb 2005
Posts: 6

Original Poster
Rep: Reputation: 0
KimVette what is the point of your post. It doesn't help at all. I know what to do with passwords etc..
My machine isn't directly on the internet it is running through a PAT configuration. so even if the password is password it would be OK(to a point).
I know you think you were helping but it sounded like you were lecturing about the rights and wrongs about passwords to make yourself sound more important. A little ego trip.:P
What would have been great is if that paragraph you wrote on passwords was instead on helping me solve my problem.:P

Quote:
No regrets
 
Old 02-08-2005, 03:45 PM   #8
KimVette
Senior Member
 
Registered: Dec 2004
Location: Lee, NH
Distribution: OpenSUSE, CentOS, RHEL
Posts: 1,794

Rep: Reputation: 46
Being a rude jackass removes any incentive for people to help you.

Good luck.
 
Old 02-08-2005, 04:06 PM   #9
Matir
LQ Guru
 
Registered: Nov 2004
Location: San Jose, CA
Distribution: Debian, Arch
Posts: 8,507

Rep: Reputation: 128Reputation: 128
Well, despite the flamewar with KimVette, I'm still willing to help newbies. I believe KimVette's point was that you DID mention you were new to linux. Not all "newbies" are well versed in security. I do not believe it was meant as an insult, but rather it was just an attempt to help you. With that, I do believe I have a solution for you.

If /etc/securetty is emtpy, then root cannot log in ANYWHERE. It must contain a line for each console on which you want root to log in on. A default one often contains:
Code:
vc/1
vc/2
vc/3
vc/4
vc/5
vc/6
vc/7
vc/8
vc/9
vc/10
vc/11
vc/12
tty1
tty2
tty3
tty4
tty5
tty6
tty7
tty8
tty9
tty10
tty11
tty12

tts/0
ttyS0
Sorry for the long post, but that's what it is. If your distro has moved the securetty location, you'll need to find it first. man 5 securetty may help.
 
Old 02-09-2005, 05:34 PM   #10
yesterdays
LQ Newbie
 
Registered: Feb 2005
Posts: 6

Original Poster
Rep: Reputation: 0
Smile

Hey thats great thanks Matir,
I haven't done anything yet but I will look at that tomorrow.

and KimVette If I hurt your feelings I'm sorry OK. I deal with a lot of people that say quotes like you said, making out like they wrote the book on linux but instead they have only read up to chapter 3 on "Linux for Dummies". I suppose I get pead off with it.
No offence meant lets be friends
You know what is funny is when people call other people "Jackass" It's about insulting as you poking me in my arm!!
what do all the lines stand for in the /etc/securetty?
thanks for the help
yesterdays
 
Old 02-09-2005, 05:56 PM   #11
HermanTheSheep
LQ Newbie
 
Registered: Dec 2004
Distribution: Slackware 10.1
Posts: 21

Rep: Reputation: 15
its been a while since ive installed mandrake but.. (BTW this might be SuSe im talking about :s)

i had the exact same problem then noticed that when you install it asks for a security user
root will not work, you should use the name you gave as the security user

hope this helps


peace
 
Old 02-09-2005, 06:07 PM   #12
KimVette
Senior Member
 
Registered: Dec 2004
Location: Lee, NH
Distribution: OpenSUSE, CentOS, RHEL
Posts: 1,794

Rep: Reputation: 46
Each line stands for one virtual console. Have you ever hit alt-1, alt-2, alt-3 to switch between the different "virtual screens" (really called "Virtual Consoles) in Linux? By enabling each tty to allow the root user, you are allowing root to log in on that virtual console.

You may consider this feature to be a little complicated since the days of dumb serial terminals (like the VT120, etc.) are in the past, but it's still very much alive in a virtual sense, and in kiosk environments with thin clients. By keeping root restricted such that it must first be explicitly allowed to log in from a terminal (whether real or virtual), it is keeping the box secured.

BTW if you have a modem on your box, and it is connected to the telephone line, and it's configured to automatically answer the line, you want to disable these:

tts/0
ttyS0

BTW If I were trying to insult you I wouldn't have said you were being a jackass, but that you're acting like a dateless pimple-faced 17-year-old - but I didn't say that now, did I? ( I couldn't resist, please don't take offense. I'm only kidding around.)
 
Old 02-10-2005, 04:50 AM   #13
yesterdays
LQ Newbie
 
Registered: Feb 2005
Posts: 6

Original Poster
Rep: Reputation: 0
Hey,
Thanks for all the help. I'm hearing bells ringing I remember something about a security user in the installation. I will try that. I am going to add the lines to /etc/securetty as well and I'll let you know.
I think I will be posting more questions on this site I like the banter!

I like this quote! Now thats an insult!
Quote:
you're acting like a dateless pimple-faced 17-year-old
Ltr Dudes
 
Old 02-10-2005, 07:47 AM   #14
peacebwitchu
Member
 
Registered: Apr 2004
Distribution: Debian
Posts: 185

Rep: Reputation: 30
If you are using gdm to login you can enable root logins in gdm.conf. I believe you would change AllowRoot=false to true. It's been awhile since I wanted root to login through the gui so this could be wrong.
 
Old 02-11-2005, 10:46 AM   #15
ugge
Senior Member
 
Registered: Dec 2000
Location: Gothenburg, SWEDEN
Distribution: OpenSUSE 10.3
Posts: 1,028

Rep: Reputation: 45
Quote:
Originally posted by yesterdays
That file has nothing in it?
is it the right file?

cheers yesterdays
The file tell which terminals that the root are allowed to login from. In your case none.
You can add entries in that file to be able to log in directly as root.
Not allowing root to login directly is advisable, you can still change user, using the su - command.
By doing so an attacker would first have to find a valid username on the system, crack the password for that user and then try to crack the root password.
 
  


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
root password not working for su brenainn Linux - Security 1 10-08-2005 04:40 AM
su command not working for root biswajit_dey Linux - Software 3 07-20-2005 11:46 PM
Root login working but not really... indy1979 Slackware 3 01-08-2005 03:46 PM
dns not working from root pjhaig Linux - Networking 2 10-16-2003 06:45 PM
How to get XScreenSaver working under 'root' dabump Linux - Software 1 08-25-2003 02:48 AM

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

All times are GMT -5. The time now is 11:45 AM.

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