Skip to content

update

14c74af
Select commit
Loading
Failed to load commit list.
Open

Prototype 2: Evaluating alternatives to YAJL for JSON processing #3540

update
14c74af
Select commit
Loading
Failed to load commit list.
SonarQubeCloud / SonarCloud Code Analysis succeeded Apr 18, 2026 in 3m 55s

Annotations

Check warning on line 71 in test/benchmark/json_benchmark.cc

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Add a using-declaration to this derived class to inherit the constructors of "runtime_error", and remove the ones you manually duplicated. Note that this may add other constructors to your derived class.

See more on https://sonarcloud.io/project/issues?id=owasp-modsecurity_ModSecurity&issues=AZ2HqeBsWym3B0O6okyS&open=AZ2HqeBsWym3B0O6okyS&pullRequest=3540

Check warning on line 419 in test/benchmark/json_benchmark.cc

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Replace this const reference to "std::string" by a "std::string_view".

See more on https://sonarcloud.io/project/issues?id=owasp-modsecurity_ModSecurity&issues=AZ1-doCWXISY38E6TxpR&open=AZ1-doCWXISY38E6TxpR&pullRequest=3540

Check failure on line 412 in src/request_body_processor/json_backend_jsoncons.cc

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Refactor this function to reduce its Cognitive Complexity from 43 to the 25 allowed.

See more on https://sonarcloud.io/project/issues?id=owasp-modsecurity_ModSecurity&issues=AZ2S1Y8Ky8hqXC4KRJ1z&open=AZ2S1Y8Ky8hqXC4KRJ1z&pullRequest=3540

Check warning on line 219 in test/common/json.h

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Catch a more specific exception instead of a generic one.

See more on https://sonarcloud.io/project/issues?id=owasp-modsecurity_ModSecurity&issues=AZ190QIVSTzC4JOHOn-i&open=AZ190QIVSTzC4JOHOn-i&pullRequest=3540

Check warning on line 39 in src/request_body_processor/json.cc

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Replace this const reference to "std::string" by a "std::string_view".

See more on https://sonarcloud.io/project/issues?id=owasp-modsecurity_ModSecurity&issues=AZ2H7l4Bym_e-6l8FQml&open=AZ2H7l4Bym_e-6l8FQml&pullRequest=3540

Check warning on line 269 in test/common/json.h

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Make the type of this parameter a pointer-to-const. The current type of "error" is "std::string *".

See more on https://sonarcloud.io/project/issues?id=owasp-modsecurity_ModSecurity&issues=AZ190QIVSTzC4JOHOn-n&open=AZ190QIVSTzC4JOHOn-n&pullRequest=3540

Check warning on line 123 in test/common/json.h

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Make this member overloaded operator a hidden friend.

See more on https://sonarcloud.io/project/issues?id=owasp-modsecurity_ModSecurity&issues=AZ190QIVSTzC4JOHOn-h&open=AZ190QIVSTzC4JOHOn-h&pullRequest=3540

Check warning on line 232 in src/modsecurity.cc

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Refactor this loop so that it is less error-prone.

See more on https://sonarcloud.io/project/issues?id=owasp-modsecurity_ModSecurity&issues=AZ190QIESTzC4JOHOn-d&open=AZ190QIESTzC4JOHOn-d&pullRequest=3540

Check warning on line 73 in src/operators/validate_byte_range.cc

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Use "std::byte" for byte-oriented data manipulation.

See more on https://sonarcloud.io/project/issues?id=owasp-modsecurity_ModSecurity&issues=AZ190QEMSTzC4JOHOn9q&open=AZ190QEMSTzC4JOHOn9q&pullRequest=3540

Check warning on line 288 in src/modsecurity.cc

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Refactor this loop so that it is less error-prone.

See more on https://sonarcloud.io/project/issues?id=owasp-modsecurity_ModSecurity&issues=AZ190QIESTzC4JOHOn-e&open=AZ190QIESTzC4JOHOn-e&pullRequest=3540

Check warning on line 183 in src/utils/json_writer.cc

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Use "std::byte" for byte-oriented data manipulation.

See more on https://sonarcloud.io/project/issues?id=owasp-modsecurity_ModSecurity&issues=AZ190QA8STzC4JOHOn9n&open=AZ190QA8STzC4JOHOn9n&pullRequest=3540

Check warning on line 262 in test/common/json.h

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Make the type of this parameter a pointer-to-const. The current type of "error" is "std::string *".

See more on https://sonarcloud.io/project/issues?id=owasp-modsecurity_ModSecurity&issues=AZ190QIVSTzC4JOHOn-m&open=AZ190QIVSTzC4JOHOn-m&pullRequest=3540

Check warning on line 568 in src/request_body_processor/json_backend_jsoncons.cc

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Use the init-statement to declare "sync_detail" inside the if statement.

See more on https://sonarcloud.io/project/issues?id=owasp-modsecurity_ModSecurity&issues=AZ2H7l3jym_e-6l8FQmi&open=AZ2H7l3jym_e-6l8FQmi&pullRequest=3540

Check warning on line 232 in test/common/json.h

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Make the type of this parameter a pointer-to-const. The current type of "error" is "std::string *".

See more on https://sonarcloud.io/project/issues?id=owasp-modsecurity_ModSecurity&issues=AZ190QIVSTzC4JOHOn-j&open=AZ190QIVSTzC4JOHOn-j&pullRequest=3540

Check warning on line 309 in test/common/json.h

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Catch a more specific exception instead of a generic one.

See more on https://sonarcloud.io/project/issues?id=owasp-modsecurity_ModSecurity&issues=AZ190QIVSTzC4JOHOn-p&open=AZ190QIVSTzC4JOHOn-p&pullRequest=3540

Check warning on line 144 in test/benchmark/json_benchmark.cc

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Use the init-statement to declare "current" inside the if statement.

See more on https://sonarcloud.io/project/issues?id=owasp-modsecurity_ModSecurity&issues=AZ2HqeBsWym3B0O6okyT&open=AZ2HqeBsWym3B0O6okyT&pullRequest=3540

Check failure on line 89 in test/common/modsecurity_test.cc

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Refactor this code to not nest more than 3 if|for|do|while|switch statements.

See more on https://sonarcloud.io/project/issues?id=owasp-modsecurity_ModSecurity&issues=AZ2S1ZDNy8hqXC4KRJ12&open=AZ2S1ZDNy8hqXC4KRJ12&pullRequest=3540

Check warning on line 486 in test/benchmark/json_benchmark.cc

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Replace this const reference to "std::string" by a "std::string_view".

See more on https://sonarcloud.io/project/issues?id=owasp-modsecurity_ModSecurity&issues=AZ1-doCWXISY38E6TxpU&open=AZ1-doCWXISY38E6TxpU&pullRequest=3540

Check warning on line 184 in src/utils/json_writer.cc

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Use "std::byte" for byte-oriented data manipulation.

See more on https://sonarcloud.io/project/issues?id=owasp-modsecurity_ModSecurity&issues=AZ190QA8STzC4JOHOn9o&open=AZ190QA8STzC4JOHOn9o&pullRequest=3540

Check warning on line 333 in test/common/json.h

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Catch a more specific exception instead of a generic one.

See more on https://sonarcloud.io/project/issues?id=owasp-modsecurity_ModSecurity&issues=AZ190QIVSTzC4JOHOn-r&open=AZ190QIVSTzC4JOHOn-r&pullRequest=3540

Check warning on line 321 in test/common/json.h

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Catch a more specific exception instead of a generic one.

See more on https://sonarcloud.io/project/issues?id=owasp-modsecurity_ModSecurity&issues=AZ190QIVSTzC4JOHOn-q&open=AZ190QIVSTzC4JOHOn-q&pullRequest=3540

Check warning on line 235 in test/regression/regression_test.cc

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

This lambda has 23 lines, which is greater than the 20 lines authorized. Split it into several lambdas or functions, or make it a named function.

See more on https://sonarcloud.io/project/issues?id=owasp-modsecurity_ModSecurity&issues=AZ2DVDgODPiZK5yPV1-J&open=AZ2DVDgODPiZK5yPV1-J&pullRequest=3540

Check warning on line 431 in test/regression/regression_test.cc

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

This function should be declared "const".

See more on https://sonarcloud.io/project/issues?id=owasp-modsecurity_ModSecurity&issues=AZ190QKvSTzC4JOHOn-4&open=AZ190QKvSTzC4JOHOn-4&pullRequest=3540

Check warning on line 156 in src/operators/validate_byte_range.cc

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Use "std::byte" for byte-oriented data manipulation.

See more on https://sonarcloud.io/project/issues?id=owasp-modsecurity_ModSecurity&issues=AZ2CBI6Kkud7vHWq0tqj&open=AZ2CBI6Kkud7vHWq0tqj&pullRequest=3540

Check warning on line 56 in src/request_body_processor/json_adapter.cc

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Prefer free functions over member functions when handling objects of generic type "InputType".

See more on https://sonarcloud.io/project/issues?id=owasp-modsecurity_ModSecurity&issues=AZ2H7l3vym_e-6l8FQmj&open=AZ2H7l3vym_e-6l8FQmj&pullRequest=3540