Displaying 2 results from an estimated 2 matches for "_pw".
Did you mean:
_p
2001 Jun 05
1
OpenSSH tmp cleanup
Hi,
I noticed that Markus has fixed the temporary file cleanup problems in
OpenSSH cvs. What files need patching for this ? I only noticed
changes in: session.c, channels.h and channels.c.
-Jarno
--
Jarno Huuskonen <Jarno.Huuskonen at uku.fi>
2002 Feb 12
0
[Patch] Xauthority file in /tmp
...2002
@@ -151,6 +151,9 @@
extern int startup_pipe;
extern void destroy_sensitive_data(void);
+/* Local Xauthority file. */
+static char *xauthfile = NULL;
+
/* original command from peer. */
const char *original_command = NULL;
@@ -220,6 +223,28 @@
#endif
}
+xauthfile_cleanup_proc(void *_pw)
+{
+ struct passwd *pw = _pw;
+
+ debug("xauthfile_cleanup_proc called");
+
+ if (xauthfile != NULL) {
+ char *p;
+ temporarily_use_uid(pw);
+ unlink(xauthfile);
+ p = strrchr(xauthfile, '/');
+ if (p != NULL) {
+ *p = '\0';
+ rmdir(xauthfile);
+ }
+ xfr...