scp doesn't work with sshd 2.5.1p1 on Solaris 2.6

mouring at etoh.eviladmin.org mouring at etoh.eviladmin.org
Tue Feb 20 07:04:43 EST 2001


On Mon, 19 Feb 2001, David Schweikert wrote:

> On Mon, Feb 19, 2001 at 13:14:08 -0600, mouring at etoh.eviladmin.org wrote:
> > 
> > If you compile without --with-pam do you still have scp fail?
> 
> No, it works.
> 

Out of interest..  If you apply this patch.  Does scp work again with the
--with-pam option?

- Ben

Index: openbsd-compat/getcwd.c
===================================================================
RCS file: /var/cvs/openssh/openbsd-compat/getcwd.c,v
retrieving revision 1.1
diff -u -r1.1 getcwd.c
--- openbsd-compat/getcwd.c	2001/01/31 21:52:03	1.1
+++ openbsd-compat/getcwd.c	2001/02/19 19:48:19
@@ -119,7 +119,7 @@
 			 * path to the beginning of the buffer, but it's always
 			 * been that way and stuff would probably break.
 			 */
-			memmove(bpt, pt, ept - bpt);
+			memmove(pt, bpt, ept - bpt);
 			free(up);
 			return (pt);
 		}
@@ -170,7 +170,7 @@
 					goto notfound;
 				if (ISDOT(dp))
 					continue;
-				memmove(dp->d_name, bup, dp->d_namlen + 1);
+				memmove(bup, dp->d_name, dp->d_namlen + 1);
 
 				/* Save the first error for later. */
 				if (lstat(up, &s)) {
@@ -202,13 +202,13 @@
 			pt = npt;
 			bpt = pt + off;
 			ept = pt + ptsize;
-			memmove(bpt, ept - len, len);
+			memmove(ept - len, bpt, len);
 			bpt = ept - len;
 		}
 		if (!first)
 			*--bpt = '/';
 		bpt -= dp->d_namlen;
-		memmove(dp->d_name, bpt, dp->d_namlen);
+		memmove(bpt, dp->d_name, dp->d_namlen);
 		(void)closedir(dir);
 
 		/* Truncate any file name. */
Index: openbsd-compat/setenv.c
===================================================================
RCS file: /var/cvs/openssh/openbsd-compat/setenv.c,v
retrieving revision 1.1
diff -u -r1.1 setenv.c
--- openbsd-compat/setenv.c	2001/01/31 21:52:04	1.1
+++ openbsd-compat/setenv.c	2001/02/19 19:48:20
@@ -122,7 +122,7 @@
 			    (cnt + 2)));
 			if (!P)
 				return (-1);
-			memmove(environ, P, cnt * sizeof(char *));
+			memmove(P, environ, cnt * sizeof(char *));
 			environ = P;
 		}
 		environ[cnt + 1] = NULL;






More information about the openssh-unix-dev mailing list