PHP WebShell

Текущая директория: /var/www/bitcardoApp/tools

Просмотр файла: mail_test.php

<?php
require_once __DIR__ . '/../config/bootstrap.php';
require_once __DIR__ . '/../lib/mailer.php';

if (!empty($_GET['to'])) {
  $to = trim($_GET['to']);
  $res = send_test_mail($to);
  header('Content-Type: text/plain');
  echo "Sent to: $to\n";
  echo "OK: " . ($res['ok'] ? 'yes' : 'no') . "\n";
  echo "Error: " . ($res['error'] ?? '(none)') . "\n";
  exit;
}
?>
<form method="get">
  <label>Send a test mail to:</label>
  <input name="to" type="email" required>
  <button>Send</button>
</form>
<p>Check your PHP error log for detailed SMTP handshake logs.</p>

Выполнить команду


Для локальной разработки. Не используйте в интернете!