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/libidl-0.8.14/include/libIDL/IDL.h Examining data/libidl-0.8.14/util.c Examining data/libidl-0.8.14/util.h Examining data/libidl-0.8.14/ns.c Examining data/libidl-0.8.14/tstidl.c Examining data/libidl-0.8.14/rename.h FINAL RESULTS: data/libidl-0.8.14/ns.c:330:4: [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 (s, join); data/libidl-0.8.14/ns.c:331:3: [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 (s, IDL_IDENT (i).str); data/libidl-0.8.14/util.c:41: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. #define popen _popen data/libidl-0.8.14/util.c:265:6: [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. if (access (filename, R_OK)) data/libidl-0.8.14/util.c:317: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. input = popen (cmd, "r"); data/libidl-0.8.14/util.c:323: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. input = popen (cmd, "r"); data/libidl-0.8.14/util.c:325:10: [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. input = popen (cmd, "r"); data/libidl-0.8.14/util.c:328: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. #error Must have popen data/libidl-0.8.14/util.c:2544:3: [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 (data->u.o, fmt, args); data/libidl-0.8.14/util.c:2568:3: [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 (data->u.o, fmt, args); data/libidl-0.8.14/util.c:281:6: [3] (tmpfile) tmpnam: Temporary file race condition (CWE-377). s = tmpnam (NULL); data/libidl-0.8.14/tstidl.c:154:17: [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). my_data->in = fopen (cb_data->init.filename, "r"); data/libidl-0.8.14/util.c:234: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 cwd[2048]; data/libidl-0.8.14/util.c:315: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 null = open ("NUL:", O_WRONLY); data/libidl-0.8.14/util.c:2135:4: [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 hex[3]; data/libidl-0.8.14/util.c:2146:4: [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 oct[4]; data/libidl-0.8.14/ns.c:102:6: [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). l = strlen (r); data/libidl-0.8.14/ns.c:300: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). joinlen = strlen (join); data/libidl-0.8.14/ns.c:306: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 (IDL_IDENT (i).str) + joinlen; data/libidl-0.8.14/util.c:2126: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). p = q = g_malloc (strlen (s) + 1); data/libidl-0.8.14/util.c:2140:10: [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). s += strlen (hex); data/libidl-0.8.14/util.c:2150:10: [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). s += strlen (oct); ANALYSIS SUMMARY: Hits = 22 Lines analyzed = 5552 in approximately 0.25 seconds (21897 lines/second) Physical Source Lines of Code (SLOC) = 4357 Hits@level = [0] 15 [1] 6 [2] 5 [3] 1 [4] 10 [5] 0 Hits@level+ = [0+] 37 [1+] 22 [2+] 16 [3+] 11 [4+] 10 [5+] 0 Hits/KSLOC@level+ = [0+] 8.49208 [1+] 5.04935 [2+] 3.67225 [3+] 2.52467 [4+] 2.29516 [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.