🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: aus.computers.linux
Article #53920

Re: How does IRC know I'm <root>?

#53920
From: David Conran
Date: Mon, 15 Dec 1997 00:00
50 lines
2094 bytes
Ivan Smith <ivans@bigfoot.com> writes:

>I am running an account with the user "ivan" and GID/UID of 0,0 (root).

>Should I change the IDs to 500,500 or something to prevent this?

>I presume that environment  variables aren't enough and the servers are
>getting my permission status from somewhere?

>It's got me stumped.

Basic Unix Sysadmin 101 :)

Your problems are:

identd, uid's and /etc/passwd

identd is allowing the irc server to figure out who you are.

uid's are only ever numbers, not names.

/etc/passwd is scaned sequentially from the top.

Put these together and ...

Identd (and your irc client) is reporting your UID as 0. Which happens to also
be root's UID. When identd looks up UID 0, it sees 'root' first with UID and
stops there, reports that UID 0 (owner of the irc client process) is 'root'.

Solution(s):

Bad:
 Move 'ivan's entry to be before 'root' in /etc/passwd. Be prepared for things
 to break if you do this, as a lot of software expect UID 0 to be mapped to
 'root' not 'ivan' :)
Good:
 Creat yourself a proper account (as you have guessed) with a non-zero UID
 and preferably not a duplicate one :)
 See Basic Unix Sysadmin 102 (2nd semester :) for why you should not run
 around in the/a 'root' account.

Today's lesson was brought to you by the letters U, I & D and the number Zero.

David ;-)
--
 _--_|\  David Conran, Systems Administrator Voice: +61-7-3365-3254
/      * Department of Mathematics,          Fax:   +61-7-3365-1477
\_.--._/ The University of Queensland, 4072  Email: lucifer@maths.uq.edu.au
      v  "Reach out and grep someone"        Http://xyzzy.com.au:8080/lucifer
Technical Details
Message-ID: <671ups$8kp$1@nargun.cc.uq.edu.au>
Path: arc1-ca.pugleaf.net!unknown!not-for-mail
References: <3493F9A9.5AA8B064@bigfoot.com>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: 102983,f301d78265da2078
X-Google-Attributes: gid102983,public
From: lucifer@maths.uq.edu.au (David Conran)
Subject: Re: How does IRC know I'm <root>?
Date: 1997/12/15
Message-ID: <671ups$8kp$1@nargun.cc.uq.edu.au>
X-Deja-AN: 298212023
References: <3493F9A9.5AA8B064@bigfoot.com>
Organization: University of Queensland
Newsgroups: aus.computers.linux