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/liblaxjson-1.0.5/example/token_list.c Examining data/liblaxjson-1.0.5/include/laxjson.h Examining data/liblaxjson-1.0.5/src/laxjson.c Examining data/liblaxjson-1.0.5/test/primitives.c FINAL RESULTS: data/liblaxjson-1.0.5/example/token_list.c:54:5: [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[1024]; data/liblaxjson-1.0.5/example/token_list.c:69:9: [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). f = fopen("file.json", "rb"); data/liblaxjson-1.0.5/test/primitives.c:6:8: [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. static char out_buf[16384]; data/liblaxjson-1.0.5/test/primitives.c:12:5: [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(&out_buf[out_buf_index], str, len); data/liblaxjson-1.0.5/test/primitives.c:11:15: [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(str); data/liblaxjson-1.0.5/test/primitives.c:39:16: [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 size = strlen(data); data/liblaxjson-1.0.5/test/primitives.c:86:24: [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 expected_len = strlen(output); data/liblaxjson-1.0.5/test/primitives.c:135:16: [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 size = strlen(input); ANALYSIS SUMMARY: Hits = 8 Lines analyzed = 1399 in approximately 0.08 seconds (16500 lines/second) Physical Source Lines of Code (SLOC) = 1202 Hits@level = [0] 21 [1] 4 [2] 4 [3] 0 [4] 0 [5] 0 Hits@level+ = [0+] 29 [1+] 8 [2+] 4 [3+] 0 [4+] 0 [5+] 0 Hits/KSLOC@level+ = [0+] 24.1265 [1+] 6.65557 [2+] 3.32779 [3+] 0 [4+] 0 [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.