Bug 1636

Summary: Loging after chroot
Product: Portable OpenSSH Reporter: jchadima
Component: sshdAssignee: Assigned to nobody <unassigned-bugs>
Status: CLOSED WONTFIX    
Severity: normal CC: djm, jchadima
Priority: P2    
Version: 5.2p1   
Hardware: Other   
OS: Linux   
Attachments:
Description Flags
Patch solving the problem djm: ok-

Description jchadima 2009-08-28 15:32:07 AEST
It is useful to continue to write the logs after chroot to the directory which do not contain the syslog socket in the chroot environment.
Comment 1 jchadima 2009-08-28 15:33:45 AEST
Created attachment 1680 [details]
Patch solving the problem
Comment 2 Damien Miller 2009-08-29 03:17:59 AEST
Comment on attachment 1680 [details]
Patch solving the problem

This patch doesn't work on platforms that use syslog_r
Comment 3 jchadima 2009-08-31 15:50:44 AEST
What is the problem? Where it can be reproduced? Solaris?
Comment 4 jchadima 2009-09-01 17:08:15 AEST
Oh I see poor broken system with disconnectlog_r.... From the manual page can be read:

SYSLOG ( 3 ) OpenBSD Programmer’sManual SYSLOG(3) 
..... 
LOG_NDELAY Open the connection tosyslogd(8) immediately. Normally the    open is delayed until 
the first message is logged. Useful for programs that need to manage the order in which 
file descriptors are allocated. This option must be used in programs that call chroot(2) 
where the newroot does not have its own log socket. 
......
Comment 5 Damien Miller 2011-06-23 20:54:03 AEST
OpenSSH 5.9 passes log messages from the preauth privsep slave to the monitor for logging, so any chroot /dev/log workarounds are no longer necessary.
Comment 6 Damien Miller 2011-09-06 15:33:05 AEST
close resolved bugs now that openssh-5.9 has been released