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/libabw-0.1.3/src/fuzz/abwfuzzer.cpp Examining data/libabw-0.1.3/src/lib/libabw_internal.h Examining data/libabw-0.1.3/src/lib/ABWXMLHelper.cpp Examining data/libabw-0.1.3/src/lib/ABWCollector.cpp Examining data/libabw-0.1.3/src/lib/libabw_internal.cpp Examining data/libabw-0.1.3/src/lib/AbiDocument.cpp Examining data/libabw-0.1.3/src/lib/ABWContentCollector.cpp Examining data/libabw-0.1.3/src/lib/tokens.h Examining data/libabw-0.1.3/src/lib/ABWZlibStream.cpp Examining data/libabw-0.1.3/src/lib/ABWStylesCollector.h Examining data/libabw-0.1.3/src/lib/ABWCollector.h Examining data/libabw-0.1.3/src/lib/ABWXMLTokenMap.h Examining data/libabw-0.1.3/src/lib/ABWParser.cpp Examining data/libabw-0.1.3/src/lib/tokenhash.h Examining data/libabw-0.1.3/src/lib/ABWContentCollector.h Examining data/libabw-0.1.3/src/lib/ABWStylesCollector.cpp Examining data/libabw-0.1.3/src/lib/ABWZlibStream.h Examining data/libabw-0.1.3/src/lib/ABWParser.h Examining data/libabw-0.1.3/src/lib/ABWOutputElements.cpp Examining data/libabw-0.1.3/src/lib/ABWOutputElements.h Examining data/libabw-0.1.3/src/lib/ABWXMLHelper.h Examining data/libabw-0.1.3/src/lib/ABWXMLTokenMap.cpp Examining data/libabw-0.1.3/src/conv/raw/abw2raw.cpp Examining data/libabw-0.1.3/src/conv/text/abw2text.cpp Examining data/libabw-0.1.3/src/conv/html/abw2html.cpp Examining data/libabw-0.1.3/inc/libabw/libabw.h Examining data/libabw-0.1.3/inc/libabw/AbiDocument.h FINAL RESULTS: data/libabw-0.1.3/src/lib/libabw_internal.cpp:22:8: [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. std::vfprintf(stderr, format, args); data/libabw-0.1.3/src/lib/libabw_internal.h:20:62: [4] (format) printf: If format strings can be influenced by an attacker, they can be exploited (CWE-134). Use a constant for the format specification. #define ABW_ATTRIBUTE_PRINTF(fmt, arg) __attribute__((format(printf, fmt, arg))) data/libabw-0.1.3/src/lib/ABWContentCollector.cpp:539:10: [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 const *odtWh[4]= {"fo:border-left", "fo:border-right", "fo:border-top", "fo:border-bottom"}; data/libabw-0.1.3/src/lib/ABWContentCollector.cpp:542:12: [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 const *wh[4]= {"left", "right", "top", "bot"}; data/libabw-0.1.3/src/lib/ABWXMLHelper.cpp:44:7: [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(buffer, tmpBuffer, tmpNumBytesRead); data/libabw-0.1.3/src/lib/ABWZlibStream.cpp:26:12: [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. unsigned char in[BLOCK_SIZE]; data/libabw-0.1.3/src/lib/ABWZlibStream.cpp:27:12: [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. unsigned char out[BLOCK_SIZE]; data/libabw-0.1.3/src/lib/ABWZlibStream.cpp:45: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(in, p, strm.avail_in); data/libabw-0.1.3/src/lib/ABWXMLHelper.cpp:41:45: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). const unsigned char *tmpBuffer = input->read((unsigned long) len, tmpNumBytesRead); data/libabw-0.1.3/src/lib/ABWZlibStream.cpp:41:37: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). const unsigned char *p = input->read(BLOCK_SIZE, numBytesRead); data/libabw-0.1.3/src/lib/ABWZlibStream.cpp:98:37: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). const unsigned char *ABWZlibStream::read(unsigned long numBytes, unsigned long &numBytesRead) data/libabw-0.1.3/src/lib/ABWZlibStream.cpp:101:21: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). return m_input->read(numBytes, numBytesRead); data/libabw-0.1.3/src/lib/ABWZlibStream.h:49:24: [1] (buffer) read: Check buffer boundaries if used in a loop including recursive loops (CWE-120, CWE-20). const unsigned char *read(unsigned long numBytes, unsigned long &numBytesRead) override; ANALYSIS SUMMARY: Hits = 13 Lines analyzed = 6791 in approximately 0.26 seconds (26248 lines/second) Physical Source Lines of Code (SLOC) = 5609 Hits@level = [0] 37 [1] 5 [2] 6 [3] 0 [4] 2 [5] 0 Hits@level+ = [0+] 50 [1+] 13 [2+] 8 [3+] 2 [4+] 2 [5+] 0 Hits/KSLOC@level+ = [0+] 8.91424 [1+] 2.3177 [2+] 1.42628 [3+] 0.35657 [4+] 0.35657 [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.