Created
August 1, 2016 14:25
-
-
Save brad-anton/eafc52da26732f4ae99dc0a093298d49 to your computer and use it in GitHub Desktop.
Simplified version of web-to-email vulnerability
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$DestinationAddress = "[email protected]"; | |
$Subject = "Contact Form Inquiry"; | |
while(list($key, $val) = each($_POST)) { | |
$GLOBALS[$key] = $val; | |
} | |
$Header = "From: $name <$email>\r\n"; | |
$Header .= "Reply-To: $name <$email>\r\n"; | |
mail($DestinationAddress, $Subject, $Message, $Header); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment