Bug 5314 - /usr/libexec/pt_chown should be suid root
/usr/libexec/pt_chown should be suid root
Status: CLOSED NOTABUG
Product: Red Hat Linux
Classification: Retired
Component: glibc (Show other bugs)
6.1
i386 Linux
high Severity high
: ---
: ---
Assigned To: Cristian Gafton
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 1999-09-22 17:38 EDT by Hans de Goede
Modified: 2008-05-01 11:37 EDT (History)
0 users

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 1999-10-01 18:34:18 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Hans de Goede 1999-09-22 17:38:06 EDT
/usr/libexec/pt_chown should be suid root and it isn't,
this causes mc's subshell and gnome-terminal to fail when
run by non root.

Probably also causes other problems.

This is with the latest glibc from the snapshots dir:
glibc-2.1.2-11
Comment 1 Bill Nottingham 1999-10-01 12:46:59 EDT
Can't reproduce this here; glibc-2.1.2-11, latest gnome-core
& mc.
Comment 2 Hans de Goede 1999-10-01 12:56:59 EDT
Hmm, could you do a "ls -l /usr/libexec/pt_chown" and check if it is
suid root? It should be, but in the rpm it isn't.
Did you test this as an ordinary user? As root it works fine.

If it is suid root, could you also do "rpm --verify glibc" ?
I made it suid root myself and rpm --verify glibc complains that the
mode is not ok.

"rpm -ql --dump glibc|grep pt_chown" gives:
/usr/libexec/pt_chown 34643 937818817 3f730db73c6f4ff5d4f20b37a7fe7976
0100755 root root 0 0 19171 X

Which should be:
/usr/libexec/pt_chown 34643 937818817 3f730db73c6f4ff5d4f20b37a7fe7976
0104755 root root 0 0 19171 X

rpm -q glibc gives:
glibc-2.1.2-11
Comment 3 Hans de Goede 1999-10-01 13:02:59 EDT
Just read you mail that it isn't suid root for you, you could have
mentioned that over here too ;)

Okay, you're partially right mc seems to have been fixed to not use
pt_chown anymore.

But gnome-terminal still gives:
[hans@shalem hans]$ gnome-terminal
pt_chown: needs to be installed setuid `root'
Error: unable to fork: Success
[hans@shalem hans]$
Comment 4 Hans de Goede 1999-10-01 13:13:59 EDT
correction it is a tricky bug:

Change /usr/libexec/pt_chown to 755

If I open one gnome-terminal all is well
second all is well, third fails

What happens is that pt_chown is only called for pty's which haven't
been used by the owner before so If I first open a few gnome-terminals
with /usr/libexec/pt_chown suid root.

And then try it without /usr/libexec/pt_chown suid root then I can
open as many terminals as I already had open, it goes wrong as soon as
I open as many as I had open + 1.

If I'm as far that gnome-terminal starts failing so does mc's
subshell.
Comment 5 Bill Nottingham 1999-10-01 14:49:59 EDT
Do you have the /dev/pts filesystem mounted?
Comment 6 Hans de Goede 1999-10-01 14:59:59 EDT
oops, I didn't, with it it works fine sorry for the hassle.
Comment 7 Bill Nottingham 1999-10-01 18:34:59 EDT
That's OK.
Comment 8 Hans de Goede 1999-12-21 10:19:59 EST
After some further checking I found out that the problem is devfs related, this
bug does happen on devfs kernel, since devfs doesn't support the pts filesystem,
so maybe this should still be fixed, maybe ?

Note You need to log in before you can comment on or make changes to this bug.