Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix spec:appsec:rack for Rack 3.1 (latest) #3960

Merged
merged 1 commit into from
Sep 27, 2024

Conversation

vpellan
Copy link
Contributor

@vpellan vpellan commented Sep 27, 2024

What does this PR do?

This PR fix spec:appsec:rack by deleting the #body method from the Rack request gateway (as this method is not used anywhere in our code, and the reactive engine uses #form_hash to send the body to the WAF) and sets a default value of '0' to headers['content-length']

Motivation:

spec:appsec:rack was failing for Rack 3.1+. Rack is used by most, if not all of our clients, we must be sure to support the latest version (hopefully these failing tests were not critical)

Unsure? Have a question? Request a review!

@vpellan vpellan requested review from a team as code owners September 27, 2024 13:20
@codecov-commenter
Copy link

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 97.87%. Comparing base (74363cc) to head (304e43f).

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #3960      +/-   ##
==========================================
+ Coverage   97.85%   97.87%   +0.01%     
==========================================
  Files        1305     1305              
  Lines       78224    78219       -5     
  Branches     3887     3886       -1     
==========================================
+ Hits        76549    76553       +4     
+ Misses       1675     1666       -9     
Flag Coverage Δ
97.87% <100.00%> (+0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@pr-commenter
Copy link

pr-commenter bot commented Sep 27, 2024

Benchmarks

Benchmark execution time: 2024-09-27 13:42:05

Comparing candidate commit 304e43f in PR branch vpellan/appsec-rack-latest with baseline commit 74363cc in branch master.

Found 0 performance improvements and 0 performance regressions! Performance is the same for 23 metrics, 2 unstable metrics.

@TonyCTHsu TonyCTHsu added the dev/testing Involves testing processes (e.g. RSpec) label Sep 27, 2024
@vpellan vpellan merged commit 69ac3b8 into master Sep 27, 2024
203 checks passed
@vpellan vpellan deleted the vpellan/appsec-rack-latest branch September 27, 2024 15:10
@github-actions github-actions bot added this to the 2.4.0 milestone Sep 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
dev/testing Involves testing processes (e.g. RSpec)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants