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/mod-dnssd-0.6/src/mod_dnssd.c FINAL RESULTS: data/mod-dnssd-0.6/src/mod_dnssd.c:294:17: [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(path, X_OK) != 0) data/mod-dnssd-0.6/src/mod_dnssd.c:160:51: [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). default_port = (uint16_t) atoi(colon+1); data/mod-dnssd-0.6/src/mod_dnssd.c:177:43: [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). default_port = (uint16_t) atoi(sp); data/mod-dnssd-0.6/src/mod_dnssd.c:181:39: [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). default_port = (uint16_t) atoi(a); data/mod-dnssd-0.6/src/mod_dnssd.c:192:36: [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). vport = (uint16_t) atoi(colon+1); data/mod-dnssd-0.6/src/mod_dnssd.c:208:48: [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). vport = (uint16_t) atoi(colon+1); data/mod-dnssd-0.6/src/mod_dnssd.c:220:40: [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). vport = (uint16_t) atoi(a); data/mod-dnssd-0.6/src/mod_dnssd.c:245:48: [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). sport = (uint16_t) atoi(a); data/mod-dnssd-0.6/src/mod_dnssd.c:829: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). i = atoi(value); data/mod-dnssd-0.6/src/mod_dnssd.c:232:50: [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 (*path != 0 && (path[(i = strlen(path) - 1)] == '>')) data/mod-dnssd-0.6/src/mod_dnssd.c:566:9: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). l = read(fd, &c, sizeof(c)); ANALYSIS SUMMARY: Hits = 11 Lines analyzed = 920 in approximately 0.04 seconds (24698 lines/second) Physical Source Lines of Code (SLOC) = 653 Hits@level = [0] 0 [1] 2 [2] 8 [3] 0 [4] 1 [5] 0 Hits@level+ = [0+] 11 [1+] 11 [2+] 9 [3+] 1 [4+] 1 [5+] 0 Hits/KSLOC@level+ = [0+] 16.8453 [1+] 16.8453 [2+] 13.7825 [3+] 1.53139 [4+] 1.53139 [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.