summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBen Lindstrom <mouring@eviladmin.org>2002-12-23 02:15:57 +0000
committerBen Lindstrom <mouring@eviladmin.org>2002-12-23 02:15:57 +0000
commit611797ed1533f14ac2c04a2531ad90615afa6174 (patch)
tree96ecba14e265263a04cb3970ec45184f87ad156e
parentc276c1208e43ed4305d723004ddf602fbe99513b (diff)
- stevesk@cvs.openbsd.org 2002/12/04 04:36:47
[session.c] remove xauth entries before add; PR 2994 from janjaap@stack.nl. ok markus@
-rw-r--r--ChangeLog6
-rw-r--r--session.c10
2 files changed, 12 insertions, 4 deletions
diff --git a/ChangeLog b/ChangeLog
index 1745e7c9..dcddd6c8 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -40,6 +40,10 @@
[scp.c sftp.c ssh.c]
allow usernames with embedded '@', e.g. scp user@vhost@realhost:file /tmp;
http://bugzilla.mindrot.org/show_bug.cgi?id=447; ok mouring@, millert@
+ - stevesk@cvs.openbsd.org 2002/12/04 04:36:47
+ [session.c]
+ remove xauth entries before add; PR 2994 from janjaap@stack.nl.
+ ok markus@
20021205
- (djm) PERL-free fixpaths from stuge-openssh-unix-dev@cdy.org
@@ -875,4 +879,4 @@
save auth method before monitor_reset_key_state(); bugzilla bug #284;
ok provos@
-$Id: ChangeLog,v 1.2526 2002/12/23 02:14:51 mouring Exp $
+$Id: ChangeLog,v 1.2527 2002/12/23 02:15:57 mouring Exp $
diff --git a/session.c b/session.c
index 9074525a..ac156175 100644
--- a/session.c
+++ b/session.c
@@ -33,7 +33,7 @@
*/
#include "includes.h"
-RCSID("$OpenBSD: session.c,v 1.150 2002/09/16 19:55:33 stevesk Exp $");
+RCSID("$OpenBSD: session.c,v 1.151 2002/12/04 04:36:47 stevesk Exp $");
#include "ssh.h"
#include "ssh1.h"
@@ -1146,8 +1146,10 @@ do_rc_files(Session *s, const char *shell)
/* Add authority data to .Xauthority if appropriate. */
if (debug_flag) {
fprintf(stderr,
- "Running %.500s add "
- "%.100s %.100s %.100s\n",
+ "Running %.500s remove %.100s\n",
+ options.xauth_location, s->auth_display);
+ fprintf(stderr,
+ "%.500s add %.100s %.100s %.100s\n",
options.xauth_location, s->auth_display,
s->auth_proto, s->auth_data);
}
@@ -1155,6 +1157,8 @@ do_rc_files(Session *s, const char *shell)
options.xauth_location);
f = popen(cmd, "w");
if (f) {
+ fprintf(f, "remove %s\n",
+ s->auth_display);
fprintf(f, "add %s %s %s\n",
s->auth_display, s->auth_proto,
s->auth_data);