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/modsecurity-3.0.4/tools/rules-check/rules-check.cc
Examining data/modsecurity-3.0.4/test/unit/unit_test.h
Examining data/modsecurity-3.0.4/test/unit/unit_test.cc
Examining data/modsecurity-3.0.4/test/unit/unit.cc
Examining data/modsecurity-3.0.4/test/regression/regression_test.h
Examining data/modsecurity-3.0.4/test/regression/regression_test.cc
Examining data/modsecurity-3.0.4/test/regression/regression.cc
Examining data/modsecurity-3.0.4/test/regression/custom_debug_log.h
Examining data/modsecurity-3.0.4/test/regression/custom_debug_log.cc
Examining data/modsecurity-3.0.4/test/optimization/optimization.cc
Examining data/modsecurity-3.0.4/test/fuzzer/afl_fuzzer.cc
Examining data/modsecurity-3.0.4/test/common/modsecurity_test_results.h
Examining data/modsecurity-3.0.4/test/common/modsecurity_test.h
Examining data/modsecurity-3.0.4/test/common/modsecurity_test.cc
Examining data/modsecurity-3.0.4/test/common/colors.h
Examining data/modsecurity-3.0.4/test/benchmark/benchmark.cc
Examining data/modsecurity-3.0.4/src/variables/xml.h
Examining data/modsecurity-3.0.4/src/variables/xml.cc
Examining data/modsecurity-3.0.4/src/variables/web_app_id.h
Examining data/modsecurity-3.0.4/src/variables/variable.h
Parsing failed to find end of parameter list; semicolon terminated it in (a.begin(), a.end(),
            m_key.begin(),
            [](char aa, char bb) {
                return static_cast<char>(toupper(aa)) == static_cast<char>(bb);
            });
    }

    std::strin
Parsing failed to find end of parameter list; semicolon terminated it in (a.begin(), a.end(), b.begin(),
            [](char aa, char bb) {
            return toupper(aa) == bb;
        });
    }

    static void stringMatchResolveMulti(Transaction *t,
        const std::s
Parsing failed to find end of parameter list; semicolon terminated it in (m_collectionName.begin(), m_collectionName.end(),
                           var->m_collectionName.begin(),
            [](char aa, char bb) {
            return toupper(aa) == bb;
        });
    }

Examining data/modsecurity-3.0.4/src/variables/variable.cc
Examining data/modsecurity-3.0.4/src/variables/user_id.h
Examining data/modsecurity-3.0.4/src/variables/user.h
Examining data/modsecurity-3.0.4/src/variables/url_encoded_error.h
Examining data/modsecurity-3.0.4/src/variables/unique_id.h
Examining data/modsecurity-3.0.4/src/variables/tx.h
Examining data/modsecurity-3.0.4/src/variables/tx.cc
Examining data/modsecurity-3.0.4/src/variables/time_year.h
Examining data/modsecurity-3.0.4/src/variables/time_year.cc
Examining data/modsecurity-3.0.4/src/variables/time_wday.h
Examining data/modsecurity-3.0.4/src/variables/time_wday.cc
Examining data/modsecurity-3.0.4/src/variables/time_sec.h
Examining data/modsecurity-3.0.4/src/variables/time_sec.cc
Examining data/modsecurity-3.0.4/src/variables/time_mon.h
Examining data/modsecurity-3.0.4/src/variables/time_mon.cc
Examining data/modsecurity-3.0.4/src/variables/time_min.h
Examining data/modsecurity-3.0.4/src/variables/time_min.cc
Examining data/modsecurity-3.0.4/src/variables/time_hour.h
Examining data/modsecurity-3.0.4/src/variables/time_hour.cc
Examining data/modsecurity-3.0.4/src/variables/time_epoch.h
Examining data/modsecurity-3.0.4/src/variables/time_epoch.cc
Examining data/modsecurity-3.0.4/src/variables/time_day.h
Examining data/modsecurity-3.0.4/src/variables/time_day.cc
Examining data/modsecurity-3.0.4/src/variables/time.h
Examining data/modsecurity-3.0.4/src/variables/time.cc
Examining data/modsecurity-3.0.4/src/variables/status.h
Examining data/modsecurity-3.0.4/src/variables/session_id.h
Examining data/modsecurity-3.0.4/src/variables/session.h
Examining data/modsecurity-3.0.4/src/variables/server_port.h
Examining data/modsecurity-3.0.4/src/variables/server_name.h
Examining data/modsecurity-3.0.4/src/variables/server_addr.h
Examining data/modsecurity-3.0.4/src/variables/rule.h
Examining data/modsecurity-3.0.4/src/variables/rule.cc
Examining data/modsecurity-3.0.4/src/variables/response_status.h
Examining data/modsecurity-3.0.4/src/variables/response_protocol.h
Examining data/modsecurity-3.0.4/src/variables/response_headers_names.h
Examining data/modsecurity-3.0.4/src/variables/response_headers.h
Examining data/modsecurity-3.0.4/src/variables/response_content_type.h
Examining data/modsecurity-3.0.4/src/variables/response_content_length.h
Examining data/modsecurity-3.0.4/src/variables/response_body.h
Examining data/modsecurity-3.0.4/src/variables/resource.h
Examining data/modsecurity-3.0.4/src/variables/request_uri_raw.h
Examining data/modsecurity-3.0.4/src/variables/request_uri.h
Examining data/modsecurity-3.0.4/src/variables/request_protocol.h
Examining data/modsecurity-3.0.4/src/variables/request_method.h
Examining data/modsecurity-3.0.4/src/variables/request_line.h
Examining data/modsecurity-3.0.4/src/variables/request_headers_names.h
Examining data/modsecurity-3.0.4/src/variables/request_headers.h
Examining data/modsecurity-3.0.4/src/variables/request_file_name.h
Examining data/modsecurity-3.0.4/src/variables/request_cookies_names.h
Examining data/modsecurity-3.0.4/src/variables/request_cookies.h
Examining data/modsecurity-3.0.4/src/variables/request_body_length.h
Examining data/modsecurity-3.0.4/src/variables/request_body.h
Examining data/modsecurity-3.0.4/src/variables/request_base_name.h
Examining data/modsecurity-3.0.4/src/variables/reqbody_processor_error_msg.h
Examining data/modsecurity-3.0.4/src/variables/reqbody_processor_error.h
Examining data/modsecurity-3.0.4/src/variables/reqbody_processor.h
Examining data/modsecurity-3.0.4/src/variables/reqbody_error_msg.h
Examining data/modsecurity-3.0.4/src/variables/reqbody_error.h
Examining data/modsecurity-3.0.4/src/variables/remote_user.h
Examining data/modsecurity-3.0.4/src/variables/remote_user.cc
Examining data/modsecurity-3.0.4/src/variables/remote_port.h
Examining data/modsecurity-3.0.4/src/variables/remote_host.h
Examining data/modsecurity-3.0.4/src/variables/remote_addr.h
Examining data/modsecurity-3.0.4/src/variables/query_string.h
Examining data/modsecurity-3.0.4/src/variables/path_info.h
Examining data/modsecurity-3.0.4/src/variables/outbound_data_error.h
Examining data/modsecurity-3.0.4/src/variables/multipart_unmatched_boundary.h
Examining data/modsecurity-3.0.4/src/variables/multipart_strict_error.h
Examining data/modsecurity-3.0.4/src/variables/multipart_name.h
Examining data/modsecurity-3.0.4/src/variables/multipart_missing_semicolon.h
Examining data/modsecurity-3.0.4/src/variables/multipart_lf_line.h
Examining data/modsecurity-3.0.4/src/variables/multipart_invalid_quoting.h
Examining data/modsecurity-3.0.4/src/variables/multipart_invalid_part.h
Examining data/modsecurity-3.0.4/src/variables/multipart_invalid_header_folding.h
Examining data/modsecurity-3.0.4/src/variables/multipart_header_folding.h
Examining data/modsecurity-3.0.4/src/variables/multipart_file_name.h
Examining data/modsecurity-3.0.4/src/variables/multipart_file_limit_exceeded.h
Examining data/modsecurity-3.0.4/src/variables/multipart_data_before.h
Examining data/modsecurity-3.0.4/src/variables/multipart_data_after.h
Examining data/modsecurity-3.0.4/src/variables/multipart_crlf_lf_lines.h
Examining data/modsecurity-3.0.4/src/variables/multipart_boundary_whitespace.h
Examining data/modsecurity-3.0.4/src/variables/multipart_boundary_quoted.h
Examining data/modsecurity-3.0.4/src/variables/modsec_build.h
Examining data/modsecurity-3.0.4/src/variables/modsec_build.cc
Examining data/modsecurity-3.0.4/src/variables/matched_vars_names.h
Examining data/modsecurity-3.0.4/src/variables/matched_vars.h
Examining data/modsecurity-3.0.4/src/variables/matched_var_name.h
Examining data/modsecurity-3.0.4/src/variables/matched_var.h
Examining data/modsecurity-3.0.4/src/variables/ip.h
Examining data/modsecurity-3.0.4/src/variables/inbound_data_error.h
Examining data/modsecurity-3.0.4/src/variables/highest_severity.h
Examining data/modsecurity-3.0.4/src/variables/highest_severity.cc
Examining data/modsecurity-3.0.4/src/variables/global.h
Examining data/modsecurity-3.0.4/src/variables/geo.h
Examining data/modsecurity-3.0.4/src/variables/full_request_length.h
Examining data/modsecurity-3.0.4/src/variables/full_request.h
Examining data/modsecurity-3.0.4/src/variables/files_tmp_names.h
Examining data/modsecurity-3.0.4/src/variables/files_tmp_content.h
Examining data/modsecurity-3.0.4/src/variables/files_sizes.h
Examining data/modsecurity-3.0.4/src/variables/files_names.h
Examining data/modsecurity-3.0.4/src/variables/files_combined_size.h
Examining data/modsecurity-3.0.4/src/variables/files.h
Examining data/modsecurity-3.0.4/src/variables/env.h
Examining data/modsecurity-3.0.4/src/variables/env.cc
Examining data/modsecurity-3.0.4/src/variables/duration.h
Examining data/modsecurity-3.0.4/src/variables/duration.cc
Examining data/modsecurity-3.0.4/src/variables/auth_type.h
Examining data/modsecurity-3.0.4/src/variables/args_post_names.h
Examining data/modsecurity-3.0.4/src/variables/args_post.h
Examining data/modsecurity-3.0.4/src/variables/args_names.h
Examining data/modsecurity-3.0.4/src/variables/args_get_names.h
Examining data/modsecurity-3.0.4/src/variables/args_get.h
Examining data/modsecurity-3.0.4/src/variables/args_combined_size.h
Examining data/modsecurity-3.0.4/src/variables/args.h
Examining data/modsecurity-3.0.4/src/utils/system.h
Examining data/modsecurity-3.0.4/src/utils/system.cc
Examining data/modsecurity-3.0.4/src/utils/string.h
Examining data/modsecurity-3.0.4/src/utils/string.cc
Examining data/modsecurity-3.0.4/src/utils/shared_files.h
Examining data/modsecurity-3.0.4/src/utils/shared_files.cc
Examining data/modsecurity-3.0.4/src/utils/sha1.h
Examining data/modsecurity-3.0.4/src/utils/sha1.cc
Examining data/modsecurity-3.0.4/src/utils/random.h
Examining data/modsecurity-3.0.4/src/utils/random.cc
Examining data/modsecurity-3.0.4/src/utils/phase.h
Examining data/modsecurity-3.0.4/src/utils/msc_tree.h
Examining data/modsecurity-3.0.4/src/utils/msc_tree.cc
Examining data/modsecurity-3.0.4/src/utils/md5.h
Examining data/modsecurity-3.0.4/src/utils/md5.cc
Examining data/modsecurity-3.0.4/src/utils/ip_tree.h
Examining data/modsecurity-3.0.4/src/utils/ip_tree.cc
Examining data/modsecurity-3.0.4/src/utils/https_client.h
Examining data/modsecurity-3.0.4/src/utils/https_client.cc
Examining data/modsecurity-3.0.4/src/utils/geo_lookup.h
Examining data/modsecurity-3.0.4/src/utils/geo_lookup.cc
Examining data/modsecurity-3.0.4/src/utils/decode.h
Examining data/modsecurity-3.0.4/src/utils/decode.cc
Examining data/modsecurity-3.0.4/src/utils/base64.h
Examining data/modsecurity-3.0.4/src/utils/base64.cc
Examining data/modsecurity-3.0.4/src/utils/acmp.h
Examining data/modsecurity-3.0.4/src/utils/acmp.cc
Examining data/modsecurity-3.0.4/src/utils/regex.cc
Examining data/modsecurity-3.0.4/src/utils/regex.h
Examining data/modsecurity-3.0.4/src/unique_id.h
Examining data/modsecurity-3.0.4/src/unique_id.cc
Examining data/modsecurity-3.0.4/src/transaction.cc
Examining data/modsecurity-3.0.4/src/run_time_string.h
Examining data/modsecurity-3.0.4/src/run_time_string.cc
Examining data/modsecurity-3.0.4/src/rules_properties.cc
Examining data/modsecurity-3.0.4/src/rules_exceptions.cc
Examining data/modsecurity-3.0.4/src/rules.cc
Examining data/modsecurity-3.0.4/src/rule_script.h
Examining data/modsecurity-3.0.4/src/rule_script.cc
Examining data/modsecurity-3.0.4/src/rule_message.cc
Examining data/modsecurity-3.0.4/src/rule.cc
Examining data/modsecurity-3.0.4/src/request_body_processor/xml.h
Examining data/modsecurity-3.0.4/src/request_body_processor/xml.cc
Examining data/modsecurity-3.0.4/src/request_body_processor/multipart.h
Parsing failed to find end of parameter list; semicolon terminated it in (Left.begin(), Left.end(), Right.begin(),
            [](char a, char b) {
                return tolower(a) == tolower(b);
            });
    }
};


class MultipartPart {
 public:
    MultipartPart(
Examining data/modsecurity-3.0.4/src/request_body_processor/multipart.cc
Examining data/modsecurity-3.0.4/src/request_body_processor/json.h
Examining data/modsecurity-3.0.4/src/request_body_processor/json.cc
Examining data/modsecurity-3.0.4/src/parser/seclang-scanner.cc
Examining data/modsecurity-3.0.4/src/parser/seclang-parser.cc
Examining data/modsecurity-3.0.4/src/parser/driver.h
Examining data/modsecurity-3.0.4/src/parser/driver.cc
Examining data/modsecurity-3.0.4/src/operators/within.h
Examining data/modsecurity-3.0.4/src/operators/within.cc
Examining data/modsecurity-3.0.4/src/operators/verify_svnr.h
Examining data/modsecurity-3.0.4/src/operators/verify_svnr.cc
Examining data/modsecurity-3.0.4/src/operators/verify_ssn.h
Examining data/modsecurity-3.0.4/src/operators/verify_ssn.cc
Examining data/modsecurity-3.0.4/src/operators/verify_cpf.h
Examining data/modsecurity-3.0.4/src/operators/verify_cpf.cc
Examining data/modsecurity-3.0.4/src/operators/verify_cc.h
Examining data/modsecurity-3.0.4/src/operators/verify_cc.cc
Examining data/modsecurity-3.0.4/src/operators/validate_utf8_encoding.h
Examining data/modsecurity-3.0.4/src/operators/validate_utf8_encoding.cc
Examining data/modsecurity-3.0.4/src/operators/validate_url_encoding.h
Examining data/modsecurity-3.0.4/src/operators/validate_url_encoding.cc
Examining data/modsecurity-3.0.4/src/operators/validate_schema.h
Examining data/modsecurity-3.0.4/src/operators/validate_schema.cc
Examining data/modsecurity-3.0.4/src/operators/validate_hash.h
Examining data/modsecurity-3.0.4/src/operators/validate_hash.cc
Examining data/modsecurity-3.0.4/src/operators/validate_dtd.h
Examining data/modsecurity-3.0.4/src/operators/validate_dtd.cc
Examining data/modsecurity-3.0.4/src/operators/validate_byte_range.h
Examining data/modsecurity-3.0.4/src/operators/validate_byte_range.cc
Examining data/modsecurity-3.0.4/src/operators/unconditional_match.h
Examining data/modsecurity-3.0.4/src/operators/unconditional_match.cc
Examining data/modsecurity-3.0.4/src/operators/str_match.h
Examining data/modsecurity-3.0.4/src/operators/str_match.cc
Examining data/modsecurity-3.0.4/src/operators/str_eq.h
Examining data/modsecurity-3.0.4/src/operators/str_eq.cc
Examining data/modsecurity-3.0.4/src/operators/rx.h
Examining data/modsecurity-3.0.4/src/operators/rsub.h
Examining data/modsecurity-3.0.4/src/operators/rsub.cc
Examining data/modsecurity-3.0.4/src/operators/rbl.h
Examining data/modsecurity-3.0.4/src/operators/rbl.cc
Examining data/modsecurity-3.0.4/src/operators/pm_from_file.h
Examining data/modsecurity-3.0.4/src/operators/pm_from_file.cc
Examining data/modsecurity-3.0.4/src/operators/pm_f.h
Examining data/modsecurity-3.0.4/src/operators/pm_f.cc
Examining data/modsecurity-3.0.4/src/operators/pm.h
Examining data/modsecurity-3.0.4/src/operators/pm.cc
Examining data/modsecurity-3.0.4/src/operators/operator.h
Examining data/modsecurity-3.0.4/src/operators/operator.cc
Examining data/modsecurity-3.0.4/src/operators/no_match.h
Examining data/modsecurity-3.0.4/src/operators/no_match.cc
Examining data/modsecurity-3.0.4/src/operators/lt.h
Examining data/modsecurity-3.0.4/src/operators/lt.cc
Examining data/modsecurity-3.0.4/src/operators/le.h
Examining data/modsecurity-3.0.4/src/operators/le.cc
Examining data/modsecurity-3.0.4/src/operators/ip_match_from_file.h
Examining data/modsecurity-3.0.4/src/operators/ip_match_from_file.cc
Examining data/modsecurity-3.0.4/src/operators/ip_match_f.h
Examining data/modsecurity-3.0.4/src/operators/ip_match_f.cc
Examining data/modsecurity-3.0.4/src/operators/ip_match.h
Examining data/modsecurity-3.0.4/src/operators/ip_match.cc
Examining data/modsecurity-3.0.4/src/operators/inspect_file.h
Examining data/modsecurity-3.0.4/src/operators/inspect_file.cc
Examining data/modsecurity-3.0.4/src/operators/gt.h
Examining data/modsecurity-3.0.4/src/operators/gt.cc
Examining data/modsecurity-3.0.4/src/operators/gsblookup.h
Examining data/modsecurity-3.0.4/src/operators/gsblookup.cc
Examining data/modsecurity-3.0.4/src/operators/geo_lookup.h
Examining data/modsecurity-3.0.4/src/operators/geo_lookup.cc
Examining data/modsecurity-3.0.4/src/operators/ge.h
Examining data/modsecurity-3.0.4/src/operators/ge.cc
Examining data/modsecurity-3.0.4/src/operators/fuzzy_hash.h
Examining data/modsecurity-3.0.4/src/operators/fuzzy_hash.cc
Examining data/modsecurity-3.0.4/src/operators/eq.h
Examining data/modsecurity-3.0.4/src/operators/eq.cc
Examining data/modsecurity-3.0.4/src/operators/ends_with.h
Examining data/modsecurity-3.0.4/src/operators/ends_with.cc
Examining data/modsecurity-3.0.4/src/operators/detect_xss.h
Examining data/modsecurity-3.0.4/src/operators/detect_xss.cc
Examining data/modsecurity-3.0.4/src/operators/detect_sqli.h
Examining data/modsecurity-3.0.4/src/operators/detect_sqli.cc
Examining data/modsecurity-3.0.4/src/operators/contains_word.h
Examining data/modsecurity-3.0.4/src/operators/contains_word.cc
Examining data/modsecurity-3.0.4/src/operators/contains.h
Examining data/modsecurity-3.0.4/src/operators/contains.cc
Examining data/modsecurity-3.0.4/src/operators/begins_with.h
Examining data/modsecurity-3.0.4/src/operators/begins_with.cc
Examining data/modsecurity-3.0.4/src/operators/rx.cc
Examining data/modsecurity-3.0.4/src/modsecurity.cc
Examining data/modsecurity-3.0.4/src/engine/lua.h
Examining data/modsecurity-3.0.4/src/engine/lua.cc
Examining data/modsecurity-3.0.4/src/debug_log_writer_agent.h
Examining data/modsecurity-3.0.4/src/debug_log/debug_log_writer.h
Examining data/modsecurity-3.0.4/src/debug_log/debug_log_writer.cc
Examining data/modsecurity-3.0.4/src/debug_log/debug_log.cc
Examining data/modsecurity-3.0.4/src/collection/collections.cc
Examining data/modsecurity-3.0.4/src/collection/backend/lmdb.h
Examining data/modsecurity-3.0.4/src/collection/backend/lmdb.cc
Examining data/modsecurity-3.0.4/src/collection/backend/in_memory-per_process.h
Parsing failed to find end of parameter list; semicolon terminated it in (Left.begin(), Left.end(), Right.begin(),
            [](char a, char b) {
            return tolower(a) == tolower(b);
        });
    }
};

struct MyHash{
    size_t operator()(const std::string& Ke
Examining data/modsecurity-3.0.4/src/collection/backend/in_memory-per_process.cc
Examining data/modsecurity-3.0.4/src/audit_log/writer/writer.h
Examining data/modsecurity-3.0.4/src/audit_log/writer/writer.cc
Examining data/modsecurity-3.0.4/src/audit_log/writer/serial.h
Examining data/modsecurity-3.0.4/src/audit_log/writer/serial.cc
Examining data/modsecurity-3.0.4/src/audit_log/writer/parallel.h
Examining data/modsecurity-3.0.4/src/audit_log/writer/parallel.cc
Examining data/modsecurity-3.0.4/src/audit_log/writer/https.h
Examining data/modsecurity-3.0.4/src/audit_log/writer/https.cc
Examining data/modsecurity-3.0.4/src/audit_log/audit_log.cc
Examining data/modsecurity-3.0.4/src/anchored_variable.cc
Examining data/modsecurity-3.0.4/src/anchored_set_variable.cc
Examining data/modsecurity-3.0.4/src/actions/xmlns.h
Examining data/modsecurity-3.0.4/src/actions/xmlns.cc
Examining data/modsecurity-3.0.4/src/actions/ver.h
Examining data/modsecurity-3.0.4/src/actions/ver.cc
Examining data/modsecurity-3.0.4/src/actions/transformations/utf8_to_unicode.h
Examining data/modsecurity-3.0.4/src/actions/transformations/utf8_to_unicode.cc
Examining data/modsecurity-3.0.4/src/actions/transformations/url_encode.h
Examining data/modsecurity-3.0.4/src/actions/transformations/url_encode.cc
Examining data/modsecurity-3.0.4/src/actions/transformations/url_decode_uni.h
Examining data/modsecurity-3.0.4/src/actions/transformations/url_decode_uni.cc
Examining data/modsecurity-3.0.4/src/actions/transformations/url_decode.h
Examining data/modsecurity-3.0.4/src/actions/transformations/url_decode.cc
Examining data/modsecurity-3.0.4/src/actions/transformations/upper_case.h
Examining data/modsecurity-3.0.4/src/actions/transformations/upper_case.cc
Examining data/modsecurity-3.0.4/src/actions/transformations/trim_right.h
Examining data/modsecurity-3.0.4/src/actions/transformations/trim_right.cc
Examining data/modsecurity-3.0.4/src/actions/transformations/trim_left.h
Examining data/modsecurity-3.0.4/src/actions/transformations/trim_left.cc
Examining data/modsecurity-3.0.4/src/actions/transformations/trim.h
Examining data/modsecurity-3.0.4/src/actions/transformations/trim.cc
Examining data/modsecurity-3.0.4/src/actions/transformations/transformation.h
Examining data/modsecurity-3.0.4/src/actions/transformations/transformation.cc
Examining data/modsecurity-3.0.4/src/actions/transformations/sql_hex_decode.h
Examining data/modsecurity-3.0.4/src/actions/transformations/sql_hex_decode.cc
Examining data/modsecurity-3.0.4/src/actions/transformations/sha1.h
Examining data/modsecurity-3.0.4/src/actions/transformations/sha1.cc
Examining data/modsecurity-3.0.4/src/actions/transformations/replace_nulls.h
Examining data/modsecurity-3.0.4/src/actions/transformations/replace_nulls.cc
Examining data/modsecurity-3.0.4/src/actions/transformations/replace_comments.h
Examining data/modsecurity-3.0.4/src/actions/transformations/replace_comments.cc
Examining data/modsecurity-3.0.4/src/actions/transformations/remove_whitespace.h
Examining data/modsecurity-3.0.4/src/actions/transformations/remove_whitespace.cc
Examining data/modsecurity-3.0.4/src/actions/transformations/remove_nulls.h
Examining data/modsecurity-3.0.4/src/actions/transformations/remove_nulls.cc
Examining data/modsecurity-3.0.4/src/actions/transformations/remove_comments_char.h
Examining data/modsecurity-3.0.4/src/actions/transformations/remove_comments_char.cc
Examining data/modsecurity-3.0.4/src/actions/transformations/remove_comments.h
Examining data/modsecurity-3.0.4/src/actions/transformations/remove_comments.cc
Examining data/modsecurity-3.0.4/src/actions/transformations/parity_zero_7bit.h
Examining data/modsecurity-3.0.4/src/actions/transformations/parity_zero_7bit.cc
Examining data/modsecurity-3.0.4/src/actions/transformations/parity_odd_7bit.h
Examining data/modsecurity-3.0.4/src/actions/transformations/parity_odd_7bit.cc
Examining data/modsecurity-3.0.4/src/actions/transformations/parity_even_7bit.h
Examining data/modsecurity-3.0.4/src/actions/transformations/parity_even_7bit.cc
Examining data/modsecurity-3.0.4/src/actions/transformations/normalise_path_win.h
Examining data/modsecurity-3.0.4/src/actions/transformations/normalise_path_win.cc
Examining data/modsecurity-3.0.4/src/actions/transformations/normalise_path.h
Examining data/modsecurity-3.0.4/src/actions/transformations/normalise_path.cc
Examining data/modsecurity-3.0.4/src/actions/transformations/none.h
Examining data/modsecurity-3.0.4/src/actions/transformations/none.cc
Examining data/modsecurity-3.0.4/src/actions/transformations/md5.h
Examining data/modsecurity-3.0.4/src/actions/transformations/md5.cc
Examining data/modsecurity-3.0.4/src/actions/transformations/lower_case.h
Examining data/modsecurity-3.0.4/src/actions/transformations/lower_case.cc
Examining data/modsecurity-3.0.4/src/actions/transformations/length.h
Examining data/modsecurity-3.0.4/src/actions/transformations/length.cc
Examining data/modsecurity-3.0.4/src/actions/transformations/js_decode.h
Examining data/modsecurity-3.0.4/src/actions/transformations/js_decode.cc
Examining data/modsecurity-3.0.4/src/actions/transformations/html_entity_decode.h
Examining data/modsecurity-3.0.4/src/actions/transformations/html_entity_decode.cc
Examining data/modsecurity-3.0.4/src/actions/transformations/hex_encode.h
Examining data/modsecurity-3.0.4/src/actions/transformations/hex_encode.cc
Examining data/modsecurity-3.0.4/src/actions/transformations/hex_decode.h
Examining data/modsecurity-3.0.4/src/actions/transformations/hex_decode.cc
Examining data/modsecurity-3.0.4/src/actions/transformations/escape_seq_decode.h
Examining data/modsecurity-3.0.4/src/actions/transformations/escape_seq_decode.cc
Examining data/modsecurity-3.0.4/src/actions/transformations/css_decode.h
Examining data/modsecurity-3.0.4/src/actions/transformations/css_decode.cc
Examining data/modsecurity-3.0.4/src/actions/transformations/compress_whitespace.h
Examining data/modsecurity-3.0.4/src/actions/transformations/compress_whitespace.cc
Examining data/modsecurity-3.0.4/src/actions/transformations/cmd_line.h
Examining data/modsecurity-3.0.4/src/actions/transformations/cmd_line.cc
Examining data/modsecurity-3.0.4/src/actions/transformations/base64_encode.h
Examining data/modsecurity-3.0.4/src/actions/transformations/base64_encode.cc
Examining data/modsecurity-3.0.4/src/actions/transformations/base64_decode_ext.h
Examining data/modsecurity-3.0.4/src/actions/transformations/base64_decode_ext.cc
Examining data/modsecurity-3.0.4/src/actions/transformations/base64_decode.h
Examining data/modsecurity-3.0.4/src/actions/transformations/base64_decode.cc
Examining data/modsecurity-3.0.4/src/actions/tag.h
Examining data/modsecurity-3.0.4/src/actions/tag.cc
Examining data/modsecurity-3.0.4/src/actions/skip_after.h
Examining data/modsecurity-3.0.4/src/actions/skip_after.cc
Examining data/modsecurity-3.0.4/src/actions/skip.h
Examining data/modsecurity-3.0.4/src/actions/skip.cc
Examining data/modsecurity-3.0.4/src/actions/severity.h
Examining data/modsecurity-3.0.4/src/actions/severity.cc
Examining data/modsecurity-3.0.4/src/actions/set_var.h
Examining data/modsecurity-3.0.4/src/actions/set_var.cc
Examining data/modsecurity-3.0.4/src/actions/set_uid.h
Examining data/modsecurity-3.0.4/src/actions/set_uid.cc
Examining data/modsecurity-3.0.4/src/actions/set_sid.h
Examining data/modsecurity-3.0.4/src/actions/set_sid.cc
Examining data/modsecurity-3.0.4/src/actions/set_rsc.h
Examining data/modsecurity-3.0.4/src/actions/set_rsc.cc
Examining data/modsecurity-3.0.4/src/actions/set_env.h
Examining data/modsecurity-3.0.4/src/actions/set_env.cc
Examining data/modsecurity-3.0.4/src/actions/rule_id.h
Examining data/modsecurity-3.0.4/src/actions/rule_id.cc
Examining data/modsecurity-3.0.4/src/actions/rev.h
Examining data/modsecurity-3.0.4/src/actions/rev.cc
Examining data/modsecurity-3.0.4/src/actions/phase.h
Examining data/modsecurity-3.0.4/src/actions/phase.cc
Examining data/modsecurity-3.0.4/src/actions/no_log.h
Examining data/modsecurity-3.0.4/src/actions/no_log.cc
Examining data/modsecurity-3.0.4/src/actions/no_audit_log.h
Examining data/modsecurity-3.0.4/src/actions/no_audit_log.cc
Examining data/modsecurity-3.0.4/src/actions/multi_match.h
Examining data/modsecurity-3.0.4/src/actions/multi_match.cc
Examining data/modsecurity-3.0.4/src/actions/msg.h
Examining data/modsecurity-3.0.4/src/actions/msg.cc
Examining data/modsecurity-3.0.4/src/actions/maturity.h
Examining data/modsecurity-3.0.4/src/actions/maturity.cc
Examining data/modsecurity-3.0.4/src/actions/log_data.h
Examining data/modsecurity-3.0.4/src/actions/log_data.cc
Examining data/modsecurity-3.0.4/src/actions/log.h
Examining data/modsecurity-3.0.4/src/actions/log.cc
Examining data/modsecurity-3.0.4/src/actions/init_col.h
Examining data/modsecurity-3.0.4/src/actions/init_col.cc
Examining data/modsecurity-3.0.4/src/actions/exec.h
Examining data/modsecurity-3.0.4/src/actions/exec.cc
Examining data/modsecurity-3.0.4/src/actions/disruptive/redirect.h
Examining data/modsecurity-3.0.4/src/actions/disruptive/redirect.cc
Examining data/modsecurity-3.0.4/src/actions/disruptive/pass.h
Examining data/modsecurity-3.0.4/src/actions/disruptive/pass.cc
Examining data/modsecurity-3.0.4/src/actions/disruptive/drop.h
Examining data/modsecurity-3.0.4/src/actions/disruptive/drop.cc
Examining data/modsecurity-3.0.4/src/actions/disruptive/deny.h
Examining data/modsecurity-3.0.4/src/actions/disruptive/deny.cc
Examining data/modsecurity-3.0.4/src/actions/disruptive/allow.h
Examining data/modsecurity-3.0.4/src/actions/disruptive/allow.cc
Examining data/modsecurity-3.0.4/src/actions/data/status.h
Examining data/modsecurity-3.0.4/src/actions/data/status.cc
Examining data/modsecurity-3.0.4/src/actions/ctl/rule_remove_target_by_tag.h
Examining data/modsecurity-3.0.4/src/actions/ctl/rule_remove_target_by_tag.cc
Examining data/modsecurity-3.0.4/src/actions/ctl/rule_remove_target_by_id.h
Examining data/modsecurity-3.0.4/src/actions/ctl/rule_remove_target_by_id.cc
Examining data/modsecurity-3.0.4/src/actions/ctl/rule_remove_by_tag.h
Examining data/modsecurity-3.0.4/src/actions/ctl/rule_remove_by_tag.cc
Examining data/modsecurity-3.0.4/src/actions/ctl/rule_remove_by_id.h
Examining data/modsecurity-3.0.4/src/actions/ctl/rule_remove_by_id.cc
Examining data/modsecurity-3.0.4/src/actions/ctl/rule_engine.h
Examining data/modsecurity-3.0.4/src/actions/ctl/rule_engine.cc
Examining data/modsecurity-3.0.4/src/actions/ctl/request_body_processor_xml.h
Examining data/modsecurity-3.0.4/src/actions/ctl/request_body_processor_xml.cc
Examining data/modsecurity-3.0.4/src/actions/ctl/request_body_processor_urlencoded.h
Examining data/modsecurity-3.0.4/src/actions/ctl/request_body_processor_urlencoded.cc
Examining data/modsecurity-3.0.4/src/actions/ctl/request_body_processor_json.h
Examining data/modsecurity-3.0.4/src/actions/ctl/request_body_processor_json.cc
Examining data/modsecurity-3.0.4/src/actions/ctl/request_body_access.h
Examining data/modsecurity-3.0.4/src/actions/ctl/request_body_access.cc
Examining data/modsecurity-3.0.4/src/actions/ctl/audit_log_parts.h
Examining data/modsecurity-3.0.4/src/actions/ctl/audit_log_parts.cc
Examining data/modsecurity-3.0.4/src/actions/chain.h
Examining data/modsecurity-3.0.4/src/actions/chain.cc
Examining data/modsecurity-3.0.4/src/actions/capture.h
Examining data/modsecurity-3.0.4/src/actions/capture.cc
Examining data/modsecurity-3.0.4/src/actions/block.h
Examining data/modsecurity-3.0.4/src/actions/block.cc
Examining data/modsecurity-3.0.4/src/actions/audit_log.h
Examining data/modsecurity-3.0.4/src/actions/audit_log.cc
Examining data/modsecurity-3.0.4/src/actions/action.cc
Examining data/modsecurity-3.0.4/src/actions/accuracy.h
Examining data/modsecurity-3.0.4/src/actions/accuracy.cc
Examining data/modsecurity-3.0.4/others/mbedtls/sha1.h
Examining data/modsecurity-3.0.4/others/mbedtls/sha1.c
Examining data/modsecurity-3.0.4/others/mbedtls/platform.h
Examining data/modsecurity-3.0.4/others/mbedtls/md5.h
Examining data/modsecurity-3.0.4/others/mbedtls/md5.c
Examining data/modsecurity-3.0.4/others/mbedtls/mbed-tls-config.h
Examining data/modsecurity-3.0.4/others/mbedtls/check_config.h
Examining data/modsecurity-3.0.4/others/mbedtls/base64.h
Examining data/modsecurity-3.0.4/others/mbedtls/base64.c
Examining data/modsecurity-3.0.4/others/libinjection/src/testdriver.c
Examining data/modsecurity-3.0.4/others/libinjection/src/test_speed_xss.c
Examining data/modsecurity-3.0.4/others/libinjection/src/test_speed_sqli.c
Examining data/modsecurity-3.0.4/others/libinjection/src/sqli_cli.c
Examining data/modsecurity-3.0.4/others/libinjection/src/reader.c
Examining data/modsecurity-3.0.4/others/libinjection/src/libinjection_xss.h
Examining data/modsecurity-3.0.4/others/libinjection/src/libinjection_xss.c
Examining data/modsecurity-3.0.4/others/libinjection/src/libinjection_sqli_data.h
Examining data/modsecurity-3.0.4/others/libinjection/src/libinjection_sqli.h
Examining data/modsecurity-3.0.4/others/libinjection/src/libinjection_sqli.c
Examining data/modsecurity-3.0.4/others/libinjection/src/libinjection_html5.h
Examining data/modsecurity-3.0.4/others/libinjection/src/libinjection_html5.c
Examining data/modsecurity-3.0.4/others/libinjection/src/libinjection.h
Examining data/modsecurity-3.0.4/others/libinjection/src/html5_cli.c
Examining data/modsecurity-3.0.4/others/libinjection/src/fptool.c
Examining data/modsecurity-3.0.4/others/libinjection/src/example1.c
Examining data/modsecurity-3.0.4/headers/modsecurity/modsecurity.h
Examining data/modsecurity-3.0.4/headers/modsecurity/variable_value.h
Examining data/modsecurity-3.0.4/headers/modsecurity/variable_origin.h
Examining data/modsecurity-3.0.4/headers/modsecurity/transaction.h
Examining data/modsecurity-3.0.4/headers/modsecurity/rules_properties.h
Examining data/modsecurity-3.0.4/headers/modsecurity/rules_exceptions.h
Examining data/modsecurity-3.0.4/headers/modsecurity/rules.h
Examining data/modsecurity-3.0.4/headers/modsecurity/rule_message.h
Examining data/modsecurity-3.0.4/headers/modsecurity/rule.h
Examining data/modsecurity-3.0.4/headers/modsecurity/intervention.h
Examining data/modsecurity-3.0.4/headers/modsecurity/debug_log.h
Examining data/modsecurity-3.0.4/headers/modsecurity/collection/collections.h
Examining data/modsecurity-3.0.4/headers/modsecurity/collection/collection.h
Examining data/modsecurity-3.0.4/headers/modsecurity/audit_log.h
Examining data/modsecurity-3.0.4/headers/modsecurity/anchored_variable.h
Examining data/modsecurity-3.0.4/headers/modsecurity/anchored_set_variable.h
Parsing failed to find end of parameter list; semicolon terminated it in (Left.begin(), Left.end(), Right.begin(),
            [](char a, char b) {
            return tolower(a) == tolower(b);
        });
    }
};

struct MyHash{
    size_t operator()(const std::string& Ke
Examining data/modsecurity-3.0.4/headers/modsecurity/actions/action.h
Examining data/modsecurity-3.0.4/examples/using_bodies_in_chunks/simple_request.cc
Examining data/modsecurity-3.0.4/examples/simple_example_using_c/test.c
Examining data/modsecurity-3.0.4/examples/reading_logs_with_offset/read.cc
Examining data/modsecurity-3.0.4/examples/reading_logs_via_rule_message/simple_request.cc
Examining data/modsecurity-3.0.4/examples/reading_logs_via_rule_message/reading_logs_via_rule_message.h
Examining data/modsecurity-3.0.4/examples/multiprocess_c/multi.c

FINAL RESULTS:

data/modsecurity-3.0.4/others/libinjection/src/libinjection_sqli.c:2320:9:  [4] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused).
        strcpy(fingerprint, state.fingerprint);
data/modsecurity-3.0.4/others/libinjection/src/testdriver.c:49:12:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
    slen = sprintf(buf + len, "%s", t->val);
data/modsecurity-3.0.4/others/libinjection/src/testdriver.c:106:12:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
    slen = sprintf(buf + len, "%s,%d,%s\n",
data/modsecurity-3.0.4/others/libinjection/src/testdriver.c:130:16:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
        slen = sprintf(buf + len, "%s", t->val);
data/modsecurity-3.0.4/others/libinjection/src/testdriver.c:172:13:  [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(bufptr, linebuf);
data/modsecurity-3.0.4/others/libinjection/src/testdriver.c:217:13:  [4] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf.
            sprintf(g_actual, "%s", buf);
data/modsecurity-3.0.4/others/mbedtls/base64.c:40:24:  [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 mbedtls_printf printf
data/modsecurity-3.0.4/others/mbedtls/md5.c:44:24:  [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 mbedtls_printf printf
data/modsecurity-3.0.4/others/mbedtls/platform.h:51:41:  [4] (format) snprintf:
  If format strings can be influenced by an attacker, they can be exploited,
  and note that sprintf variations do not always \0-terminate (CWE-134). Use
  a constant for the format specification.
#define MBEDTLS_PLATFORM_STD_SNPRINTF   snprintf /**< Default snprintf to use  */
data/modsecurity-3.0.4/others/mbedtls/platform.h:55:39:  [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 MBEDTLS_PLATFORM_STD_PRINTF   printf /**< Default printf to use  */
data/modsecurity-3.0.4/others/mbedtls/platform.h:58:38:  [4] (format) fprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
#define MBEDTLS_PLATFORM_STD_FPRINTF fprintf /**< Default fprintf to use */
data/modsecurity-3.0.4/others/mbedtls/platform.h:128:28:  [4] (format) fprintf:
  If format strings can be influenced by an attacker, they can be exploited
  (CWE-134). Use a constant for the format specification.
#define mbedtls_fprintf    fprintf
data/modsecurity-3.0.4/others/mbedtls/platform.h:150:28:  [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 mbedtls_printf     printf
data/modsecurity-3.0.4/others/mbedtls/platform.h:184:28:  [4] (format) snprintf:
  If format strings can be influenced by an attacker, they can be exploited,
  and note that sprintf variations do not always \0-terminate (CWE-134). Use
  a constant for the format specification.
#define mbedtls_snprintf   snprintf
data/modsecurity-3.0.4/others/mbedtls/sha1.c:44:24:  [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 mbedtls_printf printf
data/modsecurity-3.0.4/src/operators/inspect_file.cc:65:20:  [4] (shell) popen:
  This causes a new program to execute and is difficult to use safely
  (CWE-78). try using a library call that implements the same functionality
  if available.
        if (!(in = popen(openstr.c_str(), "r"))) {
data/modsecurity-3.0.4/src/operators/validate_dtd.h:60:19:  [4] (format) vsnprintf:
  If format strings can be influenced by an attacker, they can be exploited,
  and note that sprintf variations do not always \0-terminate (CWE-134). Use
  a constant for the format specification.
        int len = vsnprintf(buf, sizeof(buf), msg, args);
data/modsecurity-3.0.4/src/operators/validate_dtd.h:77:19:  [4] (format) vsnprintf:
  If format strings can be influenced by an attacker, they can be exploited,
  and note that sprintf variations do not always \0-terminate (CWE-134). Use
  a constant for the format specification.
        int len = vsnprintf(buf, sizeof(buf), msg, args);
data/modsecurity-3.0.4/src/operators/validate_schema.h:71:19:  [4] (format) vsnprintf:
  If format strings can be influenced by an attacker, they can be exploited,
  and note that sprintf variations do not always \0-terminate (CWE-134). Use
  a constant for the format specification.
        int len = vsnprintf(buf, sizeof(buf), msg, args);
data/modsecurity-3.0.4/src/operators/validate_schema.h:86:19:  [4] (format) vsnprintf:
  If format strings can be influenced by an attacker, they can be exploited,
  and note that sprintf variations do not always \0-terminate (CWE-134). Use
  a constant for the format specification.
        int len = vsnprintf(buf, sizeof(buf), msg, args);
data/modsecurity-3.0.4/src/operators/validate_schema.h:102:19:  [4] (format) vsnprintf:
  If format strings can be influenced by an attacker, they can be exploited,
  and note that sprintf variations do not always \0-terminate (CWE-134). Use
  a constant for the format specification.
        int len = vsnprintf(buf, sizeof(buf), msg, args);
data/modsecurity-3.0.4/src/operators/validate_schema.h:119:19:  [4] (format) vsnprintf:
  If format strings can be influenced by an attacker, they can be exploited,
  and note that sprintf variations do not always \0-terminate (CWE-134). Use
  a constant for the format specification.
        int len = vsnprintf(buf, sizeof(buf), msg, args);
data/modsecurity-3.0.4/src/utils/acmp.cc:527:17:  [4] (buffer) strcpy:
  Does not check for buffer overflows when copying to destination [MS-banned]
  (CWE-120). Consider using snprintf, strcpy_s, or strlcpy (warning: strncpy
  easily misused).
                strcpy(child->pattern, pattern);
data/modsecurity-3.0.4/src/modsecurity.cc:82:5:  [3] (random) srand:
  This function is not sufficiently random for security-related functions
  such as key and nonce creation (CWE-327). Use a more secure technique for
  acquiring random values.
    srand(time(NULL));
data/modsecurity-3.0.4/test/common/modsecurity_test.cc:148:34:  [3] (buffer) getenv:
  Environment variables are untrustable input if they can be set by an
  attacker. They can have any content and length, and the same variable can
  be set more than once (CWE-807, CWE-20). Check environment variables
  carefully before using them.
    if (const char* env_p = std::getenv("AUTOMAKE_TESTS")) {
data/modsecurity-3.0.4/others/libinjection/src/example1.c:7: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 fingerprint[8];
data/modsecurity-3.0.4/others/libinjection/src/html5_cli.c:106: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(tmp, hs->token_start, hs->token_len);
data/modsecurity-3.0.4/others/libinjection/src/html5_cli.c:139:20:  [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).
            flag = atoi(argv[offset]);
data/modsecurity-3.0.4/others/libinjection/src/html5_cli.c:153: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(copy, argv[offset], slen);
data/modsecurity-3.0.4/others/libinjection/src/libinjection_sqli.c:310: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(st->val, value, last);
data/modsecurity-3.0.4/others/libinjection/src/libinjection_sqli.c:316: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(dest, src, sizeof(stoken_t));
data/modsecurity-3.0.4/others/libinjection/src/libinjection_sqli.c:1319: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 tmp[LIBINJECTION_SQLI_TOKEN_SIZE];
data/modsecurity-3.0.4/others/libinjection/src/libinjection_sqli.c:1357: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(tmp, a->val, sz1);
data/modsecurity-3.0.4/others/libinjection/src/libinjection_sqli.c:1359: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(tmp + sz1 + 1, b->val, sz2);
data/modsecurity-3.0.4/others/libinjection/src/libinjection_sqli.c:1982: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 fp2[8];
data/modsecurity-3.0.4/others/libinjection/src/libinjection_sqli.h:59: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 val[32];
data/modsecurity-3.0.4/others/libinjection/src/libinjection_sqli.h:122: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 fingerprint[8];
data/modsecurity-3.0.4/others/libinjection/src/reader.c:120: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 linebuf[8192];
data/modsecurity-3.0.4/others/libinjection/src/reader.c:265:19:  [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).
            max = atoi(argv[offset]);
data/modsecurity-3.0.4/others/libinjection/src/reader.c:281:28:  [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).
                FILE* fd = fopen(argv[i], "r");
data/modsecurity-3.0.4/others/libinjection/src/sqli_cli.c:142: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(copy, argv[offset], slen);
data/modsecurity-3.0.4/others/libinjection/src/testdriver.c:11: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 g_test[8096];
data/modsecurity-3.0.4/others/libinjection/src/testdriver.c:12: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 g_input[8096];
data/modsecurity-3.0.4/others/libinjection/src/testdriver.c:13: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 g_expected[8096];
data/modsecurity-3.0.4/others/libinjection/src/testdriver.c:43:16:  [2] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf. Risk is low because the source has a constant maximum length.
        slen = sprintf(buf + len, "%c", t->str_open);
data/modsecurity-3.0.4/others/libinjection/src/testdriver.c:55:16:  [2] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf. Risk is low because the source has a constant maximum length.
        slen = sprintf(buf + len, "%c", t->str_close);
data/modsecurity-3.0.4/others/libinjection/src/testdriver.c:67:16:  [2] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf. Risk is low because the source has a constant maximum length.
        slen = sprintf(buf + len, "%c", '@');
data/modsecurity-3.0.4/others/libinjection/src/testdriver.c:72:16:  [2] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf. Risk is low because the source has a constant maximum length.
        slen = sprintf(buf + len, "%c", '@');
data/modsecurity-3.0.4/others/libinjection/src/testdriver.c:102: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(tmp, hs->token_start, hs->token_len);
data/modsecurity-3.0.4/others/libinjection/src/testdriver.c:119:12:  [2] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf. Risk is low because the source has a constant maximum length.
    slen = sprintf(buf + len, "%c ", t->type);
data/modsecurity-3.0.4/others/libinjection/src/testdriver.c:134:12:  [2] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf. Risk is low because the source has a constant maximum length.
    slen = sprintf(buf + len, "%c", '\n');
data/modsecurity-3.0.4/others/libinjection/src/testdriver.c:144: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 linebuf[8192];
data/modsecurity-3.0.4/others/libinjection/src/testdriver.c:145: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 g_actual[8192];
data/modsecurity-3.0.4/others/libinjection/src/testdriver.c:159:10:  [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).
    fp = fopen(fname, "r");
data/modsecurity-3.0.4/others/libinjection/src/testdriver.c:186: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(copy, g_input, slen);
data/modsecurity-3.0.4/others/libinjection/src/testdriver.c:214:9:  [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[100];
data/modsecurity-3.0.4/others/libinjection/src/testdriver.c:234:9:  [2] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf. Risk is low because the source has a constant maximum length.
        sprintf(g_actual, "%d", libinjection_xss(copy, slen));
data/modsecurity-3.0.4/others/mbedtls/base64.c:44:23:  [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 const unsigned char base64_enc_map[64] =
data/modsecurity-3.0.4/others/mbedtls/base64.c:55:23:  [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 const unsigned char base64_dec_map[128] =
data/modsecurity-3.0.4/others/mbedtls/base64.c:228:23:  [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 const unsigned char base64_test_dec[64] =
data/modsecurity-3.0.4/others/mbedtls/base64.c:251:14:  [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 buffer[128];
data/modsecurity-3.0.4/others/mbedtls/md5.c:112:68:  [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.
void mbedtls_md5_process( mbedtls_md5_context *ctx, const unsigned char data[64] )
data/modsecurity-3.0.4/others/mbedtls/md5.c:258:9:  [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( (void *) (ctx->buffer + left), input, fill );
data/modsecurity-3.0.4/others/mbedtls/md5.c:274:9:  [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( (void *) (ctx->buffer + left), input, ilen );
data/modsecurity-3.0.4/others/mbedtls/md5.c:278:23:  [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 const unsigned char md5_padding[64] =
data/modsecurity-3.0.4/others/mbedtls/md5.c:289:61:  [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.
void mbedtls_md5_finish( mbedtls_md5_context *ctx, unsigned char output[16] )
data/modsecurity-3.0.4/others/mbedtls/md5.c:293:14:  [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 msglen[8];
data/modsecurity-3.0.4/others/mbedtls/md5.c:319:34:  [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.
void mbedtls_md5( const unsigned char *input, size_t ilen, unsigned char output[16] )
data/modsecurity-3.0.4/others/mbedtls/md5.c:319:69:  [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.
void mbedtls_md5( const unsigned char *input, size_t ilen, unsigned char output[16] )
data/modsecurity-3.0.4/others/mbedtls/md5.c:334:23:  [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 const unsigned char md5_test_buf[7][81] =
data/modsecurity-3.0.4/others/mbedtls/md5.c:351:23:  [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 const unsigned char md5_test_sum[7][16] =
data/modsecurity-3.0.4/others/mbedtls/md5.c:375:14:  [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 md5sum[16];
data/modsecurity-3.0.4/others/mbedtls/md5.h:50:14:  [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 buffer[64];   /*!< data block being processed */
data/modsecurity-3.0.4/others/mbedtls/md5.h:99:61:  [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.
void mbedtls_md5_finish( mbedtls_md5_context *ctx, unsigned char output[16] );
data/modsecurity-3.0.4/others/mbedtls/md5.h:102:68:  [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.
void mbedtls_md5_process( mbedtls_md5_context *ctx, const unsigned char data[64] );
data/modsecurity-3.0.4/others/mbedtls/md5.h:123:34:  [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.
void mbedtls_md5( const unsigned char *input, size_t ilen, unsigned char output[16] );
data/modsecurity-3.0.4/others/mbedtls/md5.h:123:69:  [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.
void mbedtls_md5( const unsigned char *input, size_t ilen, unsigned char output[16] );
data/modsecurity-3.0.4/others/mbedtls/sha1.c:113:70:  [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.
void mbedtls_sha1_process( mbedtls_sha1_context *ctx, const unsigned char data[64] )
data/modsecurity-3.0.4/others/mbedtls/sha1.c:292:9:  [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( (void *) (ctx->buffer + left), input, fill );
data/modsecurity-3.0.4/others/mbedtls/sha1.c:307:9:  [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( (void *) (ctx->buffer + left), input, ilen );
data/modsecurity-3.0.4/others/mbedtls/sha1.c:310:23:  [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 const unsigned char sha1_padding[64] =
data/modsecurity-3.0.4/others/mbedtls/sha1.c:321:63:  [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.
void mbedtls_sha1_finish( mbedtls_sha1_context *ctx, unsigned char output[20] )
data/modsecurity-3.0.4/others/mbedtls/sha1.c:325:14:  [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 msglen[8];
data/modsecurity-3.0.4/others/mbedtls/sha1.c:352:35:  [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.
void mbedtls_sha1( const unsigned char *input, size_t ilen, unsigned char output[20] )
data/modsecurity-3.0.4/others/mbedtls/sha1.c:352:70:  [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.
void mbedtls_sha1( const unsigned char *input, size_t ilen, unsigned char output[20] )
data/modsecurity-3.0.4/others/mbedtls/sha1.c:367:23:  [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 const unsigned char sha1_test_buf[3][57] =
data/modsecurity-3.0.4/others/mbedtls/sha1.c:379:23:  [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 const unsigned char sha1_test_sum[3][20] =
data/modsecurity-3.0.4/others/mbedtls/sha1.c:395:14:  [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 buf[1024];
data/modsecurity-3.0.4/others/mbedtls/sha1.c:396:14:  [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 sha1sum[20];
data/modsecurity-3.0.4/others/mbedtls/sha1.h:50:14:  [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 buffer[64];   /*!< data block being processed */
data/modsecurity-3.0.4/others/mbedtls/sha1.h:99:63:  [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.
void mbedtls_sha1_finish( mbedtls_sha1_context *ctx, unsigned char output[20] );
data/modsecurity-3.0.4/others/mbedtls/sha1.h:102:70:  [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.
void mbedtls_sha1_process( mbedtls_sha1_context *ctx, const unsigned char data[64] );
data/modsecurity-3.0.4/others/mbedtls/sha1.h:123:35:  [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.
void mbedtls_sha1( const unsigned char *input, size_t ilen, unsigned char output[20] );
data/modsecurity-3.0.4/others/mbedtls/sha1.h:123:70:  [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.
void mbedtls_sha1( const unsigned char *input, size_t ilen, unsigned char output[20] );
data/modsecurity-3.0.4/src/actions/transformations/css_decode.cc:42: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(tmp, value.c_str(), value.size() + 1);
data/modsecurity-3.0.4/src/actions/transformations/escape_seq_decode.cc:102:25:  [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[4];
data/modsecurity-3.0.4/src/actions/transformations/escape_seq_decode.cc:148: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(tmp, value.c_str(), value.size() + 1);
data/modsecurity-3.0.4/src/actions/transformations/hex_decode.cc:48: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(input, value.c_str(), value.length()+1);
data/modsecurity-3.0.4/src/actions/transformations/html_entity_decode.cc:48: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(input, value.c_str(), value.length()+1);
data/modsecurity-3.0.4/src/actions/transformations/html_entity_decode.cc:104:25:  [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(x, (const char *)&input[k], j - k);
data/modsecurity-3.0.4/src/actions/transformations/html_entity_decode.cc:130:25:  [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(x, (const char *)&input[k], j - k);
data/modsecurity-3.0.4/src/actions/transformations/html_entity_decode.cc:156:21:  [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(x, (const char *)&input[k], j - k);
data/modsecurity-3.0.4/src/actions/transformations/js_decode.cc:49: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(input, value.c_str(), value.length()+1);
data/modsecurity-3.0.4/src/actions/transformations/js_decode.cc:95:17:  [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[4];
data/modsecurity-3.0.4/src/actions/transformations/normalise_path.cc:46: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(tmp, value.c_str(), value.size() + 1);
data/modsecurity-3.0.4/src/actions/transformations/normalise_path_win.cc:43: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(tmp, value.c_str(), value.size() + 1);
data/modsecurity-3.0.4/src/actions/transformations/parity_even_7bit.cc:47:10:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
    std::memcpy(input, value.c_str(), value.length()+1);
data/modsecurity-3.0.4/src/actions/transformations/parity_odd_7bit.cc:47: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(input, value.c_str(), value.length()+1);
data/modsecurity-3.0.4/src/actions/transformations/parity_zero_7bit.cc:47: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(input, value.c_str(), value.length()+1);
data/modsecurity-3.0.4/src/actions/transformations/remove_comments.cc:47: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(input, value.c_str(), value.length()+1);
data/modsecurity-3.0.4/src/actions/transformations/replace_comments.cc: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(input, value.c_str(), value.size() + 1);
data/modsecurity-3.0.4/src/actions/transformations/sql_hex_decode.cc:57: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(input, value.c_str(), value.length()+1);
data/modsecurity-3.0.4/src/actions/transformations/url_decode.cc:47: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(val, value.c_str(), value.size() + 1);
data/modsecurity-3.0.4/src/actions/transformations/url_decode_uni.cc:53: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(input, value.c_str(), value.length()+1);
data/modsecurity-3.0.4/src/actions/transformations/utf8_to_unicode.cc:50: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(input, value.c_str(), value.length()+1);
data/modsecurity-3.0.4/src/actions/transformations/utf8_to_unicode.cc:72:14:  [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 unicode[8];
data/modsecurity-3.0.4/src/actions/transformations/utf8_to_unicode.cc:103:30:  [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 z[2];
data/modsecurity-3.0.4/src/audit_log/writer/parallel.cc:50: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 tstr[300];
data/modsecurity-3.0.4/src/audit_log/writer/parallel.cc:80:49:  [2] (misc) open:
  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).
        ret = utils::SharedFiles::getInstance().open(m_audit->m_path1, error);
data/modsecurity-3.0.4/src/audit_log/writer/parallel.cc:87:49:  [2] (misc) open:
  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).
        ret = utils::SharedFiles::getInstance().open(m_audit->m_path2, error);
data/modsecurity-3.0.4/src/audit_log/writer/parallel.cc:145:10:  [2] (misc) open:
  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).
    fd = open(fileName.c_str(), O_CREAT | O_WRONLY | O_APPEND,
data/modsecurity-3.0.4/src/audit_log/writer/parallel.cc:156:12:  [2] (misc) open:
  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).
    myfile.open(a, std::ofstream::out | std::ofstream::app);
data/modsecurity-3.0.4/src/audit_log/writer/serial.cc:32:46:  [2] (misc) open:
  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).
    return utils::SharedFiles::getInstance().open(m_audit->m_path1, error);
data/modsecurity-3.0.4/src/debug_log/debug_log.cc:42:35:  [2] (misc) open:
  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).
    DebugLogWriter::getInstance().open(m_fileName, error);
data/modsecurity-3.0.4/src/debug_log/debug_log_writer.cc:36:21:  [2] (misc) open:
  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).
int DebugLogWriter::open(const std::string& fileName, std::string *error) {
data/modsecurity-3.0.4/src/debug_log/debug_log_writer.cc:37:46:  [2] (misc) open:
  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).
    return utils::SharedFiles::getInstance().open(fileName, error);
data/modsecurity-3.0.4/src/debug_log/debug_log_writer.h:45:9:  [2] (misc) open:
  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).
    int open(const std::string& m_fileName, std::string *error);
data/modsecurity-3.0.4/src/engine/lua.h:50:14:  [2] (buffer) memcpy:
  Does not check for buffer overflows when copying to destination (CWE-120).
  Make sure destination can always hold the source data.
        std::memcpy(d + m_len, data, len);
data/modsecurity-3.0.4/src/operators/detect_sqli.cc:30: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 fingerprint[8];
data/modsecurity-3.0.4/src/operators/fuzzy_hash.cc:101: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 result[FUZZY_MAX_RESULT];
data/modsecurity-3.0.4/src/operators/inspect_file.cc:57:9:  [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 buff[512];
data/modsecurity-3.0.4/src/operators/validate_byte_range.h:47: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 table[32];
data/modsecurity-3.0.4/src/operators/validate_dtd.h:55:9:  [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/modsecurity-3.0.4/src/operators/validate_dtd.h:72:9:  [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/modsecurity-3.0.4/src/operators/validate_schema.h:67:9:  [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/modsecurity-3.0.4/src/operators/validate_schema.h:82:9:  [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/modsecurity-3.0.4/src/operators/validate_schema.h:97:9:  [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/modsecurity-3.0.4/src/operators/validate_schema.h:114:9:  [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/modsecurity-3.0.4/src/operators/verify_cpf.cc:44: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 s_cpf[11];
data/modsecurity-3.0.4/src/operators/verify_cpf.cc:45: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 bad_cpf[12][12] = { "00000000000",
data/modsecurity-3.0.4/src/operators/verify_ssn.cc:92:12:  [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).
    area = atoi(str_area.c_str());
data/modsecurity-3.0.4/src/operators/verify_ssn.cc:93:11:  [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).
    grp = atoi(str_grp.c_str());
data/modsecurity-3.0.4/src/operators/verify_ssn.cc:94:14:  [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).
    serial = atoi(str_serial.c_str());
data/modsecurity-3.0.4/src/operators/verify_svnr.cc:29: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 s_svnr[11];
data/modsecurity-3.0.4/src/operators/verify_svnr.cc:30: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 bad_svnr[12][11] = { "0000000000",
data/modsecurity-3.0.4/src/parser/seclang-parser.cc:2691:47:  [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).
          driver.m_debugLog->setDebugLogLevel(atoi(yystack_[0].value.as < std::string > ().c_str()));
data/modsecurity-3.0.4/src/parser/seclang-parser.cc:2761:45:  [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).
        driver.m_requestBodyLimit.m_value = atoi(yystack_[0].value.as < std::string > ().c_str());
data/modsecurity-3.0.4/src/parser/seclang-parser.cc:2770:52:  [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).
        driver.m_requestBodyNoFilesLimit.m_value = atoi(yystack_[0].value.as < std::string > ().c_str());
data/modsecurity-3.0.4/src/parser/seclang-parser.cc:2792:46:  [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).
        driver.m_responseBodyLimit.m_value = atoi(yystack_[0].value.as < std::string > ().c_str());
data/modsecurity-3.0.4/src/parser/seclang-parser.cc:2905:13:  [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).
        if (atoi(yystack_[0].value.as < std::string > ().c_str()) == 1) {
data/modsecurity-3.0.4/src/parser/seclang-parser.cc:5573: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 const *yyarg[YYERROR_VERBOSE_ARGS_MAXIMUM];
data/modsecurity-3.0.4/src/parser/seclang-scanner.cc:8467:16:  [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).
        yyin = fopen(f.c_str(), "r" );
data/modsecurity-3.0.4/src/parser/seclang-scanner.cc:8499:16:  [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).
        yyin = fopen(f.c_str(), "r" );
data/modsecurity-3.0.4/src/request_body_processor/multipart.cc:407: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 tstr[300];
data/modsecurity-3.0.4/src/request_body_processor/multipart.cc:425:10:  [2] (tmpfile) mkstemp:
  Potential for temporary file vulnerability in some circumstances. Some
  older Unix-like systems create temp files with permission to write by all
  by default, so be sure to set the umask to override this. Also, some older
  Unix systems might fail to use O_EXCL when opening the file, so make sure
  that O_EXCL is used by the library (CWE-377).
    fd = mkstemp(tmp);
data/modsecurity-3.0.4/src/request_body_processor/multipart.cc:440: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 localreserve[2] = { '\0', '\0' }; /* initialized to quiet warning */
data/modsecurity-3.0.4/src/request_body_processor/multipart.h:147: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 m_buf[MULTIPART_BUF_SIZE + 2];
data/modsecurity-3.0.4/src/request_body_processor/multipart.h:172: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 m_reserve[4];
data/modsecurity-3.0.4/src/rules_properties.cc:91:20:  [2] (integer) atol:
  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).
        codepage = atol(p);
data/modsecurity-3.0.4/src/transaction.cc:308:9:  [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(key_c, key.c_str(), key_s);
data/modsecurity-3.0.4/src/transaction.cc:309:9:  [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(value_c, value.c_str(), value_s);
data/modsecurity-3.0.4/src/transaction.cc:1394: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 tstr[300];
data/modsecurity-3.0.4/src/transaction.cc:1454: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 tstr[300];
data/modsecurity-3.0.4/src/unique_id.cc:76: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 machine_name[MAX_MACHINE_NAME_SIZE];
data/modsecurity-3.0.4/src/unique_id.cc:109: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 mac[MAC_ADDRESS_SIZE];
data/modsecurity-3.0.4/src/unique_id.cc:147: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 ifconfbuf[128 * sizeof(struct ifreq)];
data/modsecurity-3.0.4/src/utils/acmp.cc:46:14:  [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 bin_parm[3] = { 0 };
data/modsecurity-3.0.4/src/utils/acmp.cc:242: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(to, from, sizeof(acmp_node_t));
data/modsecurity-3.0.4/src/utils/acmp.h:112: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 u8_buff[6];
data/modsecurity-3.0.4/src/utils/md5.cc:11:14:  [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 digest[16];
data/modsecurity-3.0.4/src/utils/md5.cc:16: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[33];
data/modsecurity-3.0.4/src/utils/md5.cc:18:9:  [2] (buffer) sprintf:
  Does not check for buffer overflows (CWE-120). Use sprintf_s, snprintf, or
  vsnprintf. Risk is low because the source has a constant maximum length.
        sprintf(buf+i*2, "%02x", digest[i]);
data/modsecurity-3.0.4/src/utils/md5.cc:26:14:  [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 output[16];
data/modsecurity-3.0.4/src/utils/msc_tree.cc:95: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(prefix->buffer, ipdata, ip_bitmask/8);
data/modsecurity-3.0.4/src/utils/msc_tree.cc:705:14:  [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 temp_data[NETMASK_256-1];
data/modsecurity-3.0.4/src/utils/msc_tree.cc:733: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(temp_data, ipdata, bytes);
data/modsecurity-3.0.4/src/utils/msc_tree.cc:821: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 ip_strv4[NETMASK_32], ip_strv6[NETMASK_128];
data/modsecurity-3.0.4/src/utils/msc_tree.cc:1064:16:  [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).
        cidr = atoi(mask_str);
data/modsecurity-3.0.4/src/utils/msc_tree.cc:1099:16:  [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).
        cidr = atoi(mask_str);
data/modsecurity-3.0.4/src/utils/sha1.cc:28:14:  [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 digest[20] = { 0 };
data/modsecurity-3.0.4/src/utils/sha1.cc:46:14:  [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 output[20];
data/modsecurity-3.0.4/src/utils/shared_files.cc:60:10:  [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).
    fp = fopen(fileName.c_str(), "a");
data/modsecurity-3.0.4/src/utils/shared_files.cc:108:9:  [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(new_debug_log->file_name, fileName.c_str(), fileName.size());
data/modsecurity-3.0.4/src/utils/shared_files.cc:127:19:  [2] (misc) open:
  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).
bool SharedFiles::open(const std::string& fileName, std::string *error) {
data/modsecurity-3.0.4/src/utils/shared_files.h:59:10:  [2] (misc) open:
  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).
    bool open(const std::string& fileName, std::string *error);
data/modsecurity-3.0.4/src/utils/string.h:34:7:  [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.
const char HEX2DEC[256] = {
data/modsecurity-3.0.4/src/utils/system.cc:168:16:  [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).
    FILE *fp = fopen(f.c_str(), "r");
data/modsecurity-3.0.4/src/variables/time.cc:40: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 tstr[200];
data/modsecurity-3.0.4/src/variables/time_day.cc:39: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 tstr[200];
data/modsecurity-3.0.4/src/variables/time_hour.cc:39: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 tstr[200];
data/modsecurity-3.0.4/src/variables/time_min.cc:39: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 tstr[200];
data/modsecurity-3.0.4/src/variables/time_mon.cc:39: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 tstr[200];
data/modsecurity-3.0.4/src/variables/time_mon.cc:48:13:  [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).
    int a = atoi(tstr);
data/modsecurity-3.0.4/src/variables/time_sec.cc:39: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 tstr[200];
data/modsecurity-3.0.4/src/variables/time_wday.cc:39: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 tstr[200];
data/modsecurity-3.0.4/src/variables/time_year.cc:39: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 tstr[200];
data/modsecurity-3.0.4/test/common/modsecurity_test.cc:50: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 errbuf[1024];
data/modsecurity-3.0.4/test/common/modsecurity_test.cc:54:12:  [2] (misc) open:
  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).
    myfile.open(file.c_str());
data/modsecurity-3.0.4/test/common/modsecurity_test.cc:159:34:  [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).
            m_test_number = std::atoi(test_numbers.c_str());
data/modsecurity-3.0.4/examples/reading_logs_via_rule_message/reading_logs_via_rule_message.h:88:9:  [1] (obsolete) usleep:
  This C routine is considered obsolete (as opposed to the shell command by
  the same name). The interaction of this function with SIGALRM and other
  timer functions such as sleep(), alarm(), setitimer(), and nanosleep() is
  unspecified (CWE-676). Use nanosleep(2) or setitimer(2) instead.
        usleep(10);
data/modsecurity-3.0.4/examples/reading_logs_via_rule_message/reading_logs_via_rule_message.h:98: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).
            strlen((const char*)response_body));
data/modsecurity-3.0.4/examples/reading_logs_via_rule_message/reading_logs_via_rule_message.h:160:9:  [1] (obsolete) usleep:
  This C routine is considered obsolete (as opposed to the shell command by
  the same name). The interaction of this function with SIGALRM and other
  timer functions such as sleep(), alarm(), setitimer(), and nanosleep() is
  unspecified (CWE-676). Use nanosleep(2) or setitimer(2) instead.
        usleep(10000);
data/modsecurity-3.0.4/examples/reading_logs_with_offset/read.cc:24:45:  [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).
    ret = msc.processContentOffset(request, strlen(request),
data/modsecurity-3.0.4/examples/using_bodies_in_chunks/simple_request.cc:205:9:  [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).
        strlen((const char*)request_body_first));
data/modsecurity-3.0.4/examples/using_bodies_in_chunks/simple_request.cc:210:9:  [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).
        strlen((const char*)request_body_second));
data/modsecurity-3.0.4/examples/using_bodies_in_chunks/simple_request.cc:215:9:  [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).
        strlen((const char*)request_body_third));
data/modsecurity-3.0.4/examples/using_bodies_in_chunks/simple_request.cc:245:9:  [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).
        strlen((const char*)response_body_first));
data/modsecurity-3.0.4/examples/using_bodies_in_chunks/simple_request.cc:250:9:  [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).
        strlen((const char*)response_body_second));
data/modsecurity-3.0.4/examples/using_bodies_in_chunks/simple_request.cc:255:9:  [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).
        strlen((const char*)response_body_third));
data/modsecurity-3.0.4/headers/modsecurity/anchored_set_variable.h:52:22:  [1] (buffer) equal:
  Function does not check the second iterator for over-read conditions
  (CWE-126). This function is often discouraged by most C++ coding standards
  in favor of its safer alternatives provided since C++14. Consider using a
  form of this function that checks the second iterator before potentially
  overflowing it.
             && std::equal(Left.begin(), Left.end(), Right.begin(),
data/modsecurity-3.0.4/headers/modsecurity/transaction.h:77:67:  [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).
    yajl_gen_string(g, reinterpret_cast<const unsigned char*>(a), strlen(a)); \
data/modsecurity-3.0.4/headers/modsecurity/transaction.h:80:11:  [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).
          strlen("")); \
data/modsecurity-3.0.4/headers/modsecurity/transaction.h:83:11:  [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).
          strlen(b)); \
data/modsecurity-3.0.4/headers/modsecurity/transaction.h:88:67:  [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).
    yajl_gen_string(g, reinterpret_cast<const unsigned char*>(a), strlen(a)); \
data/modsecurity-3.0.4/headers/modsecurity/transaction.h:89:58:  [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).
    yajl_gen_number(g, reinterpret_cast<const char*>(b), strlen(b));
data/modsecurity-3.0.4/headers/modsecurity/transaction.h:92:67:  [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).
    yajl_gen_string(g, reinterpret_cast<const unsigned char*>(a), strlen(a)); \
data/modsecurity-3.0.4/others/libinjection/src/example1.c:18:12:  [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).
    slen = strlen(input);
data/modsecurity-3.0.4/others/libinjection/src/fptool.c:40:12:  [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).
    slen = strlen(argv[offset]);
data/modsecurity-3.0.4/others/libinjection/src/html5_cli.c:151:12:  [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).
    slen = strlen(argv[offset]);
data/modsecurity-3.0.4/others/libinjection/src/libinjection_sqli.c:1985:18:  [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).
    size_t len = strlen(sql_state->fingerprint);
data/modsecurity-3.0.4/others/libinjection/src/libinjection_sqli.c:2037:19:  [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).
    size_t tlen = strlen(sql_state->fingerprint);
data/modsecurity-3.0.4/others/libinjection/src/libinjection_sqli.c:2048:38:  [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).
                      "sp_password", strlen("sp_password"))) {
data/modsecurity-3.0.4/others/libinjection/src/libinjection_sqli.c:2262:51:  [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).
                          sql_state->fingerprint, strlen(sql_state->fingerprint))) {
data/modsecurity-3.0.4/others/libinjection/src/libinjection_sqli.c:2267:55:  [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).
                              sql_state->fingerprint, strlen(sql_state->fingerprint))) {
data/modsecurity-3.0.4/others/libinjection/src/libinjection_sqli.c:2284:55:  [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).
                              sql_state->fingerprint, strlen(sql_state->fingerprint))) {
data/modsecurity-3.0.4/others/libinjection/src/libinjection_sqli.c:2289:59:  [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).
                                  sql_state->fingerprint, strlen(sql_state->fingerprint))) {
data/modsecurity-3.0.4/others/libinjection/src/libinjection_sqli.c:2301:55:  [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).
                              sql_state->fingerprint, strlen(sql_state->fingerprint))) {
data/modsecurity-3.0.4/others/libinjection/src/reader.c:128:35:  [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 = modp_rtrim(linebuf, strlen(linebuf));
data/modsecurity-3.0.4/others/libinjection/src/sqli_cli.c:140:12:  [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).
    slen = strlen(argv[offset]);
data/modsecurity-3.0.4/others/libinjection/src/test_speed_sqli.c:41: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).
        slen = strlen(s[j]);
data/modsecurity-3.0.4/others/libinjection/src/test_speed_xss.c:58: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).
        slen = strlen(s[j]);
data/modsecurity-3.0.4/others/libinjection/src/testdriver.c:180:39:  [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).
    g_expected[modp_rtrim(g_expected, strlen(g_expected))] = '\0';
data/modsecurity-3.0.4/others/libinjection/src/testdriver.c:181:33:  [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).
    g_input[modp_rtrim(g_input, strlen(g_input))] = '\0';
data/modsecurity-3.0.4/others/libinjection/src/testdriver.c:184:12:  [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).
    slen = strlen(g_input);
data/modsecurity-3.0.4/others/libinjection/src/testdriver.c:240:35:  [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).
    g_actual[modp_rtrim(g_actual, strlen(g_actual))] = '\0';
data/modsecurity-3.0.4/src/actions/action.cc:42:28:  [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 (op.compare(1, std::strlen(#a), #a) == 0)
data/modsecurity-3.0.4/src/actions/transformations/sql_hex_decode.cc:106:12:  [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).
    return strlen(reinterpret_cast<char *>(begin));
data/modsecurity-3.0.4/src/actions/transformations/transformation.cc:64:27:  [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 (a.compare(2, std::strlen(#b), #b) == 0)
data/modsecurity-3.0.4/src/actions/transformations/utf8_to_unicode.cc:56: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).
            strlen(reinterpret_cast<char *>(out)));
data/modsecurity-3.0.4/src/actions/transformations/utf8_to_unicode.cc:130:30:  [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).
                    length = strlen(reinterpret_cast<char *>(unicode));
data/modsecurity-3.0.4/src/actions/transformations/utf8_to_unicode.cc:181:30:  [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).
                    length = strlen(reinterpret_cast<char *>(unicode));
data/modsecurity-3.0.4/src/actions/transformations/utf8_to_unicode.cc:242:30:  [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).
                    length = strlen(reinterpret_cast<char *>(unicode));
data/modsecurity-3.0.4/src/collection/backend/in_memory-per_process.h:52:22:  [1] (buffer) equal:
  Function does not check the second iterator for over-read conditions
  (CWE-126). This function is often discouraged by most C++ coding standards
  in favor of its safer alternatives provided since C++14. Consider using a
  form of this function that checks the second iterator before potentially
  overflowing it.
             && std::equal(Left.begin(), Left.end(), Right.begin(),
data/modsecurity-3.0.4/src/engine/lua.cc:119:29:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
    const char *data = lsb->read(size);
data/modsecurity-3.0.4/src/engine/lua.h:56:17:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
    const char *read(size_t *len) {
data/modsecurity-3.0.4/src/modsecurity.cc:245:9:  [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).
        strlen("match"));
data/modsecurity-3.0.4/src/modsecurity.cc:251: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).
            strlen("variable"));
data/modsecurity-3.0.4/src/modsecurity.cc:255: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).
            strlen("highlight"));
data/modsecurity-3.0.4/src/modsecurity.cc:268: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).
            strlen("startingAt"));
data/modsecurity-3.0.4/src/modsecurity.cc:273: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).
            strlen("size"));
data/modsecurity-3.0.4/src/modsecurity.cc:294: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).
            strlen("value"));
data/modsecurity-3.0.4/src/modsecurity.cc:300: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).
            strlen("value"));
data/modsecurity-3.0.4/src/modsecurity.cc:311: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).
            strlen("transformation"));
data/modsecurity-3.0.4/src/modsecurity.cc:324: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).
            strlen("value"));
data/modsecurity-3.0.4/src/modsecurity.cc:336: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).
            strlen("operator"));
data/modsecurity-3.0.4/src/modsecurity.cc:343: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).
            strlen("highlight"));
data/modsecurity-3.0.4/src/modsecurity.cc:352: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).
            strlen("startingAt"));
data/modsecurity-3.0.4/src/modsecurity.cc:357: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).
            strlen("size"));
data/modsecurity-3.0.4/src/modsecurity.cc:369: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).
            strlen("value"));
data/modsecurity-3.0.4/src/operators/pm.cc:59:20:  [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 (n->text && strlen(n->text) > 0) {
data/modsecurity-3.0.4/src/operators/pm.cc:64:23:  [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 (n->pattern && strlen(n->pattern) > 0) {
data/modsecurity-3.0.4/src/parser/seclang-scanner.cc:5328:14:  [1] (buffer) getc:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
			     (c = getc( yyin )) != EOF && c != '\n'; ++n ) \
data/modsecurity-3.0.4/src/parser/seclang-scanner.cc:8485:7:  [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).
    f[strlen(f)-1] = '\0';
data/modsecurity-3.0.4/src/parser/seclang-scanner.cc:9381:37:  [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).
	return yy_scan_bytes( yystr, (int) strlen(yystr) );
data/modsecurity-3.0.4/src/request_body_processor/multipart.cc:195:11:  [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(data);
data/modsecurity-3.0.4/src/request_body_processor/multipart.cc:388: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).
                        + std::to_string(strlen(p)) + " bytes");
data/modsecurity-3.0.4/src/request_body_processor/multipart.cc:1268: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(b);
data/modsecurity-3.0.4/src/request_body_processor/multipart.cc:1415:41:  [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 (m_buf_contains_line && (strlen(m_buf) > 3) && (*(m_buf) == '-')
data/modsecurity-3.0.4/src/request_body_processor/multipart.cc:1418:22:  [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 ((strlen(m_buf) >= m_boundary.size() + 2)
data/modsecurity-3.0.4/src/request_body_processor/multipart.cc:1493:29:  [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).
                        && (strlen(m_buf) >= m_boundary.size() + 3)
data/modsecurity-3.0.4/src/request_body_processor/multipart.h:49:22:  [1] (buffer) equal:
  Function does not check the second iterator for over-read conditions
  (CWE-126). This function is often discouraged by most C++ coding standards
  in favor of its safer alternatives provided since C++14. Consider using a
  form of this function that checks the second iterator before potentially
  overflowing it.
             && std::equal(Left.begin(), Left.end(), Right.begin(),
data/modsecurity-3.0.4/src/rules_properties.cc:85:17:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
    file_stream.read(buf, length);
data/modsecurity-3.0.4/src/transaction.cc:435:58:  [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).
    m_variablePathInfo.set(path_info, m_variableOffset + strlen(method) +
data/modsecurity-3.0.4/src/transaction.cc:438:9:  [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).
        strlen(method) + 1, var_size);
data/modsecurity-3.0.4/src/transaction.cc:447: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).
            strlen(method) + 1 + offset + 1);
data/modsecurity-3.0.4/src/transaction.cc:664:9:  [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).
        strlen(reinterpret_cast<const char *>(key)),
data/modsecurity-3.0.4/src/transaction.cc:666:9:  [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).
        strlen(reinterpret_cast<const char *>(value)));
data/modsecurity-3.0.4/src/transaction.cc:1071:9:  [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).
        strlen(reinterpret_cast<const char *>(key)),
data/modsecurity-3.0.4/src/transaction.cc:1073:9:  [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).
        strlen(reinterpret_cast<const char *>(value)));
data/modsecurity-3.0.4/src/transaction.cc:1479:26:  [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).
            size_t pos = strlen("REQUEST_HEADERS:");
data/modsecurity-3.0.4/src/transaction.cc:1578:9:  [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).
        strlen("transaction"));
data/modsecurity-3.0.4/src/transaction.cc:1592:9:  [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).
        strlen("request"));
data/modsecurity-3.0.4/src/transaction.cc:1611: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).
            strlen("headers"));
data/modsecurity-3.0.4/src/transaction.cc:1629:9:  [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).
        strlen("response"));
data/modsecurity-3.0.4/src/transaction.cc:1641: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).
            strlen("headers"));
data/modsecurity-3.0.4/src/transaction.cc:1659: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).
            strlen("producer"));
data/modsecurity-3.0.4/src/transaction.cc:1676: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).
            strlen("components"));
data/modsecurity-3.0.4/src/transaction.cc:1692: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).
            strlen("messages"));
data/modsecurity-3.0.4/src/transaction.cc:1699:17:  [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).
                strlen("details"));
data/modsecurity-3.0.4/src/transaction.cc:1713:17:  [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).
                strlen("tags"));
data/modsecurity-3.0.4/src/transaction.cc:1718:21:  [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).
                    strlen(b.c_str()));
data/modsecurity-3.0.4/src/utils/acmp.cc:60: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).
    op_len = strlen(content);
data/modsecurity-3.0.4/src/utils/acmp.cc:84: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).
    op_len = strlen(parm);
data/modsecurity-3.0.4/src/utils/acmp.cc:183:12:  [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).
    return strlen(str);
data/modsecurity-3.0.4/src/utils/acmp.cc:517:45:  [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).
            child->text = (char *)calloc(1, strlen(pattern) + 2);
data/modsecurity-3.0.4/src/utils/acmp.cc:525:52:  [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).
                child->pattern = (char *)calloc(1, strlen(pattern) + 2);
data/modsecurity-3.0.4/src/utils/base64.cc:69:18:  [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).
    size_t len = strlen(data.c_str());
data/modsecurity-3.0.4/src/utils/msc_tree.cc:838:13:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
            strncpy(ip_strv4, buffer, sizeof(ip_strv4));
data/modsecurity-3.0.4/src/utils/msc_tree.cc:856:28:  [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).
            else if (pos < strlen(ip_strv4)) {
data/modsecurity-3.0.4/src/utils/msc_tree.cc:873:13:  [1] (buffer) strncpy:
  Easily used incorrectly; doesn't always \0-terminate or check for invalid
  pointers [MS-banned] (CWE-120).
            strncpy(ip_strv6, buffer, sizeof(ip_strv6));
data/modsecurity-3.0.4/src/utils/msc_tree.cc:893:57:  [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).
            else if (netmask_v6 != NETMASK_128 && pos < strlen(ip_strv6)) {
data/modsecurity-3.0.4/src/utils/string.cc:89: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).
    if (str == NULL || strlen(str) == 0) {
data/modsecurity-3.0.4/src/variables/variable.h:140:49:  [1] (buffer) equal:
  Function does not check the second iterator for over-read conditions
  (CWE-126). This function is often discouraged by most C++ coding standards
  in favor of its safer alternatives provided since C++14. Consider using a
  form of this function that checks the second iterator before potentially
  overflowing it.
        return a.size() == m_key.size() && std::equal(a.begin(), a.end(),
data/modsecurity-3.0.4/src/variables/variable.h:168:22:  [1] (buffer) equal:
  Function does not check the second iterator for over-read conditions
  (CWE-126). This function is often discouraged by most C++ coding standards
  in favor of its safer alternatives provided since C++14. Consider using a
  form of this function that checks the second iterator before potentially
  overflowing it.
             && std::equal(a.begin(), a.end(), b.begin(),
data/modsecurity-3.0.4/src/variables/variable.h:554:22:  [1] (buffer) equal:
  Function does not check the second iterator for over-read conditions
  (CWE-126). This function is often discouraged by most C++ coding standards
  in favor of its safer alternatives provided since C++14. Consider using a
  form of this function that checks the second iterator before potentially
  overflowing it.
             && std::equal(m_collectionName.begin(), m_collectionName.end(),
data/modsecurity-3.0.4/test/benchmark/benchmark.cc:159: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).
            strlen((const char*)response_body));
data/modsecurity-3.0.4/test/common/modsecurity_test.cc:65: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).
        if (strlen(errbuf) > 0) {
data/modsecurity-3.0.4/test/common/modsecurity_test.cc:118:22:  [1] (buffer) equal:
  Function does not check the second iterator for over-read conditions
  (CWE-126). This function is often discouraged by most C++ coding standards
  in favor of its safer alternatives provided since C++14. Consider using a
  form of this function that checks the second iterator before potentially
  overflowing it.
            || !std::equal(json.rbegin(), json.rend(), filename.rbegin())) {
data/modsecurity-3.0.4/test/fuzzer/afl_fuzzer.cc:131:22:  [1] (buffer) read:
  Check buffer boundaries if used in a loop including recursive loops
  (CWE-120, CWE-20).
        read_bytes = read(STDIN_FILENO, buf, 128);
data/modsecurity-3.0.4/tools/rules-check/rules-check.cc:55:21:  [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 (arg[strlen(arg)-1] == '\"') {
data/modsecurity-3.0.4/tools/rules-check/rules-check.cc:56:37:  [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).
                argFull.append(arg, strlen(arg)-1);
data/modsecurity-3.0.4/tools/rules-check/rules-check.cc:65:21:  [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 (arg[strlen(arg)-1] == '\"') {
data/modsecurity-3.0.4/tools/rules-check/rules-check.cc:66:39:  [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).
                argFull.append(arg+1, strlen(arg) - 2);

ANALYSIS SUMMARY:

Hits = 313
Lines analyzed = 80498 in approximately 2.25 seconds (35733 lines/second)
Physical Source Lines of Code (SLOC) = 55477
Hits@level = [0]  98 [1] 114 [2] 174 [3]   2 [4]  23 [5]   0
Hits@level+ = [0+] 411 [1+] 313 [2+] 199 [3+]  25 [4+]  23 [5+]   0
Hits/KSLOC@level+ = [0+] 7.40848 [1+] 5.64198 [2+] 3.58707 [3+] 0.450637 [4+] 0.414586 [5+]   0
Dot directories skipped = 2 (--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.