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/node-nodedbi-1.0.14/src/connection.cpp Examining data/node-nodedbi-1.0.14/src/query.cpp Examining data/node-nodedbi-1.0.14/src/connection.h Examining data/node-nodedbi-1.0.14/src/query.h FINAL RESULTS: data/node-nodedbi-1.0.14/src/query.cpp:194: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( fmtQuery, quoted ); data/node-nodedbi-1.0.14/src/query.cpp:212: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( fmtQuery, numStr ); data/node-nodedbi-1.0.14/src/query.cpp:229: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( fmtQuery, numStr ); data/node-nodedbi-1.0.14/src/query.cpp:246: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( fmtQuery, numStr ); data/node-nodedbi-1.0.14/src/connection.cpp:85: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 ckey[32]; data/node-nodedbi-1.0.14/src/connection.cpp:86: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 cval[64]; data/node-nodedbi-1.0.14/src/connection.cpp:210: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 fieldChar[ fieldName->Length() + 1 ]; data/node-nodedbi-1.0.14/src/query.cpp:85: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 idxStr[6]; data/node-nodedbi-1.0.14/src/query.cpp:137: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). idx = atoi(idxStr); // Start at %1, actually is arg position 1 luckily. data/node-nodedbi-1.0.14/src/query.cpp:201: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 numStr[32]; data/node-nodedbi-1.0.14/src/query.cpp:218: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 numStr[32]; data/node-nodedbi-1.0.14/src/query.cpp:235: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 numStr[32]; data/node-nodedbi-1.0.14/src/query.cpp:89: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). int qlen = strlen( rawQuery ); data/node-nodedbi-1.0.14/src/query.cpp:203: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). int len = strlen(numStr); data/node-nodedbi-1.0.14/src/query.cpp:220: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). int len = strlen(numStr); data/node-nodedbi-1.0.14/src/query.cpp:237: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). int len = strlen(numStr); ANALYSIS SUMMARY: Hits = 16 Lines analyzed = 844 in approximately 0.05 seconds (16525 lines/second) Physical Source Lines of Code (SLOC) = 655 Hits@level = [0] 3 [1] 4 [2] 8 [3] 0 [4] 4 [5] 0 Hits@level+ = [0+] 19 [1+] 16 [2+] 12 [3+] 4 [4+] 4 [5+] 0 Hits/KSLOC@level+ = [0+] 29.0076 [1+] 24.4275 [2+] 18.3206 [3+] 6.10687 [4+] 6.10687 [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.