docs consolidation and others
This commit is contained in:
@@ -108,7 +108,8 @@ public class SsrfTests : SecurityTestBase
|
||||
var validator = new UrlValidator();
|
||||
|
||||
// Even if hostname looks external, resolved IP must be validated
|
||||
var externalLookingUrl = "http://attacker-controlled.example.com";
|
||||
// Example URL that could resolve to internal IP via DNS rebinding
|
||||
_ = "http://attacker-controlled.example.com";
|
||||
|
||||
// Simulate DNS resolving to internal IP
|
||||
var resolvedIp = IPAddress.Parse("127.0.0.1");
|
||||
@@ -122,7 +123,8 @@ public class SsrfTests : SecurityTestBase
|
||||
{
|
||||
// Arrange
|
||||
var validator = new UrlValidator();
|
||||
var initialUrl = "https://attacker.com/redirect";
|
||||
// Initial URL redirects to internal metadata endpoint
|
||||
_ = "https://attacker.com/redirect";
|
||||
var redirectTarget = "http://169.254.169.254/latest/meta-data/";
|
||||
|
||||
// Act - Check if redirect target is safe
|
||||
|
||||
Reference in New Issue
Block a user