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/libnetfilter-acct-1.0.3/examples/nfacct-del.c Examining data/libnetfilter-acct-1.0.3/examples/nfacct-add.c Examining data/libnetfilter-acct-1.0.3/examples/nfacct-get.c Examining data/libnetfilter-acct-1.0.3/src/internal.h Examining data/libnetfilter-acct-1.0.3/src/libnetfilter_acct.c Examining data/libnetfilter-acct-1.0.3/include/linux/netfilter/nfnetlink_acct.h Examining data/libnetfilter-acct-1.0.3/include/linux/netfilter/nfnetlink.h Examining data/libnetfilter-acct-1.0.3/include/libnetfilter_acct/libnetfilter_acct.h FINAL RESULTS: data/libnetfilter-acct-1.0.3/examples/nfacct-add.c:11: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[MNL_SOCKET_BUFFER_SIZE]; data/libnetfilter-acct-1.0.3/examples/nfacct-del.c:11: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[MNL_SOCKET_BUFFER_SIZE]; data/libnetfilter-acct-1.0.3/examples/nfacct-get.c:11: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[4096]; data/libnetfilter-acct-1.0.3/examples/nfacct-get.c:37: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[MNL_SOCKET_BUFFER_SIZE]; data/libnetfilter-acct-1.0.3/src/libnetfilter_acct.c:60: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 name[NFACCT_NAME_MAX]; data/libnetfilter-acct-1.0.3/examples/nfacct-get.c:48:42: [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 (argc == 2 && strncmp(argv[1], "-z", strlen("-z")) == 0) data/libnetfilter-acct-1.0.3/src/libnetfilter_acct.c:107:3: [1] (buffer) strncpy: Easily used incorrectly; doesn't always \0-terminate or check for invalid pointers [MS-banned] (CWE-120). strncpy(nfacct->name, data, NFACCT_NAME_MAX); ANALYSIS SUMMARY: Hits = 7 Lines analyzed = 1017 in approximately 0.05 seconds (19117 lines/second) Physical Source Lines of Code (SLOC) = 701 Hits@level = [0] 20 [1] 2 [2] 5 [3] 0 [4] 0 [5] 0 Hits@level+ = [0+] 27 [1+] 7 [2+] 5 [3+] 0 [4+] 0 [5+] 0 Hits/KSLOC@level+ = [0+] 38.5164 [1+] 9.98573 [2+] 7.13267 [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.