first commit
Some checks failed
Vulhub Format Check and Lint / format-check (push) Has been cancelled
Vulhub Format Check and Lint / markdown-check (push) Has been cancelled
Vulhub Docker Image CI / longtime-images-test (push) Has been cancelled
Vulhub Docker Image CI / images-test (push) Has been cancelled
Some checks failed
Vulhub Format Check and Lint / format-check (push) Has been cancelled
Vulhub Format Check and Lint / markdown-check (push) Has been cancelled
Vulhub Docker Image CI / longtime-images-test (push) Has been cancelled
Vulhub Docker Image CI / images-test (push) Has been cancelled
This commit is contained in:
5
phpmailer/CVE-2017-5223/www/composer.json
Normal file
5
phpmailer/CVE-2017-5223/www/composer.json
Normal file
@@ -0,0 +1,5 @@
|
||||
{
|
||||
"require": {
|
||||
"phpmailer/phpmailer": "5.2.20"
|
||||
}
|
||||
}
|
78
phpmailer/CVE-2017-5223/www/composer.lock
generated
Normal file
78
phpmailer/CVE-2017-5223/www/composer.lock
generated
Normal file
@@ -0,0 +1,78 @@
|
||||
{
|
||||
"_readme": [
|
||||
"This file locks the dependencies of your project to a known state",
|
||||
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file",
|
||||
"This file is @generated automatically"
|
||||
],
|
||||
"content-hash": "103a823b388422224b1368569073c034",
|
||||
"packages": [
|
||||
{
|
||||
"name": "phpmailer/phpmailer",
|
||||
"version": "v5.2.20",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/PHPMailer/PHPMailer.git",
|
||||
"reference": "efde5edb3da8e1d257e030e3c2d922c4de6e5d09"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/PHPMailer/PHPMailer/zipball/efde5edb3da8e1d257e030e3c2d922c4de6e5d09",
|
||||
"reference": "efde5edb3da8e1d257e030e3c2d922c4de6e5d09",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
"php": ">=5.0.0"
|
||||
},
|
||||
"require-dev": {
|
||||
"phpdocumentor/phpdocumentor": "*",
|
||||
"phpunit/phpunit": "4.7.*"
|
||||
},
|
||||
"suggest": {
|
||||
"league/oauth2-google": "Needed for Google XOAUTH2 authentication"
|
||||
},
|
||||
"type": "library",
|
||||
"autoload": {
|
||||
"classmap": [
|
||||
"class.phpmailer.php",
|
||||
"class.phpmaileroauth.php",
|
||||
"class.phpmaileroauthgoogle.php",
|
||||
"class.smtp.php",
|
||||
"class.pop3.php",
|
||||
"extras/EasyPeasyICS.php",
|
||||
"extras/ntlm_sasl_client.php"
|
||||
]
|
||||
},
|
||||
"notification-url": "https://packagist.org/downloads/",
|
||||
"license": [
|
||||
"LGPL-2.1"
|
||||
],
|
||||
"authors": [
|
||||
{
|
||||
"name": "Jim Jagielski",
|
||||
"email": "jimjag@gmail.com"
|
||||
},
|
||||
{
|
||||
"name": "Marcus Bointon",
|
||||
"email": "phpmailer@synchromedia.co.uk"
|
||||
},
|
||||
{
|
||||
"name": "Andy Prevost",
|
||||
"email": "codeworxtech@users.sourceforge.net"
|
||||
},
|
||||
{
|
||||
"name": "Brent R. Matzelle"
|
||||
}
|
||||
],
|
||||
"description": "PHPMailer is a full-featured email creation and transfer class for PHP",
|
||||
"time": "2016-12-28T13:36:42+00:00"
|
||||
}
|
||||
],
|
||||
"packages-dev": [],
|
||||
"aliases": [],
|
||||
"minimum-stability": "stable",
|
||||
"stability-flags": [],
|
||||
"prefer-stable": false,
|
||||
"prefer-lowest": false,
|
||||
"platform": [],
|
||||
"platform-dev": []
|
||||
}
|
45
phpmailer/CVE-2017-5223/www/index.php
Normal file
45
phpmailer/CVE-2017-5223/www/index.php
Normal file
@@ -0,0 +1,45 @@
|
||||
<?php
|
||||
require 'vendor/autoload.php';
|
||||
|
||||
if (isset($_POST['your-name'], $_POST['your-email'], $_POST['your-message'])) {
|
||||
$mail = new PHPMailer();
|
||||
$mail->isSMTP();
|
||||
$mail->Host = $_ENV['SMTP_SERVER'];
|
||||
$mail->SMTPAuth = true;
|
||||
$mail->Username = $_ENV['SMTP_EMAIL'];
|
||||
$mail->Password = $_ENV['SMTP_PASSWORD'];
|
||||
$mail->Port = intval($_ENV['SMTP_PORT']);
|
||||
$mail->CharSet = 'UTF-8';
|
||||
if (in_array($_ENV['SMTP_SECURE'], ['tls', 'ssl'])) {
|
||||
$mail->SMTPSecure = $_ENV['SMTP_SECURE'];
|
||||
} else {
|
||||
$mail->SMTPSecure = false;
|
||||
}
|
||||
|
||||
$message = <<<DATA
|
||||
<p><strong>{$_POST['your-name']}</strong>您好,您反馈的意见如下:</p>
|
||||
|
||||
<blackquote>{$_POST['your-message']}</blockquote>
|
||||
|
||||
<p>我们将在24小时内给予您回复,请耐心等待!</p>
|
||||
DATA;
|
||||
$mail->SetFrom($_POST["your-email"], $_POST["your-name"]);
|
||||
$mail->AddAddress($_POST["your-email"], $_POST["your-name"]);
|
||||
$mail->Subject = "您反馈的意见我们已经收到";
|
||||
$mail->MsgHTML($message);
|
||||
if(!$mail->Send()) echo "Error: ".$mail->ErrorInfo; else echo "Success!";
|
||||
}
|
||||
?>
|
||||
<html>
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
</head>
|
||||
<body>
|
||||
<h2>反馈意见</h2>
|
||||
<form method="post">
|
||||
<p><label>昵称<br /><input type="text" name="your-name" value="" size="40" /></span> </label></p>
|
||||
<p><label>Email<br /><input type="email" name="your-email" value="" size="40" /></span> </label></p>
|
||||
<p><label>意见<br /><textarea name="your-message" cols="40" rows="10"></textarea></label></p>
|
||||
<p><input type="submit" value="提交" /></p>
|
||||
</body>
|
||||
</html>
|
Reference in New Issue
Block a user