Matthew_S_Cramer@armstrong.com
1999-Oct-05 19:27 UTC
Solution to accessing shares w/ 2.0.5a and openBSD 2.5 (bug in OpenBSD calls or configure script?)
I recently installed an OpenBSD 2.5 box and compiled the 2.0.5a version of Samba. I set the security to security=user and turned on encryption so that I can access my home directory from my NT workstation (this is how I set up all my other machines and only the OpenBSD caused a problem). I was getting an error when I tried to connect to the machine - my logs showed an error of unable to set the appropriate GID from smbd/uid.c. (NT gave me the "incorrect user or password" dialog). The function that was failing was set_effective_gid in lib/util_sec.c. In that section there are four possible calls: some UID trapdoor call setresgid setregid setegid Which one is used is determined by #defines in include/config.h. For some reason the configure script set the trapdoor, the setregid, and the setegid (and the corresponding defs for uid calls) to 1 and did not declare only the one for setresgid. I commented the lines for the trapdoor UID def and the setregid def (since OpenBSD's man setregid said it is depreciated and to use setegid) so that when set_effective_gid got called it only used the setegid calls (after confirming this worked I did the same for uid calls). Doing this seemed to fix it - I can now access shares. The configure script for OpenBSD 2.5 at least should probably do these defs rather than what it does now. If I am breaking something else let me know. Matt