$OpenBSD: patch-gnats_mk_auth_c,v 1.2 2007/12/28 17:11:25 espie Exp $ --- gnats/mk_auth.c.orig Thu Nov 5 20:54:10 1998 +++ gnats/mk_auth.c Fri Dec 28 18:00:24 2007 @@ -140,7 +140,7 @@ krb_mk_auth(options, ticket, service, inst, realm, che #ifdef ATHENA_COMPAT /* this is only for compatibility with old servers */ if (options & KOPT_DO_OLDSTYLE) { - (void) sprintf(buf->dat,"%d ",ticket->length); + (void) snprintf(buf->dat, sizeof(buf->dat), "%d ", ticket->length); (void) write(fd, buf, strlen(buf)); (void) write(fd, (char *) ticket->dat, ticket->length); return(rem);