process so that any logging it does is with the right timezone. From
Scott Strickler, ok djm@.
problem reported by Tavis Ormandy, Google Security Team;
ok markus@ deraadt@
- (djm) Add openssh.xml to .cvsignore and sort it
+ - (dtucker) [auth-pam.c] Propogate TZ environment variable to PAM auth
+ process so that any logging it does is with the right timezone. From
+ Scott Strickler, ok djm@.
20060912
- (djm) [Makefile.in buildpkg.sh.in configure.ac openssh.xml.in]
u_int i;
const char *pam_user;
const char **ptr_pam_user = &pam_user;
+ char *tz = getenv("TZ");
pam_get_item(sshpam_handle, PAM_USER,
(sshpam_const void **)ptr_pam_user);
+
environ[0] = NULL;
+ if (tz != NULL)
+ if (setenv("TZ", tz, 1) == -1)
+ error("PAM: could not set TZ environment: %s",
+ strerror(errno));
if (sshpam_authctxt != NULL) {
setproctitle("%s [pam]",