Fedora Core 4 libsafe-2.0-17c (Fedora Extras) libsafe is supposed to protect against buffer overflow in process stacks. It is possible that realpath implementation in Samba has buffer overflow problem. Samba prints the following error messages if libsafe is installed [2005/10/03 01:00:11, 5] smbd/filename.c:unix_convert(108) unix_convert called on file "" [2005/10/03 01:00:11, 5] smbd/filename.c:unix_convert(137) conversion finished "" -> . [2005/10/03 01:00:11, 3] smbd/vfs.c:reduce_name(919) reduce_name [.] [/udd/mur] [2005/10/03 01:00:11, 1] smbd/vfs.c:reduce_name(981) reduce_name: couldn't get realpath for . [2005/10/03 01:00:11, 5] smbd/filename.c:check_name(418) check_name on . failed [2005/10/03 01:00:11, 3] smbd/error.c:unix_error_packet(91) unix_error_packet: error string = Invalid argument [2005/10/03 01:00:11, 3] smbd/error.c:error_packet(147) error packet at smbd/reply.c(800) cmd=16 (SMBchkpth) NT_STATUS_INVALID_HANDLE When libsafe is removed everuthing is fine.
Can you test what you are doing under valgrind, as well as libsafe. If there really is a problem with realpath then valgrind will show this faster than libsafe I think. Jeremy.
realpath() is from libc. That would be their bug and not ours.