Skip to content

Commit

Permalink
test(*): Use a different Bad ip for AppSec
Browse files Browse the repository at this point in the history
We try to avoid race condition
  • Loading branch information
julienloizelet committed Oct 10, 2024
1 parent b571eea commit d2a27f4
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions tests/Constants.php
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ class Constants
public const APPSEC_CONNECT_TIMEOUT_MS = 300;

public const BAD_IP = '1.2.3.4';
public const BAD_IP_APPSEC = '1.2.3.5';
public const IP_RANGE = '24';
public const JAPAN = 'JP';
}
2 changes: 1 addition & 1 deletion tests/Integration/BouncerTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -202,7 +202,7 @@ public function testAppSecDecision($requestHandler)

$headers = [
'X-Crowdsec-Appsec-Api-Key' => $bouncerKey,
'X-Crowdsec-Appsec-Ip' => TestConstants::BAD_IP,
'X-Crowdsec-Appsec-Ip' => TestConstants::BAD_IP_APPSEC,
'X-Crowdsec-Appsec-Host' => 'example.com',
'X-Crowdsec-Appsec-User-Agent' => 'Mozilla/5.0',
'X-Crowdsec-Appsec-Verb' => 'GET',
Expand Down

0 comments on commit d2a27f4

Please sign in to comment.