Flawfinder version 2.0.10, (C) 2001-2019 David A. Wheeler. Number of rules (primarily dangerous function names) in C/C++ ruleset: 223 Examining data/gzip-1.10/zip.c Examining data/gzip-1.10/unlzw.c Examining data/gzip-1.10/lzw.c Examining data/gzip-1.10/unzip.c Examining data/gzip-1.10/sample/makecrc.c Examining data/gzip-1.10/sample/zread.c Examining data/gzip-1.10/sample/add.c Examining data/gzip-1.10/sample/sub.c Examining data/gzip-1.10/lib/cloexec.h Examining data/gzip-1.10/lib/dirent.in.h Examining data/gzip-1.10/lib/asnprintf.c Examining data/gzip-1.10/lib/chdir-long.c Examining data/gzip-1.10/lib/utimens.c Examining data/gzip-1.10/lib/lseek.c Examining data/gzip-1.10/lib/fseeko.c Examining data/gzip-1.10/lib/utimens.h Examining data/gzip-1.10/lib/arg-nonnull.h Examining data/gzip-1.10/lib/strerror.c Examining data/gzip-1.10/lib/at-func.c Examining data/gzip-1.10/lib/getopt.c Examining data/gzip-1.10/lib/printf-frexpl.c Examining data/gzip-1.10/lib/unlink.c Examining data/gzip-1.10/lib/basename-lgpl.c Examining data/gzip-1.10/lib/fcntl.in.h Examining data/gzip-1.10/lib/savedir.c Examining data/gzip-1.10/lib/vasnprintf.c Examining data/gzip-1.10/lib/signbitl.c Examining data/gzip-1.10/lib/getprogname.c Examining data/gzip-1.10/lib/printf-frexpl.h Examining data/gzip-1.10/lib/fpucw.h Examining data/gzip-1.10/lib/fcntl.c Examining data/gzip-1.10/lib/fsync.c Examining data/gzip-1.10/lib/getopt-cdefs.in.h Examining data/gzip-1.10/lib/sigaction.c Examining data/gzip-1.10/lib/stdio.in.h Examining data/gzip-1.10/lib/_Noreturn.h Examining data/gzip-1.10/lib/lstat.c Examining data/gzip-1.10/lib/error.h Examining data/gzip-1.10/lib/dirent-private.h Examining data/gzip-1.10/lib/isnanf.c Examining data/gzip-1.10/lib/timespec.h Examining data/gzip-1.10/lib/exitfail.c Examining data/gzip-1.10/lib/getdtablesize.c Examining data/gzip-1.10/lib/error.c Examining data/gzip-1.10/lib/match.c Examining data/gzip-1.10/lib/frexp.c Examining data/gzip-1.10/lib/ftello.c Examining data/gzip-1.10/lib/raise.c Examining data/gzip-1.10/lib/save-cwd.h Examining data/gzip-1.10/lib/string.in.h Examining data/gzip-1.10/lib/time.in.h Examining data/gzip-1.10/lib/unused-parameter.h Examining data/gzip-1.10/lib/malloc.c Examining data/gzip-1.10/lib/fd-safer-flag.c Examining data/gzip-1.10/lib/fd-hook.c Examining data/gzip-1.10/lib/fdopendir.c Examining data/gzip-1.10/lib/open-safer.c Examining data/gzip-1.10/lib/opendir.c Examining data/gzip-1.10/lib/perror.c Examining data/gzip-1.10/lib/calloc.c Examining data/gzip-1.10/lib/printf-args.c Examining data/gzip-1.10/lib/vfprintf.c Examining data/gzip-1.10/lib/malloca.c Examining data/gzip-1.10/lib/stdint.in.h Examining data/gzip-1.10/lib/assure.h Examining data/gzip-1.10/lib/filename.h Examining data/gzip-1.10/lib/openat-die.c Examining data/gzip-1.10/lib/getprogname.h Examining data/gzip-1.10/lib/frexpl.c Examining data/gzip-1.10/lib/fstat.c Examining data/gzip-1.10/lib/pipe-safer.c Examining data/gzip-1.10/lib/float.in.h Examining data/gzip-1.10/lib/fcntl-safer.h Examining data/gzip-1.10/lib/stat-w32.c Examining data/gzip-1.10/lib/sys_stat.in.h Examining data/gzip-1.10/lib/closedir.c Examining data/gzip-1.10/lib/getopt-pfx-core.h Examining data/gzip-1.10/lib/fseek.c Examining data/gzip-1.10/lib/gettext.h Examining data/gzip-1.10/lib/getcwd-lgpl.c Examining data/gzip-1.10/lib/close.c Examining data/gzip-1.10/lib/getopt1.c Examining data/gzip-1.10/lib/xmalloc.c Examining data/gzip-1.10/lib/dirent-safer.h Examining data/gzip-1.10/lib/sigprocmask.c Examining data/gzip-1.10/lib/ftell.c Examining data/gzip-1.10/lib/getopt-ext.h Examining data/gzip-1.10/lib/glthread/threadlib.c Examining data/gzip-1.10/lib/glthread/lock.h Examining data/gzip-1.10/lib/glthread/lock.c Examining data/gzip-1.10/lib/strerror-override.c Examining data/gzip-1.10/lib/fpurge.c Examining data/gzip-1.10/lib/printf.c Examining data/gzip-1.10/lib/msvc-nothrow.c Examining data/gzip-1.10/lib/printf-args.h Examining data/gzip-1.10/lib/yesno.c Examining data/gzip-1.10/lib/stat.c Examining data/gzip-1.10/lib/getopt_int.h Examining data/gzip-1.10/lib/isnanl.c Examining data/gzip-1.10/lib/fstatat.c Examining data/gzip-1.10/lib/fclose.c Examining data/gzip-1.10/lib/isnanf-nolibm.h Examining data/gzip-1.10/lib/filenamecat.h Examining data/gzip-1.10/lib/openat.h Examining data/gzip-1.10/lib/timespec.c Examining data/gzip-1.10/lib/gettimeofday.c Examining data/gzip-1.10/lib/strerror-override.h Examining data/gzip-1.10/lib/xalloc.h Examining data/gzip-1.10/lib/isnand.c Examining data/gzip-1.10/lib/creat-safer.c Examining data/gzip-1.10/lib/xalloc-oversized.h Examining data/gzip-1.10/lib/dosname.h Examining data/gzip-1.10/lib/size_max.h Examining data/gzip-1.10/lib/rmdir.c Examining data/gzip-1.10/lib/strdup.c Examining data/gzip-1.10/lib/getopt-core.h Examining data/gzip-1.10/lib/xsize.c Examining data/gzip-1.10/lib/fprintf.c Examining data/gzip-1.10/lib/intprops.h Examining data/gzip-1.10/lib/fseterr.c Examining data/gzip-1.10/lib/exitfail.h Examining data/gzip-1.10/lib/save-cwd.c Examining data/gzip-1.10/lib/statat.c Examining data/gzip-1.10/lib/errno.in.h Examining data/gzip-1.10/lib/msvc-nothrow.h Examining data/gzip-1.10/lib/signbitd.c Examining data/gzip-1.10/lib/limits.in.h Examining data/gzip-1.10/lib/dirname-lgpl.c Examining data/gzip-1.10/lib/open.c Examining data/gzip-1.10/lib/stdbool.in.h Examining data/gzip-1.10/lib/chdir-long.h Examining data/gzip-1.10/lib/unistd.c Examining data/gzip-1.10/lib/stat-time.h Examining data/gzip-1.10/lib/memchr.c Examining data/gzip-1.10/lib/printf-frexp.c Examining data/gzip-1.10/lib/math.in.h Examining data/gzip-1.10/lib/fseterr.h Examining data/gzip-1.10/lib/utime.c Examining data/gzip-1.10/lib/stddef.in.h Examining data/gzip-1.10/lib/stdlib.in.h Examining data/gzip-1.10/lib/fd-hook.h Examining data/gzip-1.10/lib/ignore-value.h Examining data/gzip-1.10/lib/dup.c Examining data/gzip-1.10/lib/stdio-impl.h Examining data/gzip-1.10/lib/getopt-pfx-ext.h Examining data/gzip-1.10/lib/readdir.c Examining data/gzip-1.10/lib/stpcpy.c Examining data/gzip-1.10/lib/freading.h Examining data/gzip-1.10/lib/pathmax.h Examining data/gzip-1.10/lib/yesno.h Examining data/gzip-1.10/lib/isnan.c Examining data/gzip-1.10/lib/printf-parse.c Examining data/gzip-1.10/lib/float+.h Examining data/gzip-1.10/lib/openat.c Examining data/gzip-1.10/lib/c++defs.h Examining data/gzip-1.10/lib/float.c Examining data/gzip-1.10/lib/openat-proc.c Examining data/gzip-1.10/lib/fd-safer.c Examining data/gzip-1.10/lib/openat-priv.h Examining data/gzip-1.10/lib/dup-safer-flag.c Examining data/gzip-1.10/lib/openat-safer.c Examining data/gzip-1.10/lib/math.c Examining data/gzip-1.10/lib/dup-safer.c Examining data/gzip-1.10/lib/sig-handler.c Examining data/gzip-1.10/lib/fchdir.c Examining data/gzip-1.10/lib/dirfd.c Examining data/gzip-1.10/lib/localtime-buffer.c Examining data/gzip-1.10/lib/stat-time.c Examining data/gzip-1.10/lib/unistd.in.h Examining data/gzip-1.10/lib/sys_time.in.h Examining data/gzip-1.10/lib/printf-frexp.h Examining data/gzip-1.10/lib/getopt.in.h Examining data/gzip-1.10/lib/fdatasync.c Examining data/gzip-1.10/lib/itold.c Examining data/gzip-1.10/lib/sig-handler.h Examining data/gzip-1.10/lib/localtime-buffer.h Examining data/gzip-1.10/lib/alloca.in.h Examining data/gzip-1.10/lib/isnanl-nolibm.h Examining data/gzip-1.10/lib/msvc-inval.h Examining data/gzip-1.10/lib/malloca.h Examining data/gzip-1.10/lib/xalloc-die.c Examining data/gzip-1.10/lib/signbitf.c Examining data/gzip-1.10/lib/printf-parse.h Examining data/gzip-1.10/lib/filenamecat-lgpl.c Examining data/gzip-1.10/lib/dup2.c Examining data/gzip-1.10/lib/savedir.h Examining data/gzip-1.10/lib/memrchr.c Examining data/gzip-1.10/lib/vasnprintf.h Examining data/gzip-1.10/lib/isnand-nolibm.h Examining data/gzip-1.10/lib/dirent--.h Examining data/gzip-1.10/lib/msvc-inval.c Examining data/gzip-1.10/lib/verify.h Examining data/gzip-1.10/lib/fflush.c Examining data/gzip-1.10/lib/utime.in.h Examining data/gzip-1.10/lib/dirname.h Examining data/gzip-1.10/lib/fcntl--.h Examining data/gzip-1.10/lib/opendir-safer.c Examining data/gzip-1.10/lib/stat-w32.h Examining data/gzip-1.10/lib/gettime.c Examining data/gzip-1.10/lib/xsize.h Examining data/gzip-1.10/lib/warn-on-use.h Examining data/gzip-1.10/lib/sys_types.in.h Examining data/gzip-1.10/lib/cloexec.c Examining data/gzip-1.10/lib/unlinkat.c Examining data/gzip-1.10/lib/stripslash.c Examining data/gzip-1.10/lib/unistd--.h Examining data/gzip-1.10/lib/freading.c Examining data/gzip-1.10/lib/realloc.c Examining data/gzip-1.10/lib/signal.in.h Examining data/gzip-1.10/lib/stdnoreturn.in.h Examining data/gzip-1.10/lib/unistd-safer.h Examining data/gzip-1.10/lib/strerror_r.c Examining data/gzip-1.10/lib/wchar.in.h Examining data/gzip-1.10/lib/mempcpy.c Examining data/gzip-1.10/tailor.h Examining data/gzip-1.10/deflate.c Examining data/gzip-1.10/bits.c Examining data/gzip-1.10/revision.h Examining data/gzip-1.10/trees.c Examining data/gzip-1.10/gzip.h Examining data/gzip-1.10/inflate.c Examining data/gzip-1.10/lzw.h Examining data/gzip-1.10/unlzh.c Examining data/gzip-1.10/unpack.c Examining data/gzip-1.10/util.c Examining data/gzip-1.10/gzip.c FINAL RESULTS: data/gzip-1.10/gzip.c:1930:17: [5] (race) chown: This accepts filename arguments; if an attacker can move those files, a race condition results. (CWE-362). Use fchown( ) instead. ignore_value (chown (name, uid, gid)); data/gzip-1.10/gzip.c:1985:9: [5] (race) chmod: This accepts filename arguments; if an attacker can move those files, a race condition results. (CWE-362). Use fchmod( ) instead. r = chmod (ofname, mode); data/gzip-1.10/lib/stdio.in.h:745:8: [5] (buffer) gets: Does not check for buffer overflows (CWE-120, CWE-20). Use fgets() instead. #undef gets data/gzip-1.10/lib/stdio.in.h:747:18: [5] (buffer) gets: Does not check for buffer overflows (CWE-120, CWE-20). Use fgets() instead. _GL_WARN_ON_USE (gets, "gets is a security hole - use fgets instead"); data/gzip-1.10/lib/sys_stat.in.h:507:19: [5] (race) chmod: This accepts filename arguments; if an attacker can move those files, a race condition results. (CWE-362). Use fchmod( ) instead. # define lchmod chmod data/gzip-1.10/lib/sys_stat.in.h:511:34: [5] (race) chmod: This accepts filename arguments; if an attacker can move those files, a race condition results. (CWE-362). Use fchmod( ) instead. _GL_CXXALIAS_RPL_CAST_1 (lchmod, chmod, int, data/gzip-1.10/lib/unistd.in.h:263:18: [5] (race) chown: This accepts filename arguments; if an attacker can move those files, a race condition results. (CWE-362). Use fchown( ) instead. _GL_WARN_ON_USE (chown, "chdir is not always in <unistd.h> - " data/gzip-1.10/lib/unistd.in.h:277:11: [5] (race) chown: This accepts filename arguments; if an attacker can move those files, a race condition results. (CWE-362). Use fchown( ) instead. # undef chown data/gzip-1.10/lib/unistd.in.h:278:12: [5] (race) chown: This accepts filename arguments; if an attacker can move those files, a race condition results. (CWE-362). Use fchown( ) instead. # define chown rpl_chown data/gzip-1.10/lib/unistd.in.h:280:19: [5] (race) chown: This accepts filename arguments; if an attacker can move those files, a race condition results. (CWE-362). Use fchown( ) instead. _GL_FUNCDECL_RPL (chown, int, (const char *file, uid_t uid, gid_t gid) data/gzip-1.10/lib/unistd.in.h:282:19: [5] (race) chown: This accepts filename arguments; if an attacker can move those files, a race condition results. (CWE-362). Use fchown( ) instead. _GL_CXXALIAS_RPL (chown, int, (const char *file, uid_t uid, gid_t gid)); data/gzip-1.10/lib/unistd.in.h:285:19: [5] (race) chown: This accepts filename arguments; if an attacker can move those files, a race condition results. (CWE-362). Use fchown( ) instead. _GL_FUNCDECL_SYS (chown, int, (const char *file, uid_t uid, gid_t gid) data/gzip-1.10/lib/unistd.in.h:288:19: [5] (race) chown: This accepts filename arguments; if an attacker can move those files, a race condition results. (CWE-362). Use fchown( ) instead. _GL_CXXALIAS_SYS (chown, int, (const char *file, uid_t uid, gid_t gid)); data/gzip-1.10/lib/unistd.in.h:290:19: [5] (race) chown: This accepts filename arguments; if an attacker can move those files, a race condition results. (CWE-362). Use fchown( ) instead. _GL_CXXALIASWARN (chown); data/gzip-1.10/lib/unistd.in.h:292:9: [5] (race) chown: This accepts filename arguments; if an attacker can move those files, a race condition results. (CWE-362). Use fchown( ) instead. # undef chown data/gzip-1.10/lib/unistd.in.h:294:18: [5] (race) chown: This accepts filename arguments; if an attacker can move those files, a race condition results. (CWE-362). Use fchown( ) instead. _GL_WARN_ON_USE (chown, "chown fails to follow symlinks on some systems and " data/gzip-1.10/lib/unistd.in.h:1321:12: [5] (race) readlink: This accepts filename arguments; if an attacker can move those files or change the link content, a race condition results. Also, it does not terminate with ASCII NUL. (CWE-362, CWE-20). Reconsider approach. # define readlink rpl_readlink data/gzip-1.10/lib/unistd.in.h:1323:19: [5] (race) readlink: This accepts filename arguments; if an attacker can move those files or change the link content, a race condition results. Also, it does not terminate with ASCII NUL. (CWE-362, CWE-20). Reconsider approach. _GL_FUNCDECL_RPL (readlink, ssize_t, data/gzip-1.10/lib/unistd.in.h:1326:19: [5] (race) readlink: This accepts filename arguments; if an attacker can move those files or change the link content, a race condition results. Also, it does not terminate with ASCII NUL. (CWE-362, CWE-20). Reconsider approach. _GL_CXXALIAS_RPL (readlink, ssize_t, data/gzip-1.10/lib/unistd.in.h:1330:19: [5] (race) readlink: This accepts filename arguments; if an attacker can move those files or change the link content, a race condition results. Also, it does not terminate with ASCII NUL. (CWE-362, CWE-20). Reconsider approach. _GL_FUNCDECL_SYS (readlink, ssize_t, data/gzip-1.10/lib/unistd.in.h:1334:19: [5] (race) readlink: This accepts filename arguments; if an attacker can move those files or change the link content, a race condition results. Also, it does not terminate with ASCII NUL. (CWE-362, CWE-20). Reconsider approach. _GL_CXXALIAS_SYS (readlink, ssize_t, data/gzip-1.10/lib/unistd.in.h:1337:19: [5] (race) readlink: This accepts filename arguments; if an attacker can move those files or change the link content, a race condition results. Also, it does not terminate with ASCII NUL. (CWE-362, CWE-20). Reconsider approach. _GL_CXXALIASWARN (readlink); data/gzip-1.10/lib/unistd.in.h:1339:9: [5] (race) readlink: This accepts filename arguments; if an attacker can move those files or change the link content, a race condition results. Also, it does not terminate with ASCII NUL. (CWE-362, CWE-20). Reconsider approach. # undef readlink data/gzip-1.10/lib/unistd.in.h:1341:18: [5] (race) readlink: This accepts filename arguments; if an attacker can move those files or change the link content, a race condition results. Also, it does not terminate with ASCII NUL. (CWE-362, CWE-20). Reconsider approach. _GL_WARN_ON_USE (readlink, "readlink is unportable - " data/gzip-1.10/util.c:320:11: [5] (race) chmod: This accepts filename arguments; if an attacker can move those files, a race condition results. (CWE-362). Use fchmod( ) instead. if (chmod (filename, S_IWUSR) != 0) data/gzip-1.10/gzip.c:476:25: [4] (format) fprintf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. fprintf (stderr, data/gzip-1.10/gzip.c:486:23: [4] (format) fprintf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. fprintf (stderr, data/gzip-1.10/gzip.c:607:17: [4] (format) fprintf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. fprintf (stderr, ("option not valid in "OPTIONS_VAR data/gzip-1.10/gzip.c:747:11: [4] (format) fprintf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. fprintf (stderr, data/gzip-1.10/gzip.c:1204:9: [4] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). strcpy(suffix, name); data/gzip-1.10/gzip.c:1206:9: [4] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). strcpy(suffix, name+nlen-MAX_SUFFIX-2); data/gzip-1.10/gzip.c:1306:5: [4] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). strcpy(ifname, iname); data/gzip-1.10/gzip.c:1336:9: [4] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). strcpy (ifname, iname); data/gzip-1.10/gzip.c:1347:9: [4] (buffer) strcat: Does not check for buffer overflows when concatenating to destination [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or snprintf (warning: strncat is easily misused). strcat(ifname, s); data/gzip-1.10/gzip.c:1361:5: [4] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). strcpy(ifname, iname); data/gzip-1.10/gzip.c:1369:5: [4] (buffer) strcat: Does not check for buffer overflows when concatenating to destination [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or snprintf (warning: strncat is easily misused). strcat(ifname, z_suffix); data/gzip-1.10/gzip.c:1388:5: [4] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). strcpy(ofname, ifname); data/gzip-1.10/gzip.c:1451:9: [4] (buffer) strcat: Does not check for buffer overflows when concatenating to destination [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or snprintf (warning: strncat is easily misused). strcat(ofname, z_suffix); data/gzip-1.10/gzip.c:1885:5: [4] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). strcpy(trunc, z_suffix); data/gzip-1.10/gzip.c:2036:13: [4] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). strcpy(nbuf,dir); data/gzip-1.10/gzip.c:2039:13: [4] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). strcpy (nbuf + len, entry); data/gzip-1.10/gzip.h:243:20: [4] (format) fprintf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. # define Trace(x) fprintf x data/gzip-1.10/gzip.h:244:35: [4] (format) fprintf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. # define Tracev(x) {if (verbose) fprintf x ;} data/gzip-1.10/gzip.h:245:38: [4] (format) fprintf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. # define Tracevv(x) {if (verbose>1) fprintf x ;} data/gzip-1.10/gzip.h:246:44: [4] (format) fprintf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. # define Tracec(c,x) {if (verbose && (c)) fprintf x ;} data/gzip-1.10/gzip.h:247:47: [4] (format) fprintf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. # define Tracecv(c,x) {if (verbose>1 && (c)) fprintf x ;} data/gzip-1.10/gzip.h:257:32: [4] (format) fprintf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. #define WARN(msg) {if (!quiet) fprintf msg ; \ data/gzip-1.10/lib/chdir-long.c:249:7: [4] (shell) execlp: This causes a new program to execute and is difficult to use safely (CWE-78). try using a library call that implements the same functionality if available. execlp (cmd, (char *) NULL); data/gzip-1.10/lib/error.c:274:5: [4] (format) vfprintf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. vfprintf (stderr, message, args); data/gzip-1.10/lib/error.c:389:3: [4] (format) fprintf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. fprintf (stderr, file_name != NULL ? "%s:%u: " : " ", data/gzip-1.10/lib/fprintf.c:36:1: [4] (format) fprintf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. fprintf (FILE *fp, const char *format, ...) data/gzip-1.10/lib/getopt.c:40:10: [4] (format) fprintf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. # define fprintf __fxprintf_nocancel data/gzip-1.10/lib/openat-proc.c:88:13: [4] (format) sprintf: Potential format string problem (CWE-134). Make format string constant. sprintf (dotdot_buf, PROC_SELF_FD_FORMAT "../fd", proc_self_fd); data/gzip-1.10/lib/openat-proc.c:89:27: [4] (race) access: This usually indicates a security flaw. If an attacker can change anything along the path between the call to access() and the file's actual use (e.g., by moving files), the attacker can exploit the race condition (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid()) and try to open the file directly. proc_status = access (dotdot_buf, F_OK) ? -1 : 1; data/gzip-1.10/lib/openat-proc.c:106:18: [4] (format) sprintf: Potential format string problem (CWE-134). Make format string constant. dirlen = sprintf (result, PROC_SELF_FD_FORMAT, fd); data/gzip-1.10/lib/openat-proc.c:127:5: [4] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). strcpy (result, dir); data/gzip-1.10/lib/openat-proc.c:132:3: [4] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). strcpy (result + dirlen, file); data/gzip-1.10/lib/opendir.c:151:3: [4] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). strcpy (dirp->dir_name_mask, dir_name_mask); data/gzip-1.10/lib/perror.c:30:8: [4] (format) fprintf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. #undef fprintf data/gzip-1.10/lib/printf.c:30:1: [4] (format) printf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. printf (const char *format, ...) data/gzip-1.10/lib/printf.c:36:12: [4] (format) vfprintf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. retval = vfprintf (stdout, format, args); data/gzip-1.10/lib/stdio.in.h:304:12: [4] (format) fprintf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. # define fprintf rpl_fprintf data/gzip-1.10/lib/stdio.in.h:308:19: [4] (format) fprintf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. _GL_FUNCDECL_RPL (fprintf, int, (FILE *fp, const char *format, ...) data/gzip-1.10/lib/stdio.in.h:312:19: [4] (format) fprintf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. _GL_FUNCDECL_RPL (fprintf, int, (FILE *fp, const char *format, ...) data/gzip-1.10/lib/stdio.in.h:316:19: [4] (format) fprintf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. _GL_CXXALIAS_RPL (fprintf, int, (FILE *fp, const char *format, ...)); data/gzip-1.10/lib/stdio.in.h:318:19: [4] (format) fprintf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. _GL_CXXALIAS_SYS (fprintf, int, (FILE *fp, const char *format, ...)); data/gzip-1.10/lib/stdio.in.h:320:19: [4] (format) fprintf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. _GL_CXXALIASWARN (fprintf); data/gzip-1.10/lib/stdio.in.h:324:10: [4] (format) fprintf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. # undef fprintf data/gzip-1.10/lib/stdio.in.h:327:18: [4] (format) fprintf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. _GL_WARN_ON_USE (fprintf, "fprintf is not always POSIX compliant - " data/gzip-1.10/lib/stdio.in.h:431:11: [4] (buffer) fscanf: The scanf() family's %s operation, without a limit specification, permits buffer overflows (CWE-120, CWE-20). Specify a limit to %s, or use a different input function. # undef fscanf data/gzip-1.10/lib/stdio.in.h:432:12: [4] (buffer) fscanf: The scanf() family's %s operation, without a limit specification, permits buffer overflows (CWE-120, CWE-20). Specify a limit to %s, or use a different input function. # define fscanf rpl_fscanf data/gzip-1.10/lib/stdio.in.h:434:19: [4] (buffer) fscanf: The scanf() family's %s operation, without a limit specification, permits buffer overflows (CWE-120, CWE-20). Specify a limit to %s, or use a different input function. _GL_FUNCDECL_RPL (fscanf, int, (FILE *stream, const char *format, ...) data/gzip-1.10/lib/stdio.in.h:437:19: [4] (buffer) fscanf: The scanf() family's %s operation, without a limit specification, permits buffer overflows (CWE-120, CWE-20). Specify a limit to %s, or use a different input function. _GL_CXXALIAS_RPL (fscanf, int, (FILE *stream, const char *format, ...)); data/gzip-1.10/lib/stdio.in.h:439:19: [4] (buffer) fscanf: The scanf() family's %s operation, without a limit specification, permits buffer overflows (CWE-120, CWE-20). Specify a limit to %s, or use a different input function. _GL_CXXALIAS_SYS (fscanf, int, (FILE *stream, const char *format, ...)); data/gzip-1.10/lib/stdio.in.h:441:19: [4] (buffer) fscanf: The scanf() family's %s operation, without a limit specification, permits buffer overflows (CWE-120, CWE-20). Specify a limit to %s, or use a different input function. _GL_CXXALIASWARN (fscanf); data/gzip-1.10/lib/stdio.in.h:839:11: [4] (shell) popen: This causes a new program to execute and is difficult to use safely (CWE-78). try using a library call that implements the same functionality if available. # undef popen data/gzip-1.10/lib/stdio.in.h:840:12: [4] (shell) popen: This causes a new program to execute and is difficult to use safely (CWE-78). try using a library call that implements the same functionality if available. # define popen rpl_popen data/gzip-1.10/lib/stdio.in.h:842:19: [4] (shell) popen: This causes a new program to execute and is difficult to use safely (CWE-78). try using a library call that implements the same functionality if available. _GL_FUNCDECL_RPL (popen, FILE *, (const char *cmd, const char *mode) data/gzip-1.10/lib/stdio.in.h:844:19: [4] (shell) popen: This causes a new program to execute and is difficult to use safely (CWE-78). try using a library call that implements the same functionality if available. _GL_CXXALIAS_RPL (popen, FILE *, (const char *cmd, const char *mode)); data/gzip-1.10/lib/stdio.in.h:847:19: [4] (shell) popen: This causes a new program to execute and is difficult to use safely (CWE-78). try using a library call that implements the same functionality if available. _GL_FUNCDECL_SYS (popen, FILE *, (const char *cmd, const char *mode) data/gzip-1.10/lib/stdio.in.h:850:19: [4] (shell) popen: This causes a new program to execute and is difficult to use safely (CWE-78). try using a library call that implements the same functionality if available. _GL_CXXALIAS_SYS (popen, FILE *, (const char *cmd, const char *mode)); data/gzip-1.10/lib/stdio.in.h:852:19: [4] (shell) popen: This causes a new program to execute and is difficult to use safely (CWE-78). try using a library call that implements the same functionality if available. _GL_CXXALIASWARN (popen); data/gzip-1.10/lib/stdio.in.h:854:9: [4] (shell) popen: This causes a new program to execute and is difficult to use safely (CWE-78). try using a library call that implements the same functionality if available. # undef popen data/gzip-1.10/lib/stdio.in.h:856:18: [4] (shell) popen: This causes a new program to execute and is difficult to use safely (CWE-78). try using a library call that implements the same functionality if available. _GL_WARN_ON_USE (popen, "popen is buggy on some platforms - " data/gzip-1.10/lib/stdio.in.h:867:13: [4] (format) printf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. # define printf __printf__ data/gzip-1.10/lib/stdio.in.h:884:21: [4] (format) printf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. _GL_CXXALIAS_RPL_1 (printf, __printf__, int, (const char *format, ...)); data/gzip-1.10/lib/stdio.in.h:887:13: [4] (format) printf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. # define printf rpl_printf data/gzip-1.10/lib/stdio.in.h:889:19: [4] (format) printf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. _GL_FUNCDECL_RPL (printf, int, data/gzip-1.10/lib/stdio.in.h:893:19: [4] (format) printf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. _GL_CXXALIAS_RPL (printf, int, (const char *format, ...)); data/gzip-1.10/lib/stdio.in.h:897:19: [4] (format) printf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. _GL_CXXALIAS_SYS (printf, int, (const char *format, ...)); data/gzip-1.10/lib/stdio.in.h:899:19: [4] (format) printf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. _GL_CXXALIASWARN (printf); data/gzip-1.10/lib/stdio.in.h:903:10: [4] (format) printf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. # undef printf data/gzip-1.10/lib/stdio.in.h:906:18: [4] (format) printf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. _GL_WARN_ON_USE (printf, "printf is not always POSIX compliant - " data/gzip-1.10/lib/stdio.in.h:1028:12: [4] (buffer) scanf: The scanf() family's %s operation, without a limit specification, permits buffer overflows (CWE-120, CWE-20). Specify a limit to %s, or use a different input function. # undef scanf data/gzip-1.10/lib/stdio.in.h:1030:13: [4] (buffer) scanf: The scanf() family's %s operation, without a limit specification, permits buffer overflows (CWE-120, CWE-20). Specify a limit to %s, or use a different input function. # define scanf __scanf__ data/gzip-1.10/lib/stdio.in.h:1038:21: [4] (buffer) scanf: The scanf() family's %s operation, without a limit specification, permits buffer overflows (CWE-120, CWE-20). Specify a limit to %s, or use a different input function. _GL_CXXALIAS_RPL_1 (scanf, __scanf__, int, (const char *format, ...)); data/gzip-1.10/lib/stdio.in.h:1041:12: [4] (buffer) scanf: The scanf() family's %s operation, without a limit specification, permits buffer overflows (CWE-120, CWE-20). Specify a limit to %s, or use a different input function. # undef scanf data/gzip-1.10/lib/stdio.in.h:1042:13: [4] (buffer) scanf: The scanf() family's %s operation, without a limit specification, permits buffer overflows (CWE-120, CWE-20). Specify a limit to %s, or use a different input function. # define scanf rpl_scanf data/gzip-1.10/lib/stdio.in.h:1044:19: [4] (buffer) scanf: The scanf() family's %s operation, without a limit specification, permits buffer overflows (CWE-120, CWE-20). Specify a limit to %s, or use a different input function. _GL_FUNCDECL_RPL (scanf, int, (const char *format, ...) data/gzip-1.10/lib/stdio.in.h:1047:19: [4] (buffer) scanf: The scanf() family's %s operation, without a limit specification, permits buffer overflows (CWE-120, CWE-20). Specify a limit to %s, or use a different input function. _GL_CXXALIAS_RPL (scanf, int, (const char *format, ...)); data/gzip-1.10/lib/stdio.in.h:1050:19: [4] (buffer) scanf: The scanf() family's %s operation, without a limit specification, permits buffer overflows (CWE-120, CWE-20). Specify a limit to %s, or use a different input function. _GL_CXXALIAS_SYS (scanf, int, (const char *format, ...)); data/gzip-1.10/lib/stdio.in.h:1052:19: [4] (buffer) scanf: The scanf() family's %s operation, without a limit specification, permits buffer overflows (CWE-120, CWE-20). Specify a limit to %s, or use a different input function. _GL_CXXALIASWARN (scanf); data/gzip-1.10/lib/stdio.in.h:1058:12: [4] (format) snprintf: If format strings can be influenced by an attacker, they can be exploited, and note that sprintf variations do not always \0-terminate (CWE-134). Use a constant for the format specification. # define snprintf rpl_snprintf data/gzip-1.10/lib/stdio.in.h:1060:19: [4] (format) snprintf: If format strings can be influenced by an attacker, they can be exploited, and note that sprintf variations do not always \0-terminate (CWE-134). Use a constant for the format specification. _GL_FUNCDECL_RPL (snprintf, int, data/gzip-1.10/lib/stdio.in.h:1064:19: [4] (format) snprintf: If format strings can be influenced by an attacker, they can be exploited, and note that sprintf variations do not always \0-terminate (CWE-134). Use a constant for the format specification. _GL_CXXALIAS_RPL (snprintf, int, data/gzip-1.10/lib/stdio.in.h:1068:19: [4] (format) snprintf: If format strings can be influenced by an attacker, they can be exploited, and note that sprintf variations do not always \0-terminate (CWE-134). Use a constant for the format specification. _GL_FUNCDECL_SYS (snprintf, int, data/gzip-1.10/lib/stdio.in.h:1073:19: [4] (format) snprintf: If format strings can be influenced by an attacker, they can be exploited, and note that sprintf variations do not always \0-terminate (CWE-134). Use a constant for the format specification. _GL_CXXALIAS_SYS (snprintf, int, data/gzip-1.10/lib/stdio.in.h:1076:19: [4] (format) snprintf: If format strings can be influenced by an attacker, they can be exploited, and note that sprintf variations do not always \0-terminate (CWE-134). Use a constant for the format specification. _GL_CXXALIASWARN (snprintf); data/gzip-1.10/lib/stdio.in.h:1078:9: [4] (format) snprintf: If format strings can be influenced by an attacker, they can be exploited, and note that sprintf variations do not always \0-terminate (CWE-134). Use a constant for the format specification. # undef snprintf data/gzip-1.10/lib/stdio.in.h:1080:18: [4] (format) snprintf: If format strings can be influenced by an attacker, they can be exploited, and note that sprintf variations do not always \0-terminate (CWE-134). Use a constant for the format specification. _GL_WARN_ON_USE (snprintf, "snprintf is unportable - " data/gzip-1.10/lib/stdio.in.h:1097:12: [4] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. # define sprintf rpl_sprintf data/gzip-1.10/lib/stdio.in.h:1099:19: [4] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. _GL_FUNCDECL_RPL (sprintf, int, (char *str, const char *format, ...) data/gzip-1.10/lib/stdio.in.h:1102:19: [4] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. _GL_CXXALIAS_RPL (sprintf, int, (char *str, const char *format, ...)); data/gzip-1.10/lib/stdio.in.h:1104:19: [4] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. _GL_CXXALIAS_SYS (sprintf, int, (char *str, const char *format, ...)); data/gzip-1.10/lib/stdio.in.h:1106:19: [4] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. _GL_CXXALIASWARN (sprintf); data/gzip-1.10/lib/stdio.in.h:1108:9: [4] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. # undef sprintf data/gzip-1.10/lib/stdio.in.h:1110:18: [4] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. _GL_WARN_ON_USE (sprintf, "sprintf is not always POSIX compliant - " data/gzip-1.10/lib/stdio.in.h:1216:12: [4] (format) vfprintf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. # define vfprintf rpl_vfprintf data/gzip-1.10/lib/stdio.in.h:1220:19: [4] (format) vfprintf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. _GL_FUNCDECL_RPL (vfprintf, int, (FILE *fp, const char *format, va_list args) data/gzip-1.10/lib/stdio.in.h:1224:19: [4] (format) vfprintf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. _GL_FUNCDECL_RPL (vfprintf, int, (FILE *fp, const char *format, va_list args) data/gzip-1.10/lib/stdio.in.h:1228:19: [4] (format) vfprintf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. _GL_CXXALIAS_RPL (vfprintf, int, (FILE *fp, const char *format, va_list args)); data/gzip-1.10/lib/stdio.in.h:1233:24: [4] (format) vfprintf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. _GL_CXXALIAS_SYS_CAST (vfprintf, int, data/gzip-1.10/lib/stdio.in.h:1236:19: [4] (format) vfprintf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. _GL_CXXALIASWARN (vfprintf); data/gzip-1.10/lib/stdio.in.h:1240:10: [4] (format) vfprintf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. # undef vfprintf data/gzip-1.10/lib/stdio.in.h:1243:18: [4] (format) vfprintf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. _GL_WARN_ON_USE (vfprintf, "vfprintf is not always POSIX compliant - " data/gzip-1.10/lib/stdio.in.h:1251:11: [4] (buffer) vfscanf: The scanf() family's %s operation, without a limit specification, permits buffer overflows (CWE-120, CWE-20). Specify a limit to %s, or use a different input function. # undef vfscanf data/gzip-1.10/lib/stdio.in.h:1252:12: [4] (buffer) vfscanf: The scanf() family's %s operation, without a limit specification, permits buffer overflows (CWE-120, CWE-20). Specify a limit to %s, or use a different input function. # define vfscanf rpl_vfscanf data/gzip-1.10/lib/stdio.in.h:1254:19: [4] (buffer) vfscanf: The scanf() family's %s operation, without a limit specification, permits buffer overflows (CWE-120, CWE-20). Specify a limit to %s, or use a different input function. _GL_FUNCDECL_RPL (vfscanf, int, data/gzip-1.10/lib/stdio.in.h:1258:19: [4] (buffer) vfscanf: The scanf() family's %s operation, without a limit specification, permits buffer overflows (CWE-120, CWE-20). Specify a limit to %s, or use a different input function. _GL_CXXALIAS_RPL (vfscanf, int, data/gzip-1.10/lib/stdio.in.h:1261:19: [4] (buffer) vfscanf: The scanf() family's %s operation, without a limit specification, permits buffer overflows (CWE-120, CWE-20). Specify a limit to %s, or use a different input function. _GL_CXXALIAS_SYS (vfscanf, int, data/gzip-1.10/lib/stdio.in.h:1264:19: [4] (buffer) vfscanf: The scanf() family's %s operation, without a limit specification, permits buffer overflows (CWE-120, CWE-20). Specify a limit to %s, or use a different input function. _GL_CXXALIASWARN (vfscanf); data/gzip-1.10/lib/stdio.in.h:1271:12: [4] (format) vprintf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. # define vprintf rpl_vprintf data/gzip-1.10/lib/stdio.in.h:1275:19: [4] (format) vprintf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. _GL_FUNCDECL_RPL (vprintf, int, (const char *format, va_list args) data/gzip-1.10/lib/stdio.in.h:1279:19: [4] (format) vprintf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. _GL_FUNCDECL_RPL (vprintf, int, (const char *format, va_list args) data/gzip-1.10/lib/stdio.in.h:1283:19: [4] (format) vprintf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. _GL_CXXALIAS_RPL (vprintf, int, (const char *format, va_list args)); data/gzip-1.10/lib/stdio.in.h:1288:24: [4] (format) vprintf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. _GL_CXXALIAS_SYS_CAST (vprintf, int, (const char *format, va_list args)); data/gzip-1.10/lib/stdio.in.h:1290:19: [4] (format) vprintf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. _GL_CXXALIASWARN (vprintf); data/gzip-1.10/lib/stdio.in.h:1294:10: [4] (format) vprintf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. # undef vprintf data/gzip-1.10/lib/stdio.in.h:1297:18: [4] (format) vprintf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. _GL_WARN_ON_USE (vprintf, "vprintf is not always POSIX compliant - " data/gzip-1.10/lib/stdio.in.h:1305:11: [4] (buffer) vscanf: The scanf() family's %s operation, without a limit specification, permits buffer overflows (CWE-120, CWE-20). Specify a limit to %s, or use a different input function. # undef vscanf data/gzip-1.10/lib/stdio.in.h:1306:12: [4] (buffer) vscanf: The scanf() family's %s operation, without a limit specification, permits buffer overflows (CWE-120, CWE-20). Specify a limit to %s, or use a different input function. # define vscanf rpl_vscanf data/gzip-1.10/lib/stdio.in.h:1308:19: [4] (buffer) vscanf: The scanf() family's %s operation, without a limit specification, permits buffer overflows (CWE-120, CWE-20). Specify a limit to %s, or use a different input function. _GL_FUNCDECL_RPL (vscanf, int, (const char *format, va_list args) data/gzip-1.10/lib/stdio.in.h:1311:19: [4] (buffer) vscanf: The scanf() family's %s operation, without a limit specification, permits buffer overflows (CWE-120, CWE-20). Specify a limit to %s, or use a different input function. _GL_CXXALIAS_RPL (vscanf, int, (const char *format, va_list args)); data/gzip-1.10/lib/stdio.in.h:1313:19: [4] (buffer) vscanf: The scanf() family's %s operation, without a limit specification, permits buffer overflows (CWE-120, CWE-20). Specify a limit to %s, or use a different input function. _GL_CXXALIAS_SYS (vscanf, int, (const char *format, va_list args)); data/gzip-1.10/lib/stdio.in.h:1315:19: [4] (buffer) vscanf: The scanf() family's %s operation, without a limit specification, permits buffer overflows (CWE-120, CWE-20). Specify a limit to %s, or use a different input function. _GL_CXXALIASWARN (vscanf); data/gzip-1.10/lib/stdio.in.h:1321:12: [4] (format) vsnprintf: If format strings can be influenced by an attacker, they can be exploited, and note that sprintf variations do not always \0-terminate (CWE-134). Use a constant for the format specification. # define vsnprintf rpl_vsnprintf data/gzip-1.10/lib/stdio.in.h:1323:19: [4] (format) vsnprintf: If format strings can be influenced by an attacker, they can be exploited, and note that sprintf variations do not always \0-terminate (CWE-134). Use a constant for the format specification. _GL_FUNCDECL_RPL (vsnprintf, int, data/gzip-1.10/lib/stdio.in.h:1327:19: [4] (format) vsnprintf: If format strings can be influenced by an attacker, they can be exploited, and note that sprintf variations do not always \0-terminate (CWE-134). Use a constant for the format specification. _GL_CXXALIAS_RPL (vsnprintf, int, data/gzip-1.10/lib/stdio.in.h:1331:19: [4] (format) vsnprintf: If format strings can be influenced by an attacker, they can be exploited, and note that sprintf variations do not always \0-terminate (CWE-134). Use a constant for the format specification. _GL_FUNCDECL_SYS (vsnprintf, int, data/gzip-1.10/lib/stdio.in.h:1336:19: [4] (format) vsnprintf: If format strings can be influenced by an attacker, they can be exploited, and note that sprintf variations do not always \0-terminate (CWE-134). Use a constant for the format specification. _GL_CXXALIAS_SYS (vsnprintf, int, data/gzip-1.10/lib/stdio.in.h:1339:19: [4] (format) vsnprintf: If format strings can be influenced by an attacker, they can be exploited, and note that sprintf variations do not always \0-terminate (CWE-134). Use a constant for the format specification. _GL_CXXALIASWARN (vsnprintf); data/gzip-1.10/lib/stdio.in.h:1341:9: [4] (format) vsnprintf: If format strings can be influenced by an attacker, they can be exploited, and note that sprintf variations do not always \0-terminate (CWE-134). Use a constant for the format specification. # undef vsnprintf data/gzip-1.10/lib/stdio.in.h:1343:18: [4] (format) vsnprintf: If format strings can be influenced by an attacker, they can be exploited, and note that sprintf variations do not always \0-terminate (CWE-134). Use a constant for the format specification. _GL_WARN_ON_USE (vsnprintf, "vsnprintf is unportable - " data/gzip-1.10/lib/stdio.in.h:1351:12: [4] (buffer) vsprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. # define vsprintf rpl_vsprintf data/gzip-1.10/lib/stdio.in.h:1353:19: [4] (buffer) vsprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. _GL_FUNCDECL_RPL (vsprintf, int, data/gzip-1.10/lib/stdio.in.h:1357:19: [4] (buffer) vsprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. _GL_CXXALIAS_RPL (vsprintf, int, data/gzip-1.10/lib/stdio.in.h:1363:24: [4] (buffer) vsprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. _GL_CXXALIAS_SYS_CAST (vsprintf, int, data/gzip-1.10/lib/stdio.in.h:1366:19: [4] (buffer) vsprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. _GL_CXXALIASWARN (vsprintf); data/gzip-1.10/lib/stdio.in.h:1368:9: [4] (buffer) vsprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. # undef vsprintf data/gzip-1.10/lib/stdio.in.h:1370:18: [4] (buffer) vsprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. _GL_WARN_ON_USE (vsprintf, "vsprintf is not always POSIX compliant - " data/gzip-1.10/lib/strerror.c:33:8: [4] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. #undef sprintf data/gzip-1.10/lib/strerror.c:59:7: [4] (format) sprintf: Potential format string problem (CWE-134). Make format string constant. sprintf (buf, fmt, n); data/gzip-1.10/lib/strerror_r.c:123:10: [4] (format) snprintf: If format strings can be influenced by an attacker, they can be exploited, and note that sprintf variations do not always \0-terminate (CWE-134). Use a constant for the format specification. # define snprintf local_snprintf data/gzip-1.10/lib/unistd.in.h:252:18: [4] (race) access: This usually indicates a security flaw. If an attacker can change anything along the path between the call to access() and the file's actual use (e.g., by moving files), the attacker can exploit the race condition (CWE-362/CWE-367!). Set up the correct permissions (e.g., using setuid()) and try to open the file directly. _GL_WARN_ON_USE (access, "the access function is a security risk - " data/gzip-1.10/lib/unistd.in.h:802:19: [4] (misc) getlogin: It's often easy to fool getlogin. Sometimes it does not work at all, because some program messed up the utmp file. Often, it gives only the first 8 characters of the login name. The user currently logged in on the controlling tty of our program need not be the user who started it. Avoid getlogin() for security-related purposes (CWE-807). Use getpwuid(geteuid()) and extract the desired information instead. _GL_FUNCDECL_SYS (getlogin, char *, (void)); data/gzip-1.10/lib/unistd.in.h:804:19: [4] (misc) getlogin: It's often easy to fool getlogin. Sometimes it does not work at all, because some program messed up the utmp file. Often, it gives only the first 8 characters of the login name. The user currently logged in on the controlling tty of our program need not be the user who started it. Avoid getlogin() for security-related purposes (CWE-807). Use getpwuid(geteuid()) and extract the desired information instead. _GL_CXXALIAS_SYS (getlogin, char *, (void)); data/gzip-1.10/lib/unistd.in.h:805:19: [4] (misc) getlogin: It's often easy to fool getlogin. Sometimes it does not work at all, because some program messed up the utmp file. Often, it gives only the first 8 characters of the login name. The user currently logged in on the controlling tty of our program need not be the user who started it. Avoid getlogin() for security-related purposes (CWE-807). Use getpwuid(geteuid()) and extract the desired information instead. _GL_CXXALIASWARN (getlogin); data/gzip-1.10/lib/unistd.in.h:807:9: [4] (misc) getlogin: It's often easy to fool getlogin. Sometimes it does not work at all, because some program messed up the utmp file. Often, it gives only the first 8 characters of the login name. The user currently logged in on the controlling tty of our program need not be the user who started it. Avoid getlogin() for security-related purposes (CWE-807). Use getpwuid(geteuid()) and extract the desired information instead. # undef getlogin data/gzip-1.10/lib/unistd.in.h:809:18: [4] (misc) getlogin: It's often easy to fool getlogin. Sometimes it does not work at all, because some program messed up the utmp file. Often, it gives only the first 8 characters of the login name. The user currently logged in on the controlling tty of our program need not be the user who started it. Avoid getlogin() for security-related purposes (CWE-807). Use getpwuid(geteuid()) and extract the desired information instead. _GL_WARN_ON_USE (getlogin, "getlogin is unportable - " data/gzip-1.10/lib/unistd.in.h:945:11: [4] (misc) getpass: This function is obsolete and not portable. It was in SUSv2 but removed by POSIX.2. What it does exactly varies considerably between systems, particularly in where its prompt is displayed and where it gets its data (e.g., /dev/tty, stdin, stderr, etc.). In addition, some implementations overflow buffers. (CWE-676, CWE-120, CWE-20). Make the specific calls to do exactly what you want. If you continue to use it, or write your own, be sure to zero the password as soon as possible to avoid leaving the cleartext password visible in the process' address space. # undef getpass data/gzip-1.10/lib/unistd.in.h:946:12: [4] (misc) getpass: This function is obsolete and not portable. It was in SUSv2 but removed by POSIX.2. What it does exactly varies considerably between systems, particularly in where its prompt is displayed and where it gets its data (e.g., /dev/tty, stdin, stderr, etc.). In addition, some implementations overflow buffers. (CWE-676, CWE-120, CWE-20). Make the specific calls to do exactly what you want. If you continue to use it, or write your own, be sure to zero the password as soon as possible to avoid leaving the cleartext password visible in the process' address space. # define getpass rpl_getpass data/gzip-1.10/lib/unistd.in.h:948:19: [4] (misc) getpass: This function is obsolete and not portable. It was in SUSv2 but removed by POSIX.2. What it does exactly varies considerably between systems, particularly in where its prompt is displayed and where it gets its data (e.g., /dev/tty, stdin, stderr, etc.). In addition, some implementations overflow buffers. (CWE-676, CWE-120, CWE-20). Make the specific calls to do exactly what you want. If you continue to use it, or write your own, be sure to zero the password as soon as possible to avoid leaving the cleartext password visible in the process' address space. _GL_FUNCDECL_RPL (getpass, char *, (const char *prompt) data/gzip-1.10/lib/unistd.in.h:950:19: [4] (misc) getpass: This function is obsolete and not portable. It was in SUSv2 but removed by POSIX.2. What it does exactly varies considerably between systems, particularly in where its prompt is displayed and where it gets its data (e.g., /dev/tty, stdin, stderr, etc.). In addition, some implementations overflow buffers. (CWE-676, CWE-120, CWE-20). Make the specific calls to do exactly what you want. If you continue to use it, or write your own, be sure to zero the password as soon as possible to avoid leaving the cleartext password visible in the process' address space. _GL_CXXALIAS_RPL (getpass, char *, (const char *prompt)); data/gzip-1.10/lib/unistd.in.h:953:19: [4] (misc) getpass: This function is obsolete and not portable. It was in SUSv2 but removed by POSIX.2. What it does exactly varies considerably between systems, particularly in where its prompt is displayed and where it gets its data (e.g., /dev/tty, stdin, stderr, etc.). In addition, some implementations overflow buffers. (CWE-676, CWE-120, CWE-20). Make the specific calls to do exactly what you want. If you continue to use it, or write your own, be sure to zero the password as soon as possible to avoid leaving the cleartext password visible in the process' address space. _GL_FUNCDECL_SYS (getpass, char *, (const char *prompt) data/gzip-1.10/lib/unistd.in.h:956:19: [4] (misc) getpass: This function is obsolete and not portable. It was in SUSv2 but removed by POSIX.2. What it does exactly varies considerably between systems, particularly in where its prompt is displayed and where it gets its data (e.g., /dev/tty, stdin, stderr, etc.). In addition, some implementations overflow buffers. (CWE-676, CWE-120, CWE-20). Make the specific calls to do exactly what you want. If you continue to use it, or write your own, be sure to zero the password as soon as possible to avoid leaving the cleartext password visible in the process' address space. _GL_CXXALIAS_SYS (getpass, char *, (const char *prompt)); data/gzip-1.10/lib/unistd.in.h:958:19: [4] (misc) getpass: This function is obsolete and not portable. It was in SUSv2 but removed by POSIX.2. What it does exactly varies considerably between systems, particularly in where its prompt is displayed and where it gets its data (e.g., /dev/tty, stdin, stderr, etc.). In addition, some implementations overflow buffers. (CWE-676, CWE-120, CWE-20). Make the specific calls to do exactly what you want. If you continue to use it, or write your own, be sure to zero the password as soon as possible to avoid leaving the cleartext password visible in the process' address space. _GL_CXXALIASWARN (getpass); data/gzip-1.10/lib/unistd.in.h:960:9: [4] (misc) getpass: This function is obsolete and not portable. It was in SUSv2 but removed by POSIX.2. What it does exactly varies considerably between systems, particularly in where its prompt is displayed and where it gets its data (e.g., /dev/tty, stdin, stderr, etc.). In addition, some implementations overflow buffers. (CWE-676, CWE-120, CWE-20). Make the specific calls to do exactly what you want. If you continue to use it, or write your own, be sure to zero the password as soon as possible to avoid leaving the cleartext password visible in the process' address space. # undef getpass data/gzip-1.10/lib/unistd.in.h:962:18: [4] (misc) getpass: This function is obsolete and not portable. It was in SUSv2 but removed by POSIX.2. What it does exactly varies considerably between systems, particularly in where its prompt is displayed and where it gets its data (e.g., /dev/tty, stdin, stderr, etc.). In addition, some implementations overflow buffers. (CWE-676, CWE-120, CWE-20). Make the specific calls to do exactly what you want. If you continue to use it, or write your own, be sure to zero the password as soon as possible to avoid leaving the cleartext password visible in the process' address space. _GL_WARN_ON_USE (getpass, "getpass is unportable - " data/gzip-1.10/lib/vasnprintf.c:171:20: [4] (buffer) swprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. # define SNPRINTF swprintf data/gzip-1.10/lib/vasnprintf.c:189:21: [4] (format) snprintf: If format strings can be influenced by an attacker, they can be exploited, and note that sprintf variations do not always \0-terminate (CWE-134). Use a constant for the format specification. # define SNPRINTF snprintf data/gzip-1.10/lib/vasnprintf.c:191:11: [4] (format) snprintf: If format strings can be influenced by an attacker, they can be exploited, and note that sprintf variations do not always \0-terminate (CWE-134). Use a constant for the format specification. # undef snprintf data/gzip-1.10/lib/vasnprintf.c:194:21: [4] (format) _snprintf: If format strings can be influenced by an attacker, they can be exploited, and note that sprintf variations do not always \0-terminate (CWE-134). Use a constant for the format specification. # define SNPRINTF _snprintf data/gzip-1.10/lib/vasnprintf.c:199:20: [4] (format) snprintf: If format strings can be influenced by an attacker, they can be exploited, and note that sprintf variations do not always \0-terminate (CWE-134). Use a constant for the format specification. # define SNPRINTF snprintf data/gzip-1.10/lib/vasnprintf.c:201:10: [4] (format) snprintf: If format strings can be influenced by an attacker, they can be exploited, and note that sprintf variations do not always \0-terminate (CWE-134). Use a constant for the format specification. # undef snprintf data/gzip-1.10/lib/vasnprintf.c:205:8: [4] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. #undef sprintf data/gzip-1.10/lib/vasnprintf.c:4269:39: [4] (format) sprintf: Potential format string problem (CWE-134). Make format string constant. sprintf ((char *) p, decimal_format, exponent); data/gzip-1.10/lib/vasnprintf.c:4277:39: [4] (format) sprintf: Potential format string problem (CWE-134). Make format string constant. sprintf (expbuf, decimal_format, exponent); data/gzip-1.10/lib/vasnprintf.c:4462:47: [4] (format) sprintf: Potential format string problem (CWE-134). Make format string constant. sprintf ((char *) p, decimal_format, exponent); data/gzip-1.10/lib/vasnprintf.c:4470:47: [4] (format) sprintf: Potential format string problem (CWE-134). Make format string constant. sprintf (expbuf, decimal_format, exponent); data/gzip-1.10/lib/vasnprintf.c:4992:33: [4] (format) sprintf: Potential format string problem (CWE-134). Make format string constant. count = sprintf (tmp, buf, arg); \ data/gzip-1.10/lib/vasnprintf.c:4995:33: [4] (format) sprintf: Potential format string problem (CWE-134). Make format string constant. count = sprintf (tmp, buf, prefixes[0], arg); \ data/gzip-1.10/lib/vasnprintf.c:4998:33: [4] (format) sprintf: Potential format string problem (CWE-134). Make format string constant. count = sprintf (tmp, buf, prefixes[0], prefixes[1],\ data/gzip-1.10/lib/vfprintf.c:36:1: [4] (format) vfprintf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. vfprintf (FILE *fp, const char *format, va_list args) data/gzip-1.10/lib/wchar.in.h:607:19: [4] (buffer) wcscpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using a function version that stops copying at the end of the buffer. _GL_FUNCDECL_SYS (wcscpy, wchar_t *, (wchar_t *dest, const wchar_t *src)); data/gzip-1.10/lib/wchar.in.h:609:19: [4] (buffer) wcscpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using a function version that stops copying at the end of the buffer. _GL_CXXALIAS_SYS (wcscpy, wchar_t *, (wchar_t *dest, const wchar_t *src)); data/gzip-1.10/lib/wchar.in.h:610:19: [4] (buffer) wcscpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using a function version that stops copying at the end of the buffer. _GL_CXXALIASWARN (wcscpy); data/gzip-1.10/lib/wchar.in.h:612:9: [4] (buffer) wcscpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using a function version that stops copying at the end of the buffer. # undef wcscpy data/gzip-1.10/lib/wchar.in.h:614:18: [4] (buffer) wcscpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using a function version that stops copying at the end of the buffer. _GL_WARN_ON_USE (wcscpy, "wcscpy is unportable - " data/gzip-1.10/lib/wchar.in.h:676:19: [4] (buffer) wcscat: Does not check for buffer overflows when concatenating to destination [MS-banned] (CWE-120). _GL_FUNCDECL_SYS (wcscat, wchar_t *, (wchar_t *dest, const wchar_t *src)); data/gzip-1.10/lib/wchar.in.h:678:19: [4] (buffer) wcscat: Does not check for buffer overflows when concatenating to destination [MS-banned] (CWE-120). _GL_CXXALIAS_SYS (wcscat, wchar_t *, (wchar_t *dest, const wchar_t *src)); data/gzip-1.10/lib/wchar.in.h:679:19: [4] (buffer) wcscat: Does not check for buffer overflows when concatenating to destination [MS-banned] (CWE-120). _GL_CXXALIASWARN (wcscat); data/gzip-1.10/lib/wchar.in.h:681:9: [4] (buffer) wcscat: Does not check for buffer overflows when concatenating to destination [MS-banned] (CWE-120). # undef wcscat data/gzip-1.10/lib/wchar.in.h:683:18: [4] (buffer) wcscat: Does not check for buffer overflows when concatenating to destination [MS-banned] (CWE-120). _GL_WARN_ON_USE (wcscat, "wcscat is unportable - " data/gzip-1.10/sample/makecrc.c:56:5: [4] (format) printf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. printf(i % 5 ? ", 0x%08lxL" : ",\n 0x%08lxL", c); data/gzip-1.10/sample/zread.c:30:14: [4] (shell) popen: This causes a new program to execute and is difficult to use safely (CWE-78). try using a library call that implements the same functionality if available. infile = popen(cmd, "r"); /* use "w" for zwrite */ data/gzip-1.10/gzip.c:468:24: [3] (buffer) getopt_long: Some older implementations do not protect against internal buffer overflows (CWE-120, CWE-20). Check implementation on installation, or limit the size of all string inputs. optc = getopt_long (env_argc, env_argv, shortopts, longopts, data/gzip-1.10/gzip.c:501:18: [3] (buffer) getopt_long: Some older implementations do not protect against internal buffer overflows (CWE-120, CWE-20). Check implementation on installation, or limit the size of all string inputs. optc = getopt_long (argc, argv, shortopts, longopts, &longind); data/gzip-1.10/lib/getopt-core.h:91:12: [3] (buffer) getopt: Some older implementations do not protect against internal buffer overflows (CWE-120, CWE-20). Check implementation on installation, or limit the size of all string inputs. extern int getopt (int ___argc, char *const *___argv, const char *__shortopts) data/gzip-1.10/lib/getopt-ext.h:66:12: [3] (buffer) getopt_long: Some older implementations do not protect against internal buffer overflows (CWE-120, CWE-20). Check implementation on installation, or limit the size of all string inputs. extern int getopt_long (int ___argc, char *__getopt_argv_const *___argv, data/gzip-1.10/lib/getopt-pfx-core.h:40:9: [3] (buffer) getopt: Some older implementations do not protect against internal buffer overflows (CWE-120, CWE-20). Check implementation on installation, or limit the size of all string inputs. # undef getopt data/gzip-1.10/lib/getopt-pfx-core.h:45:10: [3] (buffer) getopt: Some older implementations do not protect against internal buffer overflows (CWE-120, CWE-20). Check implementation on installation, or limit the size of all string inputs. # define getopt __GETOPT_ID (getopt) data/gzip-1.10/lib/getopt-pfx-core.h:45:30: [3] (buffer) getopt: Some older implementations do not protect against internal buffer overflows (CWE-120, CWE-20). Check implementation on installation, or limit the size of all string inputs. # define getopt __GETOPT_ID (getopt) data/gzip-1.10/lib/getopt-pfx-ext.h:40:9: [3] (buffer) getopt_long: Some older implementations do not protect against internal buffer overflows (CWE-120, CWE-20). Check implementation on installation, or limit the size of all string inputs. # undef getopt_long data/gzip-1.10/lib/getopt-pfx-ext.h:44:10: [3] (buffer) getopt_long: Some older implementations do not protect against internal buffer overflows (CWE-120, CWE-20). Check implementation on installation, or limit the size of all string inputs. # define getopt_long __GETOPT_ID (getopt_long) data/gzip-1.10/lib/getopt-pfx-ext.h:44:35: [3] (buffer) getopt_long: Some older implementations do not protect against internal buffer overflows (CWE-120, CWE-20). Check implementation on installation, or limit the size of all string inputs. # define getopt_long __GETOPT_ID (getopt_long) data/gzip-1.10/lib/getopt.c:405:33: [3] (buffer) getenv: Environment variables are untrustable input if they can be set by an attacker. They can have any content and length, and the same variable can be set more than once (CWE-807, CWE-20). Check environment variables carefully before using them. else if (posixly_correct || !!getenv ("POSIXLY_CORRECT")) data/gzip-1.10/lib/getopt.c:736:14: [3] (buffer) getopt: Some older implementations do not protect against internal buffer overflows (CWE-120, CWE-20). Check implementation on installation, or limit the size of all string inputs. GETOPT_ENTRY(getopt, 0) data/gzip-1.10/lib/getopt.c:739:14: [3] (buffer) getopt: Some older implementations do not protect against internal buffer overflows (CWE-120, CWE-20). Check implementation on installation, or limit the size of all string inputs. GETOPT_ENTRY(getopt, 1) data/gzip-1.10/lib/getopt.c:758:11: [3] (buffer) getopt: Some older implementations do not protect against internal buffer overflows (CWE-120, CWE-20). Check implementation on installation, or limit the size of all string inputs. c = getopt (argc, argv, "abc:d:0123456789"); data/gzip-1.10/lib/getopt1.c:28:1: [3] (buffer) getopt_long: Some older implementations do not protect against internal buffer overflows (CWE-120, CWE-20). Check implementation on installation, or limit the size of all string inputs. getopt_long (int argc, char *__getopt_argv_const *argv, const char *options, data/gzip-1.10/lib/getopt1.c:94:11: [3] (buffer) getopt_long: Some older implementations do not protect against internal buffer overflows (CWE-120, CWE-20). Check implementation on installation, or limit the size of all string inputs. c = getopt_long (argc, argv, "abc:d:0123456789", data/gzip-1.10/lib/gettimeofday.c:48:22: [3] (misc) LoadLibrary: Ensure that the full path to the library is specified, or current directory may be used (CWE-829, CWE-20). Use registry entry or GetWindowsDirectory to find library path, if you aren't already. HMODULE kernel32 = LoadLibrary ("kernel32.dll"); data/gzip-1.10/lib/glthread/lock.c:801:3: [3] (misc) InitializeCriticalSection: Exceptions can be thrown in low-memory situations. Use InitializeCriticalSectionAndSpinCount instead. InitializeCriticalSection (&lock->lock); data/gzip-1.10/lib/glthread/lock.c:819:3: [3] (misc) EnterCriticalSection: On some versions of Windows, exceptions can be thrown in low-memory situations. Use InitializeCriticalSectionAndSpinCount instead. EnterCriticalSection (&lock->lock); data/gzip-1.10/lib/glthread/lock.c:938:3: [3] (misc) InitializeCriticalSection: Exceptions can be thrown in low-memory situations. Use InitializeCriticalSectionAndSpinCount instead. InitializeCriticalSection (&lock->lock); data/gzip-1.10/lib/glthread/lock.c:959:3: [3] (misc) EnterCriticalSection: On some versions of Windows, exceptions can be thrown in low-memory situations. Use InitializeCriticalSectionAndSpinCount instead. EnterCriticalSection (&lock->lock); data/gzip-1.10/lib/glthread/lock.c:991:15: [3] (misc) EnterCriticalSection: On some versions of Windows, exceptions can be thrown in low-memory situations. Use InitializeCriticalSectionAndSpinCount instead. EnterCriticalSection (&lock->lock); data/gzip-1.10/lib/glthread/lock.c:1015:3: [3] (misc) EnterCriticalSection: On some versions of Windows, exceptions can be thrown in low-memory situations. Use InitializeCriticalSectionAndSpinCount instead. EnterCriticalSection (&lock->lock); data/gzip-1.10/lib/glthread/lock.c:1044:15: [3] (misc) EnterCriticalSection: On some versions of Windows, exceptions can be thrown in low-memory situations. Use InitializeCriticalSectionAndSpinCount instead. EnterCriticalSection (&lock->lock); data/gzip-1.10/lib/glthread/lock.c:1059:3: [3] (misc) EnterCriticalSection: On some versions of Windows, exceptions can be thrown in low-memory situations. Use InitializeCriticalSectionAndSpinCount instead. EnterCriticalSection (&lock->lock); data/gzip-1.10/lib/glthread/lock.c:1121:3: [3] (misc) InitializeCriticalSection: Exceptions can be thrown in low-memory situations. Use InitializeCriticalSectionAndSpinCount instead. InitializeCriticalSection (&lock->lock); data/gzip-1.10/lib/glthread/lock.c:1143:9: [3] (misc) EnterCriticalSection: On some versions of Windows, exceptions can be thrown in low-memory situations. Use InitializeCriticalSectionAndSpinCount instead. EnterCriticalSection (&lock->lock); data/gzip-1.10/lib/glthread/lock.c:1190:11: [3] (misc) InitializeCriticalSection: Exceptions can be thrown in low-memory situations. Use InitializeCriticalSectionAndSpinCount instead. InitializeCriticalSection (&once_control->lock); data/gzip-1.10/lib/glthread/lock.c:1191:11: [3] (misc) EnterCriticalSection: On some versions of Windows, exceptions can be thrown in low-memory situations. Use InitializeCriticalSectionAndSpinCount instead. EnterCriticalSection (&once_control->lock); data/gzip-1.10/lib/glthread/lock.c:1210:15: [3] (misc) EnterCriticalSection: On some versions of Windows, exceptions can be thrown in low-memory situations. Use InitializeCriticalSectionAndSpinCount instead. EnterCriticalSection (&once_control->lock); data/gzip-1.10/lib/stat-w32.c:64:22: [3] (misc) LoadLibrary: Ensure that the full path to the library is specified, or current directory may be used (CWE-829, CWE-20). Use registry entry or GetWindowsDirectory to find library path, if you aren't already. HMODULE kernel32 = LoadLibrary ("kernel32.dll"); data/gzip-1.10/lib/stdlib.in.h:577:19: [3] (random) random: This function is not sufficiently random for security-related functions such as key and nonce creation (CWE-327). Use a more secure technique for acquiring random values. _GL_FUNCDECL_SYS (random, long, (void)); data/gzip-1.10/lib/stdlib.in.h:579:19: [3] (random) random: This function is not sufficiently random for security-related functions such as key and nonce creation (CWE-327). Use a more secure technique for acquiring random values. _GL_CXXALIAS_SYS (random, long, (void)); data/gzip-1.10/lib/stdlib.in.h:580:19: [3] (random) random: This function is not sufficiently random for security-related functions such as key and nonce creation (CWE-327). Use a more secure technique for acquiring random values. _GL_CXXALIASWARN (random); data/gzip-1.10/lib/stdlib.in.h:582:9: [3] (random) random: This function is not sufficiently random for security-related functions such as key and nonce creation (CWE-327). Use a more secure technique for acquiring random values. # undef random data/gzip-1.10/lib/stdlib.in.h:584:18: [3] (random) random: This function is not sufficiently random for security-related functions such as key and nonce creation (CWE-327). Use a more secure technique for acquiring random values. _GL_WARN_ON_USE (random, "random is unportable - " data/gzip-1.10/lib/stdlib.in.h:591:19: [3] (random) srandom: This function is not sufficiently random for security-related functions such as key and nonce creation (CWE-327). Use a more secure technique for acquiring random values. _GL_FUNCDECL_SYS (srandom, void, (unsigned int seed)); data/gzip-1.10/lib/stdlib.in.h:593:19: [3] (random) srandom: This function is not sufficiently random for security-related functions such as key and nonce creation (CWE-327). Use a more secure technique for acquiring random values. _GL_CXXALIAS_SYS (srandom, void, (unsigned int seed)); data/gzip-1.10/lib/stdlib.in.h:594:19: [3] (random) srandom: This function is not sufficiently random for security-related functions such as key and nonce creation (CWE-327). Use a more secure technique for acquiring random values. _GL_CXXALIASWARN (srandom); data/gzip-1.10/lib/stdlib.in.h:596:9: [3] (random) srandom: This function is not sufficiently random for security-related functions such as key and nonce creation (CWE-327). Use a more secure technique for acquiring random values. # undef srandom data/gzip-1.10/lib/stdlib.in.h:598:18: [3] (random) srandom: This function is not sufficiently random for security-related functions such as key and nonce creation (CWE-327). Use a more secure technique for acquiring random values. _GL_WARN_ON_USE (srandom, "srandom is unportable - " data/gzip-1.10/lib/stdlib.in.h:622:19: [3] (random) setstate: This function is not sufficiently random for security-related functions such as key and nonce creation (CWE-327). Use a more secure technique for acquiring random values. _GL_FUNCDECL_SYS (setstate, char *, (char *arg_state) _GL_ARG_NONNULL ((1))); data/gzip-1.10/lib/stdlib.in.h:624:19: [3] (random) setstate: This function is not sufficiently random for security-related functions such as key and nonce creation (CWE-327). Use a more secure technique for acquiring random values. _GL_CXXALIAS_SYS (setstate, char *, (char *arg_state)); data/gzip-1.10/lib/stdlib.in.h:625:19: [3] (random) setstate: This function is not sufficiently random for security-related functions such as key and nonce creation (CWE-327). Use a more secure technique for acquiring random values. _GL_CXXALIASWARN (setstate); data/gzip-1.10/lib/stdlib.in.h:627:9: [3] (random) setstate: This function is not sufficiently random for security-related functions such as key and nonce creation (CWE-327). Use a more secure technique for acquiring random values. # undef setstate data/gzip-1.10/lib/stdlib.in.h:629:18: [3] (random) setstate: This function is not sufficiently random for security-related functions such as key and nonce creation (CWE-327). Use a more secure technique for acquiring random values. _GL_WARN_ON_USE (setstate, "setstate is unportable - " data/gzip-1.10/lib/stdlib.in.h:792:12: [3] (buffer) realpath: This function does not protect against buffer overflows, and some implementations can overflow internally (CWE-120/CWE-785!). Ensure that the destination buffer is at least of size MAXPATHLEN, andto protect against implementation problems, the input argument should also be checked to ensure it is no larger than MAXPATHLEN. # define realpath rpl_realpath data/gzip-1.10/lib/stdlib.in.h:794:19: [3] (buffer) realpath: This function does not protect against buffer overflows, and some implementations can overflow internally (CWE-120/CWE-785!). Ensure that the destination buffer is at least of size MAXPATHLEN, andto protect against implementation problems, the input argument should also be checked to ensure it is no larger than MAXPATHLEN. _GL_FUNCDECL_RPL (realpath, char *, (const char *name, char *resolved) data/gzip-1.10/lib/stdlib.in.h:796:19: [3] (buffer) realpath: This function does not protect against buffer overflows, and some implementations can overflow internally (CWE-120/CWE-785!). Ensure that the destination buffer is at least of size MAXPATHLEN, andto protect against implementation problems, the input argument should also be checked to ensure it is no larger than MAXPATHLEN. _GL_CXXALIAS_RPL (realpath, char *, (const char *name, char *resolved)); data/gzip-1.10/lib/stdlib.in.h:799:19: [3] (buffer) realpath: This function does not protect against buffer overflows, and some implementations can overflow internally (CWE-120/CWE-785!). Ensure that the destination buffer is at least of size MAXPATHLEN, andto protect against implementation problems, the input argument should also be checked to ensure it is no larger than MAXPATHLEN. _GL_FUNCDECL_SYS (realpath, char *, (const char *name, char *resolved) data/gzip-1.10/lib/stdlib.in.h:802:19: [3] (buffer) realpath: This function does not protect against buffer overflows, and some implementations can overflow internally (CWE-120/CWE-785!). Ensure that the destination buffer is at least of size MAXPATHLEN, andto protect against implementation problems, the input argument should also be checked to ensure it is no larger than MAXPATHLEN. _GL_CXXALIAS_SYS (realpath, char *, (const char *name, char *resolved)); data/gzip-1.10/lib/stdlib.in.h:804:19: [3] (buffer) realpath: This function does not protect against buffer overflows, and some implementations can overflow internally (CWE-120/CWE-785!). Ensure that the destination buffer is at least of size MAXPATHLEN, andto protect against implementation problems, the input argument should also be checked to ensure it is no larger than MAXPATHLEN. _GL_CXXALIASWARN (realpath); data/gzip-1.10/lib/stdlib.in.h:806:9: [3] (buffer) realpath: This function does not protect against buffer overflows, and some implementations can overflow internally (CWE-120/CWE-785!). Ensure that the destination buffer is at least of size MAXPATHLEN, andto protect against implementation problems, the input argument should also be checked to ensure it is no larger than MAXPATHLEN. # undef realpath data/gzip-1.10/lib/stdlib.in.h:808:18: [3] (buffer) realpath: This function does not protect against buffer overflows, and some implementations can overflow internally (CWE-120/CWE-785!). Ensure that the destination buffer is at least of size MAXPATHLEN, andto protect against implementation problems, the input argument should also be checked to ensure it is no larger than MAXPATHLEN. _GL_WARN_ON_USE (realpath, "realpath is unportable - use gnulib module " data/gzip-1.10/util.c:374:15: [3] (buffer) getenv: Environment variables are untrustable input if they can be set by an attacker. They can have any content and length, and the same variable can be set more than once (CWE-807, CWE-20). Check environment variables carefully before using them. env_val = getenv(envvar_name); data/gzip-1.10/deflate.c:565:9: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy((char*)window, (char*)window+WSIZE, (unsigned)WSIZE); data/gzip-1.10/gzip.c:202:8: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. static char volatile remove_ofname[MAX_PATH_LEN]; data/gzip-1.10/gzip.c:210:1: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char ifname[MAX_PATH_LEN]; /* input file name */ data/gzip-1.10/gzip.c:211:1: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char ofname[MAX_PATH_LEN]; /* output file name */ data/gzip-1.10/gzip.c:212:8: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. static char dfname[MAX_PATH_LEN]; /* name of dir containing output file */ data/gzip-1.10/gzip.c:509:23: [2] (integer) atoi: Unless checked, the resulting number can exceed the expected range (CWE-190). If source untrusted, check both minimum and maximum, even if the input had no minus sign (large numbers can roll over into negative number; consider saving to an unsigned value if that is intended). maxbits = atoi(optarg); data/gzip-1.10/gzip.c:668:9: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. strcpy (ifname, "stdin"); data/gzip-1.10/gzip.c:764:5: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. strcpy(ifname, "stdin"); data/gzip-1.10/gzip.c:765:5: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. strcpy(ofname, "stdout"); data/gzip-1.10/gzip.c:857:7: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy (dfname, dir, dirlen); data/gzip-1.10/gzip.c:859:13: [2] (misc) open: Check when opening files - can an attacker redirect it (via symlinks), force the opening of special file type (e.g., device files), move things around to create a race condition, control its ancestors, or change its contents? (CWE-362). dfd = open (dfname, O_SEARCH | O_DIRECTORY); data/gzip-1.10/gzip.c:952:9: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. strcpy(ofname, "stdout"); data/gzip-1.10/gzip.c:1173:5: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char suffix[MAX_SUFFIX+3]; /* last chars of name, forced to lower case */ data/gzip-1.10/gzip.c:1409:13: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. strcpy(suff, ".tar"); data/gzip-1.10/gzip.c:1436:17: [2] (buffer) strcat: Does not check for buffer overflows when concatenating to destination [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or snprintf (warning: strncat is easily misused). Risk is low because the source is a constant string. strcat(ofname, "gz"); /* enough room */ data/gzip-1.10/gzip.c:1732:12: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. static char const *const methods[MAX_METHODS] = { data/gzip-1.10/gzip.c:1858:9: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. strcpy(p-4, ".tgz"); data/gzip-1.10/gzip.c:2009:5: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char nbuf[MAX_PATH_LEN]; data/gzip-1.10/gzip.c:2128:7: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char fname[MAX_PATH_LEN]; data/gzip-1.10/inflate.c:583:11: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy(slide + w, slide + d, e); data/gzip-1.10/lib/at-func.c:89:5: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char proc_buf[OPENAT_BUFFER_SIZE]; data/gzip-1.10/lib/dirent-private.h:37:3: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char dir_name_mask[1]; data/gzip-1.10/lib/dirent.in.h:41:3: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char d_name[1]; data/gzip-1.10/lib/dirname-lgpl.c:81:3: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy (dir, file, length); data/gzip-1.10/lib/dup.c:66:7: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char path[_MAX_PATH]; data/gzip-1.10/lib/dup.c:70:17: [2] (misc) open: Check when opening files - can an attacker redirect it (via symlinks), force the opening of special file type (e.g., device files), move things around to create a race condition, control its ancestors, or change its contents? (CWE-362). dupfd = open (path, O_RDONLY); data/gzip-1.10/lib/dup2.c:118:12: [2] (misc) open: Check when opening files - can an attacker redirect it (via symlinks), force the opening of special file type (e.g., device files), move things around to create a race condition, control its ancestors, or change its contents? (CWE-362). tempfd = open ("NUL", O_RDONLY); data/gzip-1.10/lib/dup2.c:126:7: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char path[_MAX_PATH]; data/gzip-1.10/lib/dup2.c:130:14: [2] (misc) open: Check when opening files - can an attacker redirect it (via symlinks), force the opening of special file type (e.g., device files), move things around to create a race condition, control its ancestors, or change its contents? (CWE-362). return open(path, O_RDONLY); data/gzip-1.10/lib/error.c:180:3: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char errbuf[1024]; data/gzip-1.10/lib/fcntl--.h:23:8: [2] (misc) open: Check when opening files - can an attacker redirect it (via symlinks), force the opening of special file type (e.g., device files), move things around to create a race condition, control its ancestors, or change its contents? (CWE-362). #undef open data/gzip-1.10/lib/fcntl--.h:24:9: [2] (misc) open: Check when opening files - can an attacker redirect it (via symlinks), force the opening of special file type (e.g., device files), move things around to create a race condition, control its ancestors, or change its contents? (CWE-362). #define open open_safer data/gzip-1.10/lib/fcntl.c:60:12: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. unsigned char fds_to_close[OPEN_MAX_MAX / CHAR_BIT]; data/gzip-1.10/lib/fcntl.in.h:111:11: [2] (misc) open: Check when opening files - can an attacker redirect it (via symlinks), force the opening of special file type (e.g., device files), move things around to create a race condition, control its ancestors, or change its contents? (CWE-362). # undef open data/gzip-1.10/lib/fcntl.in.h:112:12: [2] (misc) open: Check when opening files - can an attacker redirect it (via symlinks), force the opening of special file type (e.g., device files), move things around to create a race condition, control its ancestors, or change its contents? (CWE-362). # define open rpl_open data/gzip-1.10/lib/fcntl.in.h:114:19: [2] (misc) open: Check when opening files - can an attacker redirect it (via symlinks), force the opening of special file type (e.g., device files), move things around to create a race condition, control its ancestors, or change its contents? (CWE-362). _GL_FUNCDECL_RPL (open, int, (const char *filename, int flags, ...) data/gzip-1.10/lib/fcntl.in.h:116:19: [2] (misc) open: Check when opening files - can an attacker redirect it (via symlinks), force the opening of special file type (e.g., device files), move things around to create a race condition, control its ancestors, or change its contents? (CWE-362). _GL_CXXALIAS_RPL (open, int, (const char *filename, int flags, ...)); data/gzip-1.10/lib/fcntl.in.h:118:19: [2] (misc) open: Check when opening files - can an attacker redirect it (via symlinks), force the opening of special file type (e.g., device files), move things around to create a race condition, control its ancestors, or change its contents? (CWE-362). _GL_CXXALIAS_SYS (open, int, (const char *filename, int flags, ...)); data/gzip-1.10/lib/fcntl.in.h:123:19: [2] (misc) open: Check when opening files - can an attacker redirect it (via symlinks), force the opening of special file type (e.g., device files), move things around to create a race condition, control its ancestors, or change its contents? (CWE-362). _GL_CXXALIASWARN (open); data/gzip-1.10/lib/fcntl.in.h:126:9: [2] (misc) open: Check when opening files - can an attacker redirect it (via symlinks), force the opening of special file type (e.g., device files), move things around to create a race condition, control its ancestors, or change its contents? (CWE-362). # undef open data/gzip-1.10/lib/fcntl.in.h:128:18: [2] (misc) open: Check when opening files - can an attacker redirect it (via symlinks), force the opening of special file type (e.g., device files), move things around to create a race condition, control its ancestors, or change its contents? (CWE-362). _GL_WARN_ON_USE (open, "open is not always POSIX compliant - " data/gzip-1.10/lib/fdopendir.c:71:3: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char path[_MAX_PATH]; data/gzip-1.10/lib/fdopendir.c:182:7: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char buf[OPENAT_BUFFER_SIZE]; data/gzip-1.10/lib/filenamecat-lgpl.c:31:47: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. # define mempcpy(D, S, N) ((void *) ((char *) memcpy (D, S, N) + (N))) data/gzip-1.10/lib/fprintf.c:38:3: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char buf[2000]; data/gzip-1.10/lib/fseeko.c:62:19: [2] (misc) fopen: Check when opening files - can an attacker redirect it (via symlinks), force the opening of special file type (e.g., device files), move things around to create a race condition, control its ancestors, or change its contents? (CWE-362). FILE *tmp = fopen ("/dev/null", "r"); data/gzip-1.10/lib/ftello.c:76:19: [2] (misc) fopen: Check when opening files - can an attacker redirect it (via symlinks), force the opening of special file type (e.g., device files), move things around to create a race condition, control its ancestors, or change its contents? (CWE-362). FILE *tmp = fopen ("/dev/null", "r"); data/gzip-1.10/lib/getcwd-lgpl.c:80:5: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char tmp[4032]; data/gzip-1.10/lib/getprogname.c:148:11: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char status64[1216]; data/gzip-1.10/lib/getprogname.c:218:3: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char filename[50]; data/gzip-1.10/lib/getprogname.c:221:3: [2] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. Risk is low because the source has a constant maximum length. sprintf (filename, "/proc/pinfo/%d", (int) getpid ()); data/gzip-1.10/lib/getprogname.c:222:8: [2] (misc) open: Check when opening files - can an attacker redirect it (via symlinks), force the opening of special file type (e.g., device files), move things around to create a race condition, control its ancestors, or change its contents? (CWE-362). fd = open (filename, O_RDONLY); data/gzip-1.10/lib/getprogname.c:238:22: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. return memcpy (namecopy, name, namelen); data/gzip-1.10/lib/gettext.h:220:3: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char msg_ctxt_id[msgctxt_len + msgid_len]; data/gzip-1.10/lib/gettext.h:222:3: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char buf[1024]; data/gzip-1.10/lib/gettext.h:231:7: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy (msg_ctxt_id, msgctxt, msgctxt_len - 1); data/gzip-1.10/lib/gettext.h:233:7: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy (msg_ctxt_id + msgctxt_len, msgid, msgid_len); data/gzip-1.10/lib/gettext.h:268:3: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char msg_ctxt_id[msgctxt_len + msgid_len]; data/gzip-1.10/lib/gettext.h:270:3: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char buf[1024]; data/gzip-1.10/lib/gettext.h:279:7: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy (msg_ctxt_id, msgctxt, msgctxt_len - 1); data/gzip-1.10/lib/gettext.h:281:7: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy (msg_ctxt_id + msgctxt_len, msgid, msgid_len); data/gzip-1.10/lib/mempcpy.c:27:19: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. return (char *) memcpy (dest, src, n) + n; data/gzip-1.10/lib/open-safer.c:45:20: [2] (misc) open: Check when opening files - can an attacker redirect it (via symlinks), force the opening of special file type (e.g., device files), move things around to create a race condition, control its ancestors, or change its contents? (CWE-362). return fd_safer (open (file, flags, mode)); data/gzip-1.10/lib/open.c:33:10: [2] (misc) open: Check when opening files - can an attacker redirect it (via symlinks), force the opening of special file type (e.g., device files), move things around to create a race condition, control its ancestors, or change its contents? (CWE-362). return open (filename, flags, mode); data/gzip-1.10/lib/open.c:55:1: [2] (misc) open: Check when opening files - can an attacker redirect it (via symlinks), force the opening of special file type (e.g., device files), move things around to create a race condition, control its ancestors, or change its contents? (CWE-362). open (const char *filename, int flags, ...) data/gzip-1.10/lib/open.c:162:16: [2] (misc) open: Check when opening files - can an attacker redirect it (via symlinks), force the opening of special file type (e.g., device files), move things around to create a race condition, control its ancestors, or change its contents? (CWE-362). fd = open ("/dev/null", flags, mode); data/gzip-1.10/lib/openat-priv.h:47:1: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char *openat_proc_name (char buf[OPENAT_BUFFER_SIZE], int fd, char const *file); data/gzip-1.10/lib/openat-priv.h:47:25: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char *openat_proc_name (char buf[OPENAT_BUFFER_SIZE], int fd, char const *file); data/gzip-1.10/lib/openat-proc.c:43:1: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char * data/gzip-1.10/lib/openat-proc.c:44:19: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. openat_proc_name (char buf[OPENAT_BUFFER_SIZE], int fd, char const *file) data/gzip-1.10/lib/openat-proc.c:76:28: [2] (misc) open: Check when opening files - can an attacker redirect it (via symlinks), force the opening of special file type (e.g., device files), move things around to create a race condition, control its ancestors, or change its contents? (CWE-362). int proc_self_fd = open ("/proc/self/fd", data/gzip-1.10/lib/openat-proc.c:87:13: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char dotdot_buf[PROC_SELF_FD_DIR_SIZE_BOUND + sizeof "../fd" - 1]; data/gzip-1.10/lib/openat-proc.c:112:5: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char dir[_MAX_PATH]; data/gzip-1.10/lib/openat.c:225:12: [2] (misc) open: Check when opening files - can an attacker redirect it (via symlinks), force the opening of special file type (e.g., device files), move things around to create a race condition, control its ancestors, or change its contents? (CWE-362). return open (file, flags, mode); data/gzip-1.10/lib/openat.c:228:5: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char buf[OPENAT_BUFFER_SIZE]; data/gzip-1.10/lib/openat.c:232:27: [2] (misc) open: Check when opening files - can an attacker redirect it (via symlinks), force the opening of special file type (e.g., device files), move things around to create a race condition, control its ancestors, or change its contents? (CWE-362). int open_result = open (proc_file, flags, mode); data/gzip-1.10/lib/openat.c:269:13: [2] (misc) open: Check when opening files - can an attacker redirect it (via symlinks), force the opening of special file type (e.g., device files), move things around to create a race condition, control its ancestors, or change its contents? (CWE-362). err = open (file, flags, mode); data/gzip-1.10/lib/openat.c:296:12: [2] (misc) open: Check when opening files - can an attacker redirect it (via symlinks), force the opening of special file type (e.g., device files), move things around to create a race condition, control its ancestors, or change its contents? (CWE-362). int fd = open ("/", O_SEARCH); data/gzip-1.10/lib/openat.c:300:7: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char buf[OPENAT_BUFFER_SIZE]; data/gzip-1.10/lib/opendir.c:61:14: [2] (misc) open: Check when opening files - can an attacker redirect it (via symlinks), force the opening of special file type (e.g., device files), move things around to create a race condition, control its ancestors, or change its contents? (CWE-362). int fd = open (dir_name, O_RDONLY); data/gzip-1.10/lib/opendir.c:77:3: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char dir_name_mask[MAX_PATH + 1 + 1 + 1]; data/gzip-1.10/lib/opendir.c:150:5: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy (&dirp->entry, &entry, sizeof (WIN32_FIND_DATA)); data/gzip-1.10/lib/perror.c:35:3: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char stackbuf[STACKBUF_LEN]; data/gzip-1.10/lib/printf-parse.c:122:11: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy (memory, a->arg, a->count * sizeof (argument)); \ data/gzip-1.10/lib/printf-parse.c:599:17: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy (memory, d->dir, d->count * sizeof (DIRECTIVE)); data/gzip-1.10/lib/save-cwd.c:66:15: [2] (misc) open: Check when opening files - can an attacker redirect it (via symlinks), force the opening of special file type (e.g., device files), move things around to create a race condition, control its ancestors, or change its contents? (CWE-362). cwd->desc = open (".", O_SEARCH | O_CLOEXEC); data/gzip-1.10/lib/savedir.c:145:15: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy (name_space + used, entry, entry_size); data/gzip-1.10/lib/stat-w32.c:196:15: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy (&buf->st_ino, &id.FileId, sizeof (ino_t)); data/gzip-1.10/lib/stat-w32.c:249:15: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char fpath[PATH_MAX]; data/gzip-1.10/lib/stat.c:168:7: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy (malloca_rname, name, rlen); data/gzip-1.10/lib/stdio-impl.h:51:35: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. unsigned char _ubuf[3]; \ data/gzip-1.10/lib/stdio-impl.h:52:35: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. unsigned char _nbuf[1]; \ data/gzip-1.10/lib/stdio-impl.h:85:35: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. unsigned char _ubuf[3]; \ data/gzip-1.10/lib/stdio-impl.h:86:35: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. unsigned char _nbuf[1]; \ data/gzip-1.10/lib/stdio.in.h:283:11: [2] (misc) fopen: Check when opening files - can an attacker redirect it (via symlinks), force the opening of special file type (e.g., device files), move things around to create a race condition, control its ancestors, or change its contents? (CWE-362). # undef fopen data/gzip-1.10/lib/stdio.in.h:284:12: [2] (misc) fopen: Check when opening files - can an attacker redirect it (via symlinks), force the opening of special file type (e.g., device files), move things around to create a race condition, control its ancestors, or change its contents? (CWE-362). # define fopen rpl_fopen data/gzip-1.10/lib/stdio.in.h:286:19: [2] (misc) fopen: Check when opening files - can an attacker redirect it (via symlinks), force the opening of special file type (e.g., device files), move things around to create a race condition, control its ancestors, or change its contents? (CWE-362). _GL_FUNCDECL_RPL (fopen, FILE *, (const char *filename, const char *mode) data/gzip-1.10/lib/stdio.in.h:288:19: [2] (misc) fopen: Check when opening files - can an attacker redirect it (via symlinks), force the opening of special file type (e.g., device files), move things around to create a race condition, control its ancestors, or change its contents? (CWE-362). _GL_CXXALIAS_RPL (fopen, FILE *, (const char *filename, const char *mode)); data/gzip-1.10/lib/stdio.in.h:290:19: [2] (misc) fopen: Check when opening files - can an attacker redirect it (via symlinks), force the opening of special file type (e.g., device files), move things around to create a race condition, control its ancestors, or change its contents? (CWE-362). _GL_CXXALIAS_SYS (fopen, FILE *, (const char *filename, const char *mode)); data/gzip-1.10/lib/stdio.in.h:292:19: [2] (misc) fopen: Check when opening files - can an attacker redirect it (via symlinks), force the opening of special file type (e.g., device files), move things around to create a race condition, control its ancestors, or change its contents? (CWE-362). _GL_CXXALIASWARN (fopen); data/gzip-1.10/lib/stdio.in.h:294:9: [2] (misc) fopen: Check when opening files - can an attacker redirect it (via symlinks), force the opening of special file type (e.g., device files), move things around to create a race condition, control its ancestors, or change its contents? (CWE-362). # undef fopen data/gzip-1.10/lib/stdio.in.h:296:18: [2] (misc) fopen: Check when opening files - can an attacker redirect it (via symlinks), force the opening of special file type (e.g., device files), move things around to create a race condition, control its ancestors, or change its contents? (CWE-362). _GL_WARN_ON_USE (fopen, "fopen on native Windows platforms is not POSIX compliant - " data/gzip-1.10/lib/stdio.in.h:1118:12: [2] (tmpfile) tmpfile: Function tmpfile() has a security flaw on some systems (e.g., older System V systems) (CWE-377). # define tmpfile rpl_tmpfile data/gzip-1.10/lib/stdio.in.h:1120:19: [2] (tmpfile) tmpfile: Function tmpfile() has a security flaw on some systems (e.g., older System V systems) (CWE-377). _GL_FUNCDECL_RPL (tmpfile, FILE *, (void)); data/gzip-1.10/lib/stdio.in.h:1121:19: [2] (tmpfile) tmpfile: Function tmpfile() has a security flaw on some systems (e.g., older System V systems) (CWE-377). _GL_CXXALIAS_RPL (tmpfile, FILE *, (void)); data/gzip-1.10/lib/stdio.in.h:1123:19: [2] (tmpfile) tmpfile: Function tmpfile() has a security flaw on some systems (e.g., older System V systems) (CWE-377). _GL_CXXALIAS_SYS (tmpfile, FILE *, (void)); data/gzip-1.10/lib/stdio.in.h:1125:19: [2] (tmpfile) tmpfile: Function tmpfile() has a security flaw on some systems (e.g., older System V systems) (CWE-377). _GL_CXXALIASWARN (tmpfile); data/gzip-1.10/lib/stdio.in.h:1127:9: [2] (tmpfile) tmpfile: Function tmpfile() has a security flaw on some systems (e.g., older System V systems) (CWE-377). # undef tmpfile data/gzip-1.10/lib/stdio.in.h:1129:18: [2] (tmpfile) tmpfile: Function tmpfile() has a security flaw on some systems (e.g., older System V systems) (CWE-377). _GL_WARN_ON_USE (tmpfile, "tmpfile is not usable on mingw - " data/gzip-1.10/lib/stdlib.in.h:402:12: [2] (tmpfile) mkstemp: Potential for temporary file vulnerability in some circumstances. Some older Unix-like systems create temp files with permission to write by all by default, so be sure to set the umask to override this. Also, some older Unix systems might fail to use O_EXCL when opening the file, so make sure that O_EXCL is used by the library (CWE-377). # define mkstemp rpl_mkstemp data/gzip-1.10/lib/stdlib.in.h:404:19: [2] (tmpfile) mkstemp: Potential for temporary file vulnerability in some circumstances. Some older Unix-like systems create temp files with permission to write by all by default, so be sure to set the umask to override this. Also, some older Unix systems might fail to use O_EXCL when opening the file, so make sure that O_EXCL is used by the library (CWE-377). _GL_FUNCDECL_RPL (mkstemp, int, (char * /*template*/) _GL_ARG_NONNULL ((1))); data/gzip-1.10/lib/stdlib.in.h:405:19: [2] (tmpfile) mkstemp: Potential for temporary file vulnerability in some circumstances. Some older Unix-like systems create temp files with permission to write by all by default, so be sure to set the umask to override this. Also, some older Unix systems might fail to use O_EXCL when opening the file, so make sure that O_EXCL is used by the library (CWE-377). _GL_CXXALIAS_RPL (mkstemp, int, (char * /*template*/)); data/gzip-1.10/lib/stdlib.in.h:408:19: [2] (tmpfile) mkstemp: Potential for temporary file vulnerability in some circumstances. Some older Unix-like systems create temp files with permission to write by all by default, so be sure to set the umask to override this. Also, some older Unix systems might fail to use O_EXCL when opening the file, so make sure that O_EXCL is used by the library (CWE-377). _GL_FUNCDECL_SYS (mkstemp, int, (char * /*template*/) _GL_ARG_NONNULL ((1))); data/gzip-1.10/lib/stdlib.in.h:410:19: [2] (tmpfile) mkstemp: Potential for temporary file vulnerability in some circumstances. Some older Unix-like systems create temp files with permission to write by all by default, so be sure to set the umask to override this. Also, some older Unix systems might fail to use O_EXCL when opening the file, so make sure that O_EXCL is used by the library (CWE-377). _GL_CXXALIAS_SYS (mkstemp, int, (char * /*template*/)); data/gzip-1.10/lib/stdlib.in.h:412:19: [2] (tmpfile) mkstemp: Potential for temporary file vulnerability in some circumstances. Some older Unix-like systems create temp files with permission to write by all by default, so be sure to set the umask to override this. Also, some older Unix systems might fail to use O_EXCL when opening the file, so make sure that O_EXCL is used by the library (CWE-377). _GL_CXXALIASWARN (mkstemp); data/gzip-1.10/lib/stdlib.in.h:414:9: [2] (tmpfile) mkstemp: Potential for temporary file vulnerability in some circumstances. Some older Unix-like systems create temp files with permission to write by all by default, so be sure to set the umask to override this. Also, some older Unix systems might fail to use O_EXCL when opening the file, so make sure that O_EXCL is used by the library (CWE-377). # undef mkstemp data/gzip-1.10/lib/stdlib.in.h:416:18: [2] (tmpfile) mkstemp: Potential for temporary file vulnerability in some circumstances. Some older Unix-like systems create temp files with permission to write by all by default, so be sure to set the umask to override this. Also, some older Unix systems might fail to use O_EXCL when opening the file, so make sure that O_EXCL is used by the library (CWE-377). _GL_WARN_ON_USE (mkstemp, "mkstemp is unportable - " data/gzip-1.10/lib/strdup.c:47:19: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. return (char *) memcpy (new, s, len); data/gzip-1.10/lib/strerror.c:39:10: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. static char buf[STACKBUF_LEN]; data/gzip-1.10/lib/strerror.c:69:3: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy (buf, msg, len + 1); data/gzip-1.10/lib/strerror_r.c:192:7: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char stackbuf[80]; data/gzip-1.10/lib/strerror_r.c:219:9: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char stackbuf[STACKBUF_LEN]; data/gzip-1.10/lib/strerror_r.c:238:9: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char stackbuf[STACKBUF_LEN]; data/gzip-1.10/lib/sys_stat.in.h:788:44: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. _GL_FUNCDECL_RPL (utimensat, int, (int fd, char const *name, data/gzip-1.10/lib/sys_stat.in.h:791:44: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. _GL_CXXALIAS_RPL (utimensat, int, (int fd, char const *name, data/gzip-1.10/lib/sys_stat.in.h:795:44: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. _GL_FUNCDECL_SYS (utimensat, int, (int fd, char const *name, data/gzip-1.10/lib/sys_stat.in.h:799:44: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. _GL_CXXALIAS_SYS (utimensat, int, (int fd, char const *name, data/gzip-1.10/lib/unlink.c:72:11: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy (short_name, name, len); data/gzip-1.10/lib/unlinkat.c:71:11: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy (short_name, name, len); data/gzip-1.10/lib/utime.c:33:28: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. _gl_utimens_windows (const char *name, struct timespec ts[2]) data/gzip-1.10/lib/utime.c:77:7: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy (malloca_rname, name, rlen); data/gzip-1.10/lib/utime.in.h:83:39: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. extern int _gl_utimens_windows (const char *filename, struct timespec ts[2]); data/gzip-1.10/lib/utimens.c:170:20: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. fdutimens (int fd, char const *file, struct timespec const timespec[2]) data/gzip-1.10/lib/utimens.c:505:10: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. utimens (char const *file, struct timespec const timespec[2]) data/gzip-1.10/lib/utimens.c:515:11: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. lutimens (char const *file, struct timespec const timespec[2]) data/gzip-1.10/lib/utimens.h:21:21: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. int fdutimens (int, char const *, struct timespec const [2]); data/gzip-1.10/lib/utimens.h:22:14: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. int utimens (char const *, struct timespec const [2]); data/gzip-1.10/lib/utimens.h:23:15: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. int lutimens (char const *, struct timespec const [2]); data/gzip-1.10/lib/utimens.h:37:35: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. int fdutimensat (int fd, int dir, char const *name, struct timespec const [2], data/gzip-1.10/lib/utimens.h:42:22: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. lutimensat (int dir, char const *file, struct timespec const times[2]) data/gzip-1.10/lib/vasnprintf.c:151:21: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. # define DCHAR_CPY memcpy data/gzip-1.10/lib/vasnprintf.c:295:3: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char pointbuf[5]; data/gzip-1.10/lib/vasnprintf.c:296:3: [2] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. Risk is low because the source has a constant maximum length. sprintf (pointbuf, "%#.0f", 1.0); data/gzip-1.10/lib/vasnprintf.c:520:7: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy (r_ptr, a_ptr, a_len * sizeof (mp_limb_t)); data/gzip-1.10/lib/vasnprintf.c:656:11: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy (r_ptr, a_ptr, a_len * sizeof (mp_limb_t)); data/gzip-1.10/lib/vasnprintf.c:2677:27: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char cbuf[64]; /* Assume MB_CUR_MAX <= 64. */ data/gzip-1.10/lib/vasnprintf.c:2722:27: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char cbuf[64]; /* Assume MB_CUR_MAX <= 64. */ data/gzip-1.10/lib/vasnprintf.c:2772:25: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char cbuf[64]; /* Assume MB_CUR_MAX <= 64. */ data/gzip-1.10/lib/vasnprintf.c:2785:25: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy (tmpptr, cbuf, count); data/gzip-1.10/lib/vasnprintf.c:2853:27: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char cbuf[64]; /* Assume MB_CUR_MAX <= 64. */ data/gzip-1.10/lib/vasnprintf.c:2866:27: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy (result + length, cbuf, count); data/gzip-1.10/lib/vasnprintf.c:2882:27: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char cbuf[64]; /* Assume MB_CUR_MAX <= 64. */ data/gzip-1.10/lib/vasnprintf.c:2904:27: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy (result + length, cbuf, count); data/gzip-1.10/lib/vasnprintf.c:3185:35: [2] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. Risk is low because the source has a constant maximum length. sprintf ((char *) p, "%+d", exponent); data/gzip-1.10/lib/vasnprintf.c:3191:35: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char expbuf[6 + 1]; data/gzip-1.10/lib/vasnprintf.c:3193:35: [2] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. Risk is low because the source has a constant maximum length. sprintf (expbuf, "%+d", exponent); data/gzip-1.10/lib/vasnprintf.c:3336:35: [2] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. Risk is low because the source has a constant maximum length. sprintf ((char *) p, "%+d", exponent); data/gzip-1.10/lib/vasnprintf.c:3342:35: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char expbuf[6 + 1]; data/gzip-1.10/lib/vasnprintf.c:3344:35: [2] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. Risk is low because the source has a constant maximum length. sprintf (expbuf, "%+d", exponent); data/gzip-1.10/lib/vasnprintf.c:3411:17: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy (result + length, tmp, count * sizeof (DCHAR_T)); data/gzip-1.10/lib/vasnprintf.c:3796:37: [2] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. Risk is low because the source has a constant maximum length. sprintf ((char *) p, "%+.2d", exponent); data/gzip-1.10/lib/vasnprintf.c:3802:37: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char expbuf[6 + 1]; data/gzip-1.10/lib/vasnprintf.c:3804:37: [2] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. Risk is low because the source has a constant maximum length. sprintf (expbuf, "%+.2d", exponent); data/gzip-1.10/lib/vasnprintf.c:3977:45: [2] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. Risk is low because the source has a constant maximum length. sprintf ((char *) p, "%+.2d", exponent); data/gzip-1.10/lib/vasnprintf.c:3983:45: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char expbuf[6 + 1]; data/gzip-1.10/lib/vasnprintf.c:3985:45: [2] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. Risk is low because the source has a constant maximum length. sprintf (expbuf, "%+.2d", exponent); data/gzip-1.10/lib/vasnprintf.c:4275:39: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char expbuf[6 + 1]; data/gzip-1.10/lib/vasnprintf.c:4468:47: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char expbuf[6 + 1]; data/gzip-1.10/lib/vasnprintf.c:4594:17: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy (result + length, tmp, count * sizeof (DCHAR_T)); data/gzip-1.10/lib/vasnprintf.c:4802:29: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy (fbp, dp->width_start, n * sizeof (TCHAR_T)); data/gzip-1.10/lib/vasnprintf.c:4823:29: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy (fbp, dp->precision_start, n * sizeof (TCHAR_T)); data/gzip-1.10/lib/vasnprintf.c:5532:21: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy (result + length, tmp, count * sizeof (DCHAR_T)); data/gzip-1.10/lib/vfprintf.c:38:3: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char buf[2000]; data/gzip-1.10/lib/xmalloc.c:113:10: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. return memcpy (xmalloc (s), p, s); data/gzip-1.10/sample/add.c:17:1: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char a[MAX_DIST]; /* last byte buffer for up to MAX_DIST differences */ data/gzip-1.10/sample/sub.c:44:1: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char a[MAX_DIST]; /* last byte buffer for up to MAX_DIST differences */ data/gzip-1.10/sample/sub.c:53:7: [2] (integer) atoi: Unless checked, the resulting number can exceed the expected range (CWE-190). If source untrusted, check both minimum and maximum, even if the input had no minus sign (large numbers can roll over into negative number; consider saving to an unsigned value if that is intended). int atoi(); /* (avoid including stdlib for portability) */ data/gzip-1.10/sample/sub.c:62:9: [2] (integer) atoi: Unless checked, the resulting number can exceed the expected range (CWE-190). If source untrusted, check both minimum and maximum, even if the input had no minus sign (large numbers can roll over into negative number; consider saving to an unsigned value if that is intended). n = atoi(argv[1]); data/gzip-1.10/sample/zread.c:18:5: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char cmd[256]; data/gzip-1.10/sample/zread.c:19:5: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char buf[BUFSIZ]; data/gzip-1.10/sample/zread.c:26:5: [2] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant string. strcpy(cmd, "gzip -dc "); /* use "gzip -c" for zwrite */ data/gzip-1.10/unlzw.c:255:29: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy(outbuf+outpos, stackp, i); data/gzip-1.10/unlzw.c:268:21: [2] (buffer) memcpy: Does not check for buffer overflows when copying to destination (CWE-120). Make sure destination can always hold the source data. memcpy(outbuf+outpos, stackp, i); data/gzip-1.10/util.c:476:5: [2] (buffer) char: Statically-sized arrays can be improperly restricted, leading to potential overflows or other issues (CWE-119!/CWE-120). Perform bounds checking, use functions that limit length, or ensure that the size is larger than the maximum possible length. char buf[CHAR_BIT * sizeof (off_t)]; data/gzip-1.10/gzip.c:425:15: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). proglen = strlen (program_name); data/gzip-1.10/gzip.c:456:13: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). z_len = strlen(z_suffix); data/gzip-1.10/gzip.c:565:21: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). z_len = strlen(optarg); data/gzip-1.10/gzip.c:1187:25: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). size_t suflen = strlen (*suf); data/gzip-1.10/gzip.c:1202:12: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). nlen = strlen(name); data/gzip-1.10/gzip.c:1209:12: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). slen = strlen(suffix); data/gzip-1.10/gzip.c:1212:16: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). int s = strlen(*suf); data/gzip-1.10/gzip.c:1303:30: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). if (sizeof ifname - 1 <= strlen (iname)) data/gzip-1.10/gzip.c:1326:9: [1] (buffer) strcat: Does not check for buffer overflows when concatenating to destination [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or snprintf (warning: strncat is easily misused). Risk is low because the source is a constant character. strcat(ifname, "."); data/gzip-1.10/gzip.c:1330:12: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). ilen = strlen(ifname); data/gzip-1.10/gzip.c:1339:27: [1] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant character. if (*dot == '\0') strcpy (dot, "."); data/gzip-1.10/gzip.c:1342:29: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). if (MAX_EXT_CHARS < strlen (s) + strlen (dot + 1)) data/gzip-1.10/gzip.c:1342:42: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). if (MAX_EXT_CHARS < strlen (s) + strlen (dot + 1)) data/gzip-1.10/gzip.c:1343:35: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). dot[MAX_EXT_CHARS + 1 - strlen (s)] = '\0'; data/gzip-1.10/gzip.c:1345:37: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). if (sizeof ifname <= ilen + strlen (s)) data/gzip-1.10/gzip.c:1363:23: [1] (buffer) strcpy: Does not check for buffer overflows when copying to destination [MS-banned] (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy easily misused). Risk is low because the source is a constant character. if (*dot == '\0') strcpy(dot, "."); data/gzip-1.10/gzip.c:1366:33: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). if (MAX_EXT_CHARS < z_len + strlen (dot + 1)) data/gzip-1.10/gzip.c:1429:34: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). if (sizeof ofname <= strlen (ofname) + 1) data/gzip-1.10/gzip.c:1431:13: [1] (buffer) strcat: Does not check for buffer overflows when concatenating to destination [MS-banned] (CWE-120). Consider using strcat_s, strncat, strlcat, or snprintf (warning: strncat is easily misused). Risk is low because the source is a constant character. strcat(ofname, "."); data/gzip-1.10/gzip.c:1434:38: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). if (sizeof ofname <= strlen (ofname) + 2) data/gzip-1.10/gzip.c:1443:20: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). } else if (strlen(suff)-1 + z_len > MAX_SUFFIX) { data/gzip-1.10/gzip.c:1449:30: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). if (sizeof ofname <= strlen (ofname) + z_len) data/gzip-1.10/gzip.c:1623:35: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). memmove (base, p, strlen (p) + 1); data/gzip-1.10/gzip.c:1784:17: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). if (read(ifd, (char*)buf, sizeof(buf)) != sizeof(buf)) { data/gzip-1.10/gzip.c:1843:11: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). len = strlen(name); data/gzip-1.10/gzip.c:2031:22: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). size_t len = strlen (dir); data/gzip-1.10/gzip.c:2032:20: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). entrylen = strlen (entry); data/gzip-1.10/lib/basename-lgpl.c:63:14: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). for (len = strlen (name); 1 < len && ISSLASH (name[len - 1]); len--) data/gzip-1.10/lib/chdir-long.c:117:18: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). size_t len = strlen (dir); data/gzip-1.10/lib/error.c:211:20: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). size_t len = strlen (message) + 1; data/gzip-1.10/lib/filenamecat-lgpl.c:52:20: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). size_t baselen = strlen (base); data/gzip-1.10/lib/fstatat.c:79:9: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). len = strlen (file); data/gzip-1.10/lib/getcwd-lgpl.c:119:30: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). result = realloc (buf, strlen (buf) + 1); data/gzip-1.10/lib/getopt.c:214:16: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). && namelen == strlen (p->name)) data/gzip-1.10/lib/getopt.c:301:21: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). d->__nextchar += strlen (d->__nextchar); data/gzip-1.10/lib/getprogname.c:117:15: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). if (strlen (ucomm) < PST_UCOMMLEN - 1) data/gzip-1.10/lib/getprogname.c:131:19: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). if (strlen (p) > PST_UCOMMLEN - 1 data/gzip-1.10/lib/getprogname.c:153:19: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). if (strlen (ucomm) < PST_UCOMMLEN - 1) data/gzip-1.10/lib/getprogname.c:167:23: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). if (strlen (p) > PST_UCOMMLEN - 1 data/gzip-1.10/lib/gettext.h:216:24: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). size_t msgctxt_len = strlen (msgctxt) + 1; data/gzip-1.10/lib/gettext.h:217:22: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). size_t msgid_len = strlen (msgid) + 1; data/gzip-1.10/lib/gettext.h:264:24: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). size_t msgctxt_len = strlen (msgctxt) + 1; data/gzip-1.10/lib/gettext.h:265:22: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). size_t msgid_len = strlen (msgid) + 1; data/gzip-1.10/lib/lstat.c:80:43: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). if (S_ISDIR (sbuf->st_mode) || file[strlen (file) - 1] != '/') data/gzip-1.10/lib/match.c:152:1: [1] (buffer) mismatch: Function does not check the second iterator for over-read conditions (CWE-126). This function is often discouraged by most C++ coding standards in favor of its safer alternatives provided since C++14. Consider using a form of this function that checks the second iterator before potentially overflowing it. mismatch: data/gzip-1.10/lib/match.c:176:17: [1] (buffer) mismatch: Function does not check the second iterator for over-read conditions (CWE-126). This function is often discouraged by most C++ coding standards in favor of its safer alternatives provided since C++14. Consider using a form of this function that checks the second iterator before potentially overflowing it. jmp mismatch data/gzip-1.10/lib/match.c:690:29: [1] (buffer) mismatch: Function does not check the second iterator for over-read conditions (CWE-126). This function is often discouraged by most C++ coding standards in favor of its safer alternatives provided since C++14. Consider using a form of this function that checks the second iterator before potentially overflowing it. (p_no) br.cond.dpnt.many .mismatch data/gzip-1.10/lib/match.c:709:2: [1] (buffer) mismatch: Function does not check the second iterator for over-read conditions (CWE-126). This function is often discouraged by most C++ coding standards in favor of its safer alternatives provided since C++14. Consider using a form of this function that checks the second iterator before potentially overflowing it. .mismatch: data/gzip-1.10/lib/open.c:118:20: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). size_t len = strlen (filename); data/gzip-1.10/lib/open.c:187:20: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). size_t len = strlen (filename); data/gzip-1.10/lib/openat-proc.c:98:56: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). size_t bufsize = PROC_SELF_FD_DIR_SIZE_BOUND + strlen (file); data/gzip-1.10/lib/openat-proc.c:118:14: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). dirlen = strlen (dir); data/gzip-1.10/lib/openat-proc.c:119:28: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). bufsize = dirlen + 1 + strlen (file) + 1; /* 1 for '/', 1 for null */ data/gzip-1.10/lib/openat.c:107:20: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). size_t len = strlen (filename); data/gzip-1.10/lib/openat.c:152:20: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). size_t len = strlen (filename); data/gzip-1.10/lib/opendir.c:103:25: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). p = dir_name_mask + strlen (dir_name_mask); data/gzip-1.10/lib/opendir.c:139:15: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). + strlen (dir_name_mask) + 1); data/gzip-1.10/lib/rmdir.c:37:16: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). size_t len = strlen (dir); data/gzip-1.10/lib/savedir.c:31:33: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). # define _D_EXACT_NAMLEN(dp) strlen ((dp)->d_name) data/gzip-1.10/lib/stat.c:122:16: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). size_t len = strlen (name); data/gzip-1.10/lib/stat.c:417:24: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). size_t len = strlen (name); data/gzip-1.10/lib/stdio.in.h:254:11: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). # undef fgetc data/gzip-1.10/lib/stdio.in.h:255:12: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). # define fgetc rpl_fgetc data/gzip-1.10/lib/stdio.in.h:257:19: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). _GL_FUNCDECL_RPL (fgetc, int, (FILE *stream) _GL_ARG_NONNULL ((1))); data/gzip-1.10/lib/stdio.in.h:258:19: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). _GL_CXXALIAS_RPL (fgetc, int, (FILE *stream)); data/gzip-1.10/lib/stdio.in.h:260:19: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). _GL_CXXALIAS_SYS (fgetc, int, (FILE *stream)); data/gzip-1.10/lib/stdio.in.h:262:19: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). _GL_CXXALIASWARN (fgetc); data/gzip-1.10/lib/stdio.in.h:641:11: [1] (buffer) getc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). # undef getc data/gzip-1.10/lib/stdio.in.h:642:12: [1] (buffer) getc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). # define getc rpl_fgetc data/gzip-1.10/lib/stdio.in.h:644:19: [1] (buffer) fgetc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). _GL_FUNCDECL_RPL (fgetc, int, (FILE *stream) _GL_ARG_NONNULL ((1))); data/gzip-1.10/lib/stdio.in.h:645:21: [1] (buffer) getc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). _GL_CXXALIAS_RPL_1 (getc, rpl_fgetc, int, (FILE *stream)); data/gzip-1.10/lib/stdio.in.h:647:19: [1] (buffer) getc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). _GL_CXXALIAS_SYS (getc, int, (FILE *stream)); data/gzip-1.10/lib/stdio.in.h:649:19: [1] (buffer) getc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). _GL_CXXALIASWARN (getc); data/gzip-1.10/lib/stdio.in.h:655:11: [1] (buffer) getchar: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). # undef getchar data/gzip-1.10/lib/stdio.in.h:656:12: [1] (buffer) getchar: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). # define getchar rpl_getchar data/gzip-1.10/lib/stdio.in.h:658:19: [1] (buffer) getchar: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). _GL_FUNCDECL_RPL (getchar, int, (void)); data/gzip-1.10/lib/stdio.in.h:659:19: [1] (buffer) getchar: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). _GL_CXXALIAS_RPL (getchar, int, (void)); data/gzip-1.10/lib/stdio.in.h:661:19: [1] (buffer) getchar: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). _GL_CXXALIAS_SYS (getchar, int, (void)); data/gzip-1.10/lib/stdio.in.h:663:19: [1] (buffer) getchar: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). _GL_CXXALIASWARN (getchar); data/gzip-1.10/lib/strdup.c:41:16: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). size_t len = strlen (s) + 1; data/gzip-1.10/lib/strerror.c:65:9: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). len = strlen (msg); data/gzip-1.10/lib/strerror_r.c:131:16: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). size_t len = strlen (msg); data/gzip-1.10/lib/strerror_r.c:217:17: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). if (!ret && strlen (buf) == buflen - 1) data/gzip-1.10/lib/strerror_r.c:222:15: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). len = strlen (stackbuf); data/gzip-1.10/lib/strerror_r.c:236:26: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). if (ret == ERANGE && strlen (buf) < buflen - 1) data/gzip-1.10/lib/string.in.h:411:11: [1] (buffer) strncat: Easily used incorrectly (e.g., incorrectly computing the correct maximum size to add) [MS-banned] (CWE-120). Consider strcat_s, strlcat, snprintf, or automatically resizing strings. # undef strncat data/gzip-1.10/lib/string.in.h:412:12: [1] (buffer) strncat: Easily used incorrectly (e.g., incorrectly computing the correct maximum size to add) [MS-banned] (CWE-120). Consider strcat_s, strlcat, snprintf, or automatically resizing strings. # define strncat rpl_strncat data/gzip-1.10/lib/string.in.h:414:19: [1] (buffer) strncat: Easily used incorrectly (e.g., incorrectly computing the correct maximum size to add) [MS-banned] (CWE-120). Consider strcat_s, strlcat, snprintf, or automatically resizing strings. _GL_FUNCDECL_RPL (strncat, char *, (char *dest, const char *src, size_t n) data/gzip-1.10/lib/string.in.h:416:19: [1] (buffer) strncat: Easily used incorrectly (e.g., incorrectly computing the correct maximum size to add) [MS-banned] (CWE-120). Consider strcat_s, strlcat, snprintf, or automatically resizing strings. _GL_CXXALIAS_RPL (strncat, char *, (char *dest, const char *src, size_t n)); data/gzip-1.10/lib/string.in.h:418:19: [1] (buffer) strncat: Easily used incorrectly (e.g., incorrectly computing the correct maximum size to add) [MS-banned] (CWE-120). Consider strcat_s, strlcat, snprintf, or automatically resizing strings. _GL_CXXALIAS_SYS (strncat, char *, (char *dest, const char *src, size_t n)); data/gzip-1.10/lib/string.in.h:420:19: [1] (buffer) strncat: Easily used incorrectly (e.g., incorrectly computing the correct maximum size to add) [MS-banned] (CWE-120). Consider strcat_s, strlcat, snprintf, or automatically resizing strings. _GL_CXXALIASWARN (strncat); data/gzip-1.10/lib/string.in.h:422:9: [1] (buffer) strncat: Easily used incorrectly (e.g., incorrectly computing the correct maximum size to add) [MS-banned] (CWE-120). Consider strcat_s, strlcat, snprintf, or automatically resizing strings. # undef strncat data/gzip-1.10/lib/string.in.h:424:18: [1] (buffer) strncat: Easily used incorrectly (e.g., incorrectly computing the correct maximum size to add) [MS-banned] (CWE-120). Consider strcat_s, strlcat, snprintf, or automatically resizing strings. _GL_WARN_ON_USE (strncat, "strncat is unportable - " data/gzip-1.10/lib/unistd.in.h:1297:11: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). # undef read data/gzip-1.10/lib/unistd.in.h:1298:12: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). # define read rpl_read data/gzip-1.10/lib/unistd.in.h:1300:19: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). _GL_FUNCDECL_RPL (read, ssize_t, (int fd, void *buf, size_t count) data/gzip-1.10/lib/unistd.in.h:1302:19: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). _GL_CXXALIAS_RPL (read, ssize_t, (int fd, void *buf, size_t count)); data/gzip-1.10/lib/unistd.in.h:1307:24: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). _GL_CXXALIAS_SYS_CAST (read, ssize_t, (int fd, void *buf, size_t count)); data/gzip-1.10/lib/unistd.in.h:1309:19: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). _GL_CXXALIASWARN (read); data/gzip-1.10/lib/unistd.in.h:1622:11: [1] (obsolete) usleep: This C routine is considered obsolete (as opposed to the shell command by the same name). The interaction of this function with SIGALRM and other timer functions such as sleep(), alarm(), setitimer(), and nanosleep() is unspecified (CWE-676). Use nanosleep(2) or setitimer(2) instead. # undef usleep data/gzip-1.10/lib/unistd.in.h:1623:12: [1] (obsolete) usleep: This C routine is considered obsolete (as opposed to the shell command by the same name). The interaction of this function with SIGALRM and other timer functions such as sleep(), alarm(), setitimer(), and nanosleep() is unspecified (CWE-676). Use nanosleep(2) or setitimer(2) instead. # define usleep rpl_usleep data/gzip-1.10/lib/unistd.in.h:1625:19: [1] (obsolete) usleep: This C routine is considered obsolete (as opposed to the shell command by the same name). The interaction of this function with SIGALRM and other timer functions such as sleep(), alarm(), setitimer(), and nanosleep() is unspecified (CWE-676). Use nanosleep(2) or setitimer(2) instead. _GL_FUNCDECL_RPL (usleep, int, (useconds_t n)); data/gzip-1.10/lib/unistd.in.h:1626:19: [1] (obsolete) usleep: This C routine is considered obsolete (as opposed to the shell command by the same name). The interaction of this function with SIGALRM and other timer functions such as sleep(), alarm(), setitimer(), and nanosleep() is unspecified (CWE-676). Use nanosleep(2) or setitimer(2) instead. _GL_CXXALIAS_RPL (usleep, int, (useconds_t n)); data/gzip-1.10/lib/unistd.in.h:1629:19: [1] (obsolete) usleep: This C routine is considered obsolete (as opposed to the shell command by the same name). The interaction of this function with SIGALRM and other timer functions such as sleep(), alarm(), setitimer(), and nanosleep() is unspecified (CWE-676). Use nanosleep(2) or setitimer(2) instead. _GL_FUNCDECL_SYS (usleep, int, (useconds_t n)); data/gzip-1.10/lib/unistd.in.h:1631:19: [1] (obsolete) usleep: This C routine is considered obsolete (as opposed to the shell command by the same name). The interaction of this function with SIGALRM and other timer functions such as sleep(), alarm(), setitimer(), and nanosleep() is unspecified (CWE-676). Use nanosleep(2) or setitimer(2) instead. _GL_CXXALIAS_SYS (usleep, int, (useconds_t n)); data/gzip-1.10/lib/unistd.in.h:1633:19: [1] (obsolete) usleep: This C routine is considered obsolete (as opposed to the shell command by the same name). The interaction of this function with SIGALRM and other timer functions such as sleep(), alarm(), setitimer(), and nanosleep() is unspecified (CWE-676). Use nanosleep(2) or setitimer(2) instead. _GL_CXXALIASWARN (usleep); data/gzip-1.10/lib/unistd.in.h:1635:9: [1] (obsolete) usleep: This C routine is considered obsolete (as opposed to the shell command by the same name). The interaction of this function with SIGALRM and other timer functions such as sleep(), alarm(), setitimer(), and nanosleep() is unspecified (CWE-676). Use nanosleep(2) or setitimer(2) instead. # undef usleep data/gzip-1.10/lib/unistd.in.h:1637:18: [1] (obsolete) usleep: This C routine is considered obsolete (as opposed to the shell command by the same name). The interaction of this function with SIGALRM and other timer functions such as sleep(), alarm(), setitimer(), and nanosleep() is unspecified (CWE-676). Use nanosleep(2) or setitimer(2) instead. _GL_WARN_ON_USE (usleep, "usleep is unportable - " data/gzip-1.10/lib/unlink.c:38:16: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). size_t len = strlen (name); data/gzip-1.10/lib/unlinkat.c:54:9: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). len = strlen (name); data/gzip-1.10/lib/utime.c:45:16: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). size_t len = strlen (name); data/gzip-1.10/lib/vasnprintf.c:240:24: [1] (buffer) wcslen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). # define local_wcslen wcslen data/gzip-1.10/lib/vasnprintf.c:1744:26: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). tmp_length = strlen (arg); data/gzip-1.10/lib/vasnprintf.c:2576:39: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). arg_end = arg + strlen (arg); data/gzip-1.10/lib/vasnprintf.c:3663:43: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). ndigits = strlen (digits); data/gzip-1.10/lib/vasnprintf.c:3723:51: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). ndigits = strlen (digits); data/gzip-1.10/lib/vasnprintf.c:3759:45: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). if (strlen (digits2) == precision + 1) data/gzip-1.10/lib/vasnprintf.c:3859:51: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). ndigits = strlen (digits); data/gzip-1.10/lib/vasnprintf.c:3895:45: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). if (strlen (digits2) == precision) data/gzip-1.10/lib/vasnprintf.c:4125:43: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). ndigits = strlen (digits); data/gzip-1.10/lib/vasnprintf.c:4182:51: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). ndigits = strlen (digits); data/gzip-1.10/lib/vasnprintf.c:4217:45: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). if (strlen (digits2) == precision + 1) data/gzip-1.10/lib/vasnprintf.c:4330:51: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). ndigits = strlen (digits); data/gzip-1.10/lib/vasnprintf.c:4365:45: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). if (strlen (digits2) == precision) data/gzip-1.10/lib/wchar.in.h:574:19: [1] (buffer) wcslen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). _GL_FUNCDECL_SYS (wcslen, size_t, (const wchar_t *s) _GL_ATTRIBUTE_PURE); data/gzip-1.10/lib/wchar.in.h:576:19: [1] (buffer) wcslen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). _GL_CXXALIAS_SYS (wcslen, size_t, (const wchar_t *s)); data/gzip-1.10/lib/wchar.in.h:577:19: [1] (buffer) wcslen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). _GL_CXXALIASWARN (wcslen); data/gzip-1.10/lib/wchar.in.h:579:9: [1] (buffer) wcslen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). # undef wcslen data/gzip-1.10/lib/wchar.in.h:581:18: [1] (buffer) wcslen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). _GL_WARN_ON_USE (wcslen, "wcslen is unportable - " data/gzip-1.10/lib/wchar.in.h:639:19: [1] (buffer) wcsncpy: Easily used incorrectly; doesn't always \0-terminate or check for invalid pointers [MS-banned] (CWE-120). _GL_FUNCDECL_SYS (wcsncpy, wchar_t *, data/gzip-1.10/lib/wchar.in.h:642:19: [1] (buffer) wcsncpy: Easily used incorrectly; doesn't always \0-terminate or check for invalid pointers [MS-banned] (CWE-120). _GL_CXXALIAS_SYS (wcsncpy, wchar_t *, data/gzip-1.10/lib/wchar.in.h:644:19: [1] (buffer) wcsncpy: Easily used incorrectly; doesn't always \0-terminate or check for invalid pointers [MS-banned] (CWE-120). _GL_CXXALIASWARN (wcsncpy); data/gzip-1.10/lib/wchar.in.h:646:9: [1] (buffer) wcsncpy: Easily used incorrectly; doesn't always \0-terminate or check for invalid pointers [MS-banned] (CWE-120). # undef wcsncpy data/gzip-1.10/lib/wchar.in.h:648:18: [1] (buffer) wcsncpy: Easily used incorrectly; doesn't always \0-terminate or check for invalid pointers [MS-banned] (CWE-120). _GL_WARN_ON_USE (wcsncpy, "wcsncpy is unportable - " data/gzip-1.10/lib/wchar.in.h:692:19: [1] (buffer) wcsncat: Easily used incorrectly (e.g., incorrectly computing the correct maximum size to add) [MS-banned] (CWE-120). Consider strcat_s, strlcat, or automatically resizing strings. _GL_FUNCDECL_SYS (wcsncat, wchar_t *, data/gzip-1.10/lib/wchar.in.h:695:19: [1] (buffer) wcsncat: Easily used incorrectly (e.g., incorrectly computing the correct maximum size to add) [MS-banned] (CWE-120). Consider strcat_s, strlcat, or automatically resizing strings. _GL_CXXALIAS_SYS (wcsncat, wchar_t *, data/gzip-1.10/lib/wchar.in.h:697:19: [1] (buffer) wcsncat: Easily used incorrectly (e.g., incorrectly computing the correct maximum size to add) [MS-banned] (CWE-120). Consider strcat_s, strlcat, or automatically resizing strings. _GL_CXXALIASWARN (wcsncat); data/gzip-1.10/lib/wchar.in.h:699:9: [1] (buffer) wcsncat: Easily used incorrectly (e.g., incorrectly computing the correct maximum size to add) [MS-banned] (CWE-120). Consider strcat_s, strlcat, or automatically resizing strings. # undef wcsncat data/gzip-1.10/lib/wchar.in.h:701:18: [1] (buffer) wcsncat: Easily used incorrectly (e.g., incorrectly computing the correct maximum size to add) [MS-banned] (CWE-120). Consider strcat_s, strlcat, or automatically resizing strings. _GL_WARN_ON_USE (wcsncat, "wcsncat is unportable - " data/gzip-1.10/lib/xmalloc.c:121:27: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). return xmemdup (string, strlen (string) + 1); data/gzip-1.10/lib/yesno.c:56:11: [1] (buffer) getchar: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). int c = getchar (); data/gzip-1.10/lib/yesno.c:59:9: [1] (buffer) getchar: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). c = getchar (); data/gzip-1.10/sample/add.c:26:7: [1] (buffer) getchar: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). if (getchar() != MAGIC1 || getchar() != MAGIC2) data/gzip-1.10/sample/add.c:26:30: [1] (buffer) getchar: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). if (getchar() != MAGIC1 || getchar() != MAGIC2) data/gzip-1.10/sample/add.c:33:12: [1] (buffer) getchar: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). if ((n = getchar()) == EOF || (i = getchar()) == EOF) { data/gzip-1.10/sample/add.c:33:38: [1] (buffer) getchar: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). if ((n = getchar()) == EOF || (i = getchar()) == EOF) { data/gzip-1.10/sample/add.c:50:15: [1] (buffer) getchar: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). while ((c = getchar()) != EOF) data/gzip-1.10/sample/sub.c:81:15: [1] (buffer) getchar: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). while ((c = getchar()) != EOF) data/gzip-1.10/sample/zread.c:28:9: [1] (buffer) strncat: Easily used incorrectly (e.g., incorrectly computing the correct maximum size to add) [MS-banned] (CWE-120). Consider strcat_s, strlcat, snprintf, or automatically resizing strings. strncat(cmd, argv[1], sizeof(cmd)-strlen(cmd)); data/gzip-1.10/sample/zread.c:28:43: [1] (buffer) strlen: Does not handle strings that are not \0-terminated; if given one it may perform an over-read (it could cause a crash if unprotected) (CWE-126). strncat(cmd, argv[1], sizeof(cmd)-strlen(cmd)); data/gzip-1.10/sample/zread.c:36:9: [1] (buffer) getc: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). n = getc(infile); data/gzip-1.10/util.c:200:9: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). len = read (fd, buf, cnt); data/gzip-1.10/util.c:213:19: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). len = read (fd, buf, cnt); ANALYSIS SUMMARY: Hits = 597 Lines analyzed = 50116 in approximately 1.47 seconds (34072 lines/second) Physical Source Lines of Code (SLOC) = 33310 Hits@level = [0] 139 [1] 153 [2] 184 [3] 55 [4] 180 [5] 25 Hits@level+ = [0+] 736 [1+] 597 [2+] 444 [3+] 260 [4+] 205 [5+] 25 Hits/KSLOC@level+ = [0+] 22.0955 [1+] 17.9225 [2+] 13.3293 [3+] 7.80546 [4+] 6.15431 [5+] 0.750525 Dot directories skipped = 1 (--followdotdir overrides) Minimum risk level = 1 Not every hit is necessarily a security vulnerability. There may be other security vulnerabilities; review your code! See 'Secure Programming HOWTO' (https://dwheeler.com/secure-programs) for more information.