lkml.org 
[lkml]   [1998]   [May]   [13]   [last100]   RSS Feed
Views: [more markup]  [less markup]  [headers]  [forward] 
 
Messages in this thread
/
DateWed, 13 May 1998 21:03:47 -0400 (EDT)
FromADAM Sulmicki <>
Subjectcan't login as user?
I did bit more testing.

the nfs server is RedHat 4.2. It exports /usr and two tftpboot
directories, the two dir are very similar, and based on 4.2, not 
identical though.

After that I did made an 34pre13 kernel and NET-booted it on 

Cyrix686MMX-PR200 /w 64mb ram,
	it appeared to work all fine, I could login as user etc.

Afrter that I netbooted it on 

Cyrix486-66 w/ 8mb ram.
	It would have exactly those symptom as other say:
	I could login fine as user, but trying any of the following: 
	login : it would fail w/ "no home/foo directory" message
	su    : would say "/bin/bash permission denied"
	trying to run a program which first setuid() and 
	then to ties to system("/bin/bash"), makes fork to fail.
	[program attached below]

[root@bea /root]# su foo
su: cannot run /bin/bash: Permission denied
[root@bea /root]# whoami
root
[root@bea /root]# test3
[root@bea /root]# whoami
root
[root@bea /root]# telnet localhost
Trying 127.0.0.1...
Connected to localhost.
Escape character is '^]'.
Red Hat Linux Red Hat Linux release 4.2 (Biltmore)
Kernel 2.0.34 on an i486
login: foo
No directory /foo!
Connection closed by foreign host.


Note : kernels were identical, the /usr dir was identical,
	the /tftpboot.<x> dirs are separate copies but
	I think they are closely identical, and after all
	they should not contribute to make system()
	call to fail.

[root@eax root]# cat test3.c
#include<unistd.h>
#include<stdlib.h>
main () {
   int err =  setuid(500);
   system("/bin/bash");
}

-Adam



-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu

\
 
 \ /
  Last update: 2005-03-22 13:42    [from the cache]
©2003-2008