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/haskell-streaming-commons-0.2.2.1/cbits/zlib-helper.c Examining data/haskell-streaming-commons-0.2.2.1/cbits/text-helper.c Examining data/haskell-streaming-commons-0.2.2.1/include/inffixed.h Examining data/haskell-streaming-commons-0.2.2.1/include/zlib.h Examining data/haskell-streaming-commons-0.2.2.1/include/inflate.h Examining data/haskell-streaming-commons-0.2.2.1/include/inftrees.h Examining data/haskell-streaming-commons-0.2.2.1/include/crc32.h Examining data/haskell-streaming-commons-0.2.2.1/include/text_cbits.h Examining data/haskell-streaming-commons-0.2.2.1/include/trees.h Examining data/haskell-streaming-commons-0.2.2.1/include/zconf.h Examining data/haskell-streaming-commons-0.2.2.1/include/inffast.h Examining data/haskell-streaming-commons-0.2.2.1/include/deflate.h Examining data/haskell-streaming-commons-0.2.2.1/include/zutil.h FINAL RESULTS: data/haskell-streaming-commons-0.2.2.1/include/zutil.h:199: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. # if !defined(vsnprintf) && !defined(NO_vsnprintf) data/haskell-streaming-commons-0.2.2.1/include/zutil.h:200:15: [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 _vsnprintf data/haskell-streaming-commons-0.2.2.1/include/zutil.h:246:39: [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) {if (z_verbose>=0) fprintf x ;} data/haskell-streaming-commons-0.2.2.1/include/zutil.h:247:39: [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 (z_verbose>0) fprintf x ;} data/haskell-streaming-commons-0.2.2.1/include/zutil.h:248:40: [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 (z_verbose>1) fprintf x ;} data/haskell-streaming-commons-0.2.2.1/include/zutil.h:249:48: [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 (z_verbose>0 && (c)) fprintf x ;} data/haskell-streaming-commons-0.2.2.1/include/zutil.h:250:49: [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 (z_verbose>1 && (c)) fprintf x ;} data/haskell-streaming-commons-0.2.2.1/cbits/text-helper.c:19: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(cdest + (doff<<1), csrc + (soff<<1), n<<1); data/haskell-streaming-commons-0.2.2.1/include/zutil.h:53: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. extern const char * const z_errmsg[10]; /* indexed by 2-zlib_error */ data/haskell-streaming-commons-0.2.2.1/include/zutil.h:111:6: [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). fopen((name), (mode), "mbc=60", "ctx=stm", "rfm=fix", "mrs=512") data/haskell-streaming-commons-0.2.2.1/include/zutil.h:173:30: [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 F_OPEN(name, mode) fopen((name), (mode)) data/haskell-streaming-commons-0.2.2.1/include/zutil.h:230: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 zmemcpy memcpy ANALYSIS SUMMARY: Hits = 12 Lines analyzed = 3561 in approximately 0.22 seconds (15899 lines/second) Physical Source Lines of Code (SLOC) = 1813 Hits@level = [0] 0 [1] 0 [2] 5 [3] 0 [4] 7 [5] 0 Hits@level+ = [0+] 12 [1+] 12 [2+] 12 [3+] 7 [4+] 7 [5+] 0 Hits/KSLOC@level+ = [0+] 6.61886 [1+] 6.61886 [2+] 6.61886 [3+] 3.861 [4+] 3.861 [5+] 0 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.