[Chrootssh-users] chroot() not happening here either
Brought to you by:
punkball
From: <Ala...@ne...> - 2003-08-15 03:01:15
|
I'm using OpenBSD 3.1 and 3.3. I've got the tarball openssh-3.6.1p1-chroot.tar.gz When it's compiling I notice in the warnings: session.c: In function Do_setusercontext': session.c:1217: warning: unused variable New_root' session.c:1216: warning: unused variable User_dir' It seems to me from looking at the code that do_setusercontext() is where the actual chroot() happens, based on whether /./ is found in the variable new_root, but that's only if CHROOT is defined. CHROOT is defined, unconditionally, just after the #includes. The lines 1217 and 1216 where the warnings originate are inside an #ifdef CHROOT, as is the chroot() call itself, based on the condition: if(strncmp(new_root, "/./", 3) == 0) { It seems like new_root is kind of a critical variable to get warnings about it being unused. I haven't done any programming under OpenBSD at all, only some C under FreeBSD, and C isn't my forte anyway, being more of a Pascal/Delphi type. This just looks odd. The chroot just doesn't happen, but the sshd itself seems to be working, and according to this I'm running the patched version I expect to be: leto:alan {102} ssh -V OpenSSH_3.6.1p1, SSH protocols 1.5/2.0, OpenSSL 0x0090602f Alan __________________________________________________________________ McAfee VirusScan Online from the Netscape Network. Comprehensive protection for your entire computer. Get your free trial today! http://channels.netscape.com/ns/computing/mcafee/index.jsp?promo=393397 Get AOL Instant Messenger 5.1 free of charge. Download Now! http://aim.aol.com/aimnew/Aim/register.adp?promo=380455 |