pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/security/ssh2 Added missing fflush to scp when priting...



details:   https://anonhg.NetBSD.org/pkgsrc/rev/7b817e774239
branches:  trunk
changeset: 520906:7b817e774239
user:      kivinen <kivinen%pkgsrc.org@localhost>
date:      Thu Nov 02 12:31:58 2006 +0000

description:
Added missing fflush to scp when priting statistics. Fixed bug
        in the reverse dns queries for IPv6 addresses (overwriting 12
        bytes of local variables on the stack). Disabled x11-security
        on all platforms, as it does not seem to work on i386 either.
        Incremented PKGREVISION to 7.

diffstat:

 security/ssh2/Makefile         |   7 +++----
 security/ssh2/distinfo         |   4 +++-
 security/ssh2/patches/patch-bh |  12 ++++++++++++
 security/ssh2/patches/patch-bi |  41 +++++++++++++++++++++++++++++++++++++++++
 4 files changed, 59 insertions(+), 5 deletions(-)

diffs (105 lines):

diff -r 2b6fa216b207 -r 7b817e774239 security/ssh2/Makefile
--- a/security/ssh2/Makefile    Thu Nov 02 07:57:56 2006 +0000
+++ b/security/ssh2/Makefile    Thu Nov 02 12:31:58 2006 +0000
@@ -1,8 +1,8 @@
-# $NetBSD: Makefile,v 1.17 2006/09/22 13:58:46 kivinen Exp $
+# $NetBSD: Makefile,v 1.18 2006/11/02 12:31:58 kivinen Exp $
 
 DISTNAME=      ssh-3.2.9.1
 PKGNAME=       ${DISTNAME:C/ssh-/ssh2-/}
-PKGREVISION=   6
+PKGREVISION=   7
 CATEGORIES=    security
 MASTER_SITES=  ftp://ftp.ssh.com/pub/ssh/
 
@@ -51,13 +51,12 @@
 CONFIGURE_ARGS+=       --with-libwrap=${BUILDLINK_PREFIX.tcp-wrappers}
 CONFIGURE_ARGS+=       --with-pid-dir=${SSH_PID_DIR:Q}
 
-.if ${OPSYS} == "NetBSD" && ${MACHINE_ARCH} == "x86_64"
 # This seems to break x11 forwarding at least on NetBSD 3.1 amd64
+# and i386, so I assume it actually breaks it for all platforms.
 # (i.e ssh localhost xterm does not work as client will get wrong
 # auth cookie).
 # Without this it will use the xauth method and that will work.
 CONFIGURE_ARGS+=       --without-x11-security
-.endif
 
 # Setting FOREIGN_ETCDIR to PKG_SYSCONFBASEDIR may seem stupid
 # if PKG_SYSCONFDIR.${PKG_SYSCONFVAR} is set but it does no harm...
diff -r 2b6fa216b207 -r 7b817e774239 security/ssh2/distinfo
--- a/security/ssh2/distinfo    Thu Nov 02 07:57:56 2006 +0000
+++ b/security/ssh2/distinfo    Thu Nov 02 12:31:58 2006 +0000
@@ -1,4 +1,4 @@
-$NetBSD: distinfo,v 1.11 2006/09/22 13:58:46 kivinen Exp $
+$NetBSD: distinfo,v 1.12 2006/11/02 12:31:58 kivinen Exp $
 
 SHA1 (ssh-3.2.9.1.tar.gz) = 22e4589c889aef18e53a8942716084f0d8ede7db
 RMD160 (ssh-3.2.9.1.tar.gz) = 21bfe97fae477dea1109c6e6eb44a448b6b2f250
@@ -36,3 +36,5 @@
 SHA1 (patch-be) = 788a8fa682e968d9e3cd55213547f82908cc3a0a
 SHA1 (patch-bf) = 64fa9f13619a9d222af9a24d0b1069033facdef1
 SHA1 (patch-bg) = 73da22930f753fc02cd4a5bad30b4edf226d1180
+SHA1 (patch-bh) = 3a4798d70198858af33a6325325fb37dfc50356e
+SHA1 (patch-bi) = 6d8ad1c52b0e27ba262c8837dbb55c8ca4e744a7
diff -r 2b6fa216b207 -r 7b817e774239 security/ssh2/patches/patch-bh
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/security/ssh2/patches/patch-bh    Thu Nov 02 12:31:58 2006 +0000
@@ -0,0 +1,12 @@
+$NetBSD: patch-bh,v 1.1 2006/11/02 12:31:58 kivinen Exp $
+
+--- apps/ssh/scp2.c.orig       2003-12-03 15:17:22.000000000 +0200
++++ apps/ssh/scp2.c
+@@ -833,6 +833,7 @@ void scp_simple_progress_cb(SshFileCopyC
+   
+   fprintf(stdout, "%s | %4sB | %4sB/s | TOC: %s\r\n",
+           file_name, num_buffer, tr_rate_buffer, toc_buffer);
++  fflush(stdout);
+   ssh_xfree(file_name);
+ }
+ 
diff -r 2b6fa216b207 -r 7b817e774239 security/ssh2/patches/patch-bi
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/security/ssh2/patches/patch-bi    Thu Nov 02 12:31:58 2006 +0000
@@ -0,0 +1,41 @@
+$NetBSD: patch-bi,v 1.1 2006/11/02 12:31:58 kivinen Exp $
+
+--- lib/sshutil/sshnet/sshunixtcp.c.orig       2003-12-03 15:17:31.000000000 +0200
++++ lib/sshutil/sshnet/sshunixtcp.c
+@@ -1459,7 +1459,6 @@ char *ssh_tcp_get_host_by_addr_sync(cons
+ #else /* VXWORKS */
+   unsigned char outbuf[16];
+   size_t outbuflen = 16;
+-  struct in_addr in_addr;
+   struct hostent *hp;
+   char *name;
+   int i;
+@@ -1467,8 +1466,16 @@ char *ssh_tcp_get_host_by_addr_sync(cons
+   if (!ssh_inet_strtobin(addr, outbuf, &outbuflen))
+     return NULL;
+ 
+-  memmove(&in_addr.s_addr, outbuf, outbuflen);
+-  hp = gethostbyaddr((char *)&in_addr, sizeof(struct in_addr), AF_INET);
++#ifdef AF_INET6
++  hp = gethostbyaddr((char *)outbuf, outbuflen,
++                   (outbuflen == 16) ? AF_INET6 : AF_INET);
++#else /* AF_INET6 */
++  if (outbuflen == 16)
++    return NULL;
++  hp = gethostbyaddr((char *)outbuf, outbuflen,
++                   AF_INET);
++#endif /* AF_INET6 */
++  
+   if (!hp)
+     return NULL;
+ 
+@@ -1491,7 +1498,8 @@ char *ssh_tcp_get_host_by_addr_sync(cons
+ 
+   /* Look for the address from the list of addresses. */
+   for (i = 0; hp->h_addr_list[i]; i++)
+-    if (memcmp(hp->h_addr_list[i], &in_addr, sizeof(in_addr)) == 0)
++    if (hp->h_length == outbuflen && 
++      memcmp(hp->h_addr_list[i], outbuf, outbuflen) == 0)
+       break;
+   /* If we reached the end of the list, the address was not there. */
+   if (!hp->h_addr_list[i])



Home | Main Index | Thread Index | Old Index