Bug 12731 - Multiple instances of directory in PATH variable
Summary: Multiple instances of directory in PATH variable
Keywords:
Status: CLOSED RAWHIDE
Alias: None
Product: Red Hat Linux
Classification: Retired
Component: krb5
Version: 6.2
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Nalin Dahyabhai
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2000-06-19 22:17 UTC by Ashwin Kalbag
Modified: 2008-05-01 15:37 UTC (History)
0 users

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2000-06-20 14:06:36 UTC
Embargoed:


Attachments (Terms of Use)

Description Ashwin Kalbag 2000-06-19 22:17:26 UTC
Hello,

I recently installed Red Hat Linux 6.2 Professional (i686) on a Pentium 
III Dell as a dual boot system with Windows NT 4.0.  I also added the 
Kerberos 5 security advisory fix.  I'm set up to run the Gnome desktop.

I now find that when I'm logged in as "root" user (default shell 
is "bash"), the following happens:
1.  If I get a teletype terminal with Ctrl-Alt-F2 and then login as root 
and do an "echo $PATH", my PATH variable is OK.
2.  If I get a "Regular Xterm" from the Gnome "Utilities" menu, and 
then "echo $PATH", I see the 
directories "/usr/kerberos/sbin:/usr/kerberos/bin" prepended to my PATH 
variable 3 times instead of 1.

I believe this is due to the fact that because I'm running "bash", 
both /etc/profile.d/krb5.csh and /etc/profile.d/krb5.sh are being run 
from /etc/bashrc and/or /etc/csh.cshrc, /etc/csh.login.  This results in 
the prepending the Kerberos paths 3 times to the original value of PATH.

I'm not sure if this explanation is correct - but I'd like to know what's 
causing it and how to fix this.  I don't want my PATH var to contain 
garbage, especially as "root".

Thanks in advance.

Ashwin Kalbag
kalbag
212-582-2977

Comment 1 Nalin Dahyabhai 2000-06-19 22:59:33 UTC
This should be fixed in the latest Kerberos 5 packages in our build tree and in
Raw Hide (ftp://ftp.redhat.com/pub/rawhide/).

Comment 2 Ashwin Kalbag 2000-06-20 13:57:02 UTC
It's nice that the bug is fixed in a forthcoming release of Red Hat.  But I
would like to fix this on my current system, without installing the RawHide
version which has other fixes in it as well and messing my system up.

What do I need to change on my system right now to make it go away?

Comment 3 Ashwin Kalbag 2000-06-20 14:06:32 UTC
BTW, I went to ftp://ftp.redhat.com/pub/rawhide/i386/RedHat/RPMS/.
I didn't find my version krb5-xxx-1.1.1-21, I found 1.1.1-20, but
krb5-configs-1.1.1-20 was missing.  Also the dates on the other 4 rpms of krb5
are Jun 8, 2000 - before my reporting the fix.  Are you sure this is the correct
site, or am I doing something wrong?

Comment 4 Nalin Dahyabhai 2000-06-20 14:36:25 UTC
Raw Hide probably hasn't been refreshed for almost a week now.  We released a
security errata for 6.2 that unfortunately predates that fix (all of the
Kerberos erratas are backports of what we have in the development tree, from
which Raw Hide is built).  Anyhow, the scripts in /etc/profile.d never checked
that the directory in question might already be in the PATH before adding it
again.  The fixed krb5.sh:


if ! echo ${PATH} | grep -q /usr/kerberos/bin ; then
	PATH=/usr/kerberos/bin:${PATH}
fi
if ! echo ${PATH} | grep -q /usr/kerberos/sbin ; then
	if [ `id -u` = 0 ] ; then
		PATH=/usr/kerberos/sbin:${PATH}
	fi
fi



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