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

rshd s/strcpy/strlcpy/



Another minor strcpy/strncpy/strcat/strncat fix, this one for rshd.


jsyn

--- libexec/rshd/rshd.c.orig	Mon Jul  2 14:21:44 2001
+++ libexec/rshd/rshd.c	Mon Jul  2 14:26:05 2001
@@ -441,7 +441,7 @@ doit(fromp)
 		kdata = (AUTH_DAT *) authbuf;
 		ticket = (KTEXT) tickbuf;
 		authopts = 0L;
-		strcpy(instance, "*");
+		strlcpy(instance, "*", sizeof(instance));
 		version[VERSION_SIZE - 1] = '\0';
 #ifdef CRYPT
 		if (doencrypt) {