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/parsec47-0.2.dfsg1/src/dirent_d.c FINAL RESULTS: data/parsec47-0.2.dfsg1/src/dirent_d.c:19:2: [4] (buffer) sprintf: Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or vsnprintf. sprintf(buf, "%s/*", dir); data/parsec47-0.2.dfsg1/src/dirent_d.c:33: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(d->prev, fd.cFileName); data/parsec47-0.2.dfsg1/src/dirent_d.c:17:2: [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[MAX_PATH]; data/parsec47-0.2.dfsg1/src/dirent_d.c:32: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). d->prev = malloc(sizeof(char) * strlen(fd.cFileName)); ANALYSIS SUMMARY: Hits = 4 Lines analyzed = 59 in approximately 0.06 seconds (1061 lines/second) Physical Source Lines of Code (SLOC) = 47 Hits@level = [0] 0 [1] 1 [2] 1 [3] 0 [4] 2 [5] 0 Hits@level+ = [0+] 4 [1+] 4 [2+] 3 [3+] 2 [4+] 2 [5+] 0 Hits/KSLOC@level+ = [0+] 85.1064 [1+] 85.1064 [2+] 63.8298 [3+] 42.5532 [4+] 42.5532 [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.