diff options
author | pst <pst@FreeBSD.org> | 1995-02-23 00:20:00 +0000 |
---|---|---|
committer | pst <pst@FreeBSD.org> | 1995-02-23 00:20:00 +0000 |
commit | 37063bd4edb87b70b019d35bddf18209ab478c44 (patch) | |
tree | c2ec59123a60e285b451f58acfbedc78a4aab7f2 /usr.sbin/sendmail/src/daemon.c | |
parent | babe0fd0e29aedfa2e1d473fbb3dcec915a3b575 (diff) | |
download | FreeBSD-src-37063bd4edb87b70b019d35bddf18209ab478c44.zip FreeBSD-src-37063bd4edb87b70b019d35bddf18209ab478c44.tar.gz |
Sendmail 8.6.10 update for security problems.
Imported on CSRG/V_8_6_10 branch.
Obtained from: CSRG/Allman
Diffstat (limited to 'usr.sbin/sendmail/src/daemon.c')
-rw-r--r-- | usr.sbin/sendmail/src/daemon.c | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/usr.sbin/sendmail/src/daemon.c b/usr.sbin/sendmail/src/daemon.c index 293438b..fe1070b 100644 --- a/usr.sbin/sendmail/src/daemon.c +++ b/usr.sbin/sendmail/src/daemon.c @@ -37,9 +37,9 @@ #ifndef lint #ifdef DAEMON -static char sccsid[] = "@(#)daemon.c 8.48 (Berkeley) 4/18/94 (with daemon mode)"; +static char sccsid[] = "@(#)daemon.c 8.48.1.2 (Berkeley) 2/9/95 (with daemon mode)"; #else -static char sccsid[] = "@(#)daemon.c 8.48 (Berkeley) 4/18/94 (without daemon mode)"; +static char sccsid[] = "@(#)daemon.c 8.48.1.2 (Berkeley) 2/9/95 (without daemon mode)"; #endif #endif /* not lint */ @@ -1122,9 +1122,11 @@ getauthinfo(fd) while (isascii(*++p) && isspace(*p)) continue; - /* p now points to the authenticated name */ - (void) sprintf(hbuf, "%s@%s", - p, RealHostName == NULL ? "localhost" : RealHostName); + /* p now points to the authenticated name -- copy carefully */ + cleanstrcpy(hbuf, p, MAXNAME); + i = strlen(hbuf); + hbuf[i++] = '@'; + strcpy(&hbuf[i], RealHostName == NULL ? "localhost" : RealHostName); goto finish; closeident: |