=================================================================== RCS file: /cvsrepo/anoncvs/cvs/src/usr.bin/signify/signify.c,v retrieving revision 1.81 retrieving revision 1.82 diff -c -r1.81 -r1.82 *** src/usr.bin/signify/signify.c 2014/05/14 15:55:11 1.81 --- src/usr.bin/signify/signify.c 2014/05/14 15:56:41 1.82 *************** *** 1,4 **** ! /* $OpenBSD: signify.c,v 1.81 2014/05/14 15:55:11 tedu Exp $ */ /* * Copyright (c) 2013 Ted Unangst * --- 1,4 ---- ! /* $OpenBSD: signify.c,v 1.82 2014/05/14 15:56:41 tedu Exp $ */ /* * Copyright (c) 2013 Ted Unangst * *************** *** 140,149 **** } b64end = strchr(commentend + 1, '\n'); if (!b64end) ! errx(1, "missing new line after b64 in %s", filename); *b64end = '\0'; if (b64_pton(commentend + 1, buf, buflen) != buflen) ! errx(1, "invalid b64 encoding in %s", filename); if (memcmp(buf, PKALG, 2) != 0) errx(1, "unsupported file %s", filename); return b64end - b64 + 1; --- 140,149 ---- } b64end = strchr(commentend + 1, '\n'); if (!b64end) ! errx(1, "missing new line after base64 in %s", filename); *b64end = '\0'; if (b64_pton(commentend + 1, buf, buflen) != buflen) ! errx(1, "invalid base64 encoding in %s", filename); if (memcmp(buf, PKALG, 2) != 0) errx(1, "unsupported file %s", filename); return b64end - b64 + 1; *************** *** 237,243 **** errx(1, "comment too long"); writeall(fd, header, strlen(header), filename); if ((rv = b64_ntop(buf, buflen, b64, sizeof(b64)-1)) == -1) ! errx(1, "b64 encode failed"); b64[rv++] = '\n'; writeall(fd, b64, rv, filename); explicit_bzero(b64, sizeof(b64)); --- 237,243 ---- errx(1, "comment too long"); writeall(fd, header, strlen(header), filename); if ((rv = b64_ntop(buf, buflen, b64, sizeof(b64)-1)) == -1) ! errx(1, "base64 encode failed"); b64[rv++] = '\n'; writeall(fd, b64, rv, filename); explicit_bzero(b64, sizeof(b64));