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/farbfeld-4/ff2png.c Examining data/farbfeld-4/arg.h Examining data/farbfeld-4/util.h Examining data/farbfeld-4/ff2jpg.c Examining data/farbfeld-4/ff2ppm.c Examining data/farbfeld-4/png2ff.c Examining data/farbfeld-4/ff2pam.c Examining data/farbfeld-4/util.c Examining data/farbfeld-4/jpg2ff.c FINAL RESULTS: data/farbfeld-4/util.c:24:2: [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, fmt, ap); data/farbfeld-4/util.c:98:6: [4] (buffer) sscanf: 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. If the scanf format is influenceable by an attacker, it's exploitable. if (sscanf(s, fmt, col, col + 1, col + 2) != 3) { data/farbfeld-4/util.c:86:18: [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. parse_mask(const char *s, uint16_t mask[3]) data/farbfeld-4/util.h:15: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. int parse_mask(const char *, uint16_t mask[3]); data/farbfeld-4/util.c:26: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). if (fmt[0] && fmt[strlen(fmt) - 1] == ':') { data/farbfeld-4/util.c:92: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). slen = strlen(s); ANALYSIS SUMMARY: Hits = 6 Lines analyzed = 824 in approximately 0.07 seconds (11069 lines/second) Physical Source Lines of Code (SLOC) = 622 Hits@level = [0] 6 [1] 2 [2] 2 [3] 0 [4] 2 [5] 0 Hits@level+ = [0+] 12 [1+] 6 [2+] 4 [3+] 2 [4+] 2 [5+] 0 Hits/KSLOC@level+ = [0+] 19.2926 [1+] 9.6463 [2+] 6.43087 [3+] 3.21543 [4+] 3.21543 [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.