Skip to content

Instantly share code, notes, and snippets.

@brad-anton
Created August 1, 2016 14:25
Show Gist options
  • Save brad-anton/eafc52da26732f4ae99dc0a093298d49 to your computer and use it in GitHub Desktop.
Save brad-anton/eafc52da26732f4ae99dc0a093298d49 to your computer and use it in GitHub Desktop.
Simplified version of web-to-email vulnerability
$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