summaryrefslogtreecommitdiff
path: root/channels.c
diff options
context:
space:
mode:
authorDamien Miller <djm@mindrot.org>2001-02-04 23:20:18 +1100
committerDamien Miller <djm@mindrot.org>2001-02-04 23:20:18 +1100
commit33804263583e82fb7e6e36477fe63ebd14f15ecb (patch)
tree90d891bedf231b49acdd91f456d58a4142070bd6 /channels.c
parent45cb2937bc8a74c1e1f7da3b35ad4319d3033baf (diff)
NB: big update - may break stuff. Please test!
- (djm) OpenBSD CVS sync: - markus@cvs.openbsd.org 2001/02/03 03:08:38 [auth-options.c auth-rh-rsa.c auth-rhosts.c auth.c canohost.c] [canohost.h servconf.c servconf.h session.c sshconnect1.c sshd.8] [sshd_config] make ReverseMappingCheck optional in sshd_config; ok djm@,dugsong@ - markus@cvs.openbsd.org 2001/02/03 03:19:51 [ssh.1 sshd.8 sshd_config] Skey is now called ChallengeResponse - markus@cvs.openbsd.org 2001/02/03 03:43:09 [sshd.8] use no-pty option in .ssh/authorized_keys* if you need a 8-bit clean channel. note from Erik.Anggard@cygate.se (pr/1659) - stevesk@cvs.openbsd.org 2001/02/03 10:03:06 [ssh.1] typos; ok markus@ - djm@cvs.openbsd.org 2001/02/04 04:11:56 [scp.1 sftp-server.c ssh.1 sshd.8 sftp-client.c sftp-client.h] [sftp-common.c sftp-common.h sftp-int.c sftp-int.h sftp.1 sftp.c] Basic interactive sftp client; ok theo@ - (djm) Update RPM specs for new sftp binary - (djm) Update several bits for new optional reverse lookup stuff. I think I got them all.
Diffstat (limited to 'channels.c')
-rw-r--r--channels.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/channels.c b/channels.c
index 82a2db05e..d343ac89e 100644
--- a/channels.c
+++ b/channels.c
@@ -40,7 +40,7 @@
40 */ 40 */
41 41
42#include "includes.h" 42#include "includes.h"
43RCSID("$OpenBSD: channels.c,v 1.85 2001/01/29 19:42:35 markus Exp $"); 43RCSID("$OpenBSD: channels.c,v 1.88 2001/02/01 21:58:08 markus Exp $");
44 44
45#include <openssl/rsa.h> 45#include <openssl/rsa.h>
46#include <openssl/dsa.h> 46#include <openssl/dsa.h>
@@ -600,7 +600,7 @@ channel_post_port_listener(Channel *c, fd_set * readset, fd_set * writeset)
600 struct sockaddr addr; 600 struct sockaddr addr;
601 int newsock, newch; 601 int newsock, newch;
602 socklen_t addrlen; 602 socklen_t addrlen;
603 char buf[1024], *remote_hostname, *rtype; 603 char buf[1024], *remote_ipaddr, *rtype;
604 int remote_port; 604 int remote_port;
605 605
606 rtype = (c->type == SSH_CHANNEL_RPORT_LISTENER) ? 606 rtype = (c->type == SSH_CHANNEL_RPORT_LISTENER) ?
@@ -616,13 +616,13 @@ channel_post_port_listener(Channel *c, fd_set * readset, fd_set * writeset)
616 error("accept: %.100s", strerror(errno)); 616 error("accept: %.100s", strerror(errno));
617 return; 617 return;
618 } 618 }
619 remote_hostname = get_remote_hostname(newsock); 619 remote_ipaddr = get_peer_ipaddr(newsock);
620 remote_port = get_peer_port(newsock); 620 remote_port = get_peer_port(newsock);
621 snprintf(buf, sizeof buf, 621 snprintf(buf, sizeof buf,
622 "listen port %d for %.100s port %d, " 622 "listen port %d for %.100s port %d, "
623 "connect from %.200s port %d", 623 "connect from %.200s port %d",
624 c->listening_port, c->path, c->host_port, 624 c->listening_port, c->path, c->host_port,
625 remote_hostname, remote_port); 625 remote_ipaddr, remote_port);
626 626
627 newch = channel_new(rtype, 627 newch = channel_new(rtype,
628 SSH_CHANNEL_OPENING, newsock, newsock, -1, 628 SSH_CHANNEL_OPENING, newsock, newsock, -1,
@@ -644,7 +644,7 @@ channel_post_port_listener(Channel *c, fd_set * readset, fd_set * writeset)
644 packet_put_int(c->host_port); 644 packet_put_int(c->host_port);
645 } 645 }
646 /* originator host and port */ 646 /* originator host and port */
647 packet_put_cstring(remote_hostname); 647 packet_put_cstring(remote_ipaddr);
648 packet_put_int(remote_port); 648 packet_put_int(remote_port);
649 packet_send(); 649 packet_send();
650 } else { 650 } else {
@@ -657,7 +657,7 @@ channel_post_port_listener(Channel *c, fd_set * readset, fd_set * writeset)
657 } 657 }
658 packet_send(); 658 packet_send();
659 } 659 }
660 xfree(remote_hostname); 660 xfree(remote_ipaddr);
661 } 661 }
662} 662}
663 663