Commit 897bc924 authored by Claudemir Todo Bom's avatar Claudemir Todo Bom

* comando para mover da quarentena para a entrada

parent 345cfaf2
Pipeline #170 passed with stage
in 2 minutes and 23 seconds
#!/bin/sh
USER=$1
GUID=$2
doveadm fetch -u "${USER}" guid mailbox Junk guid "${GUID}" | grep -q "${GUID}" || exit 1
doveadm move -u "${USER}" INBOX mailbox Junk guid "${GUID}"
exit $?
www-data ALL = (root) NOPASSWD: /usr/bin/mailq
www-data ALL = (root) NOPASSWD: /usr/sbin/exim4
www-data ALL = (mail) NOPASSWD: /usr/local/bin/junkrelease.sh
......@@ -2,10 +2,32 @@
require_once "wwmail.inc.php";
$htmlhead=
"<html>
<head>
<title>Liberação da Quarentena</title>
<meta name='viewport' content='width=device-width, user-scalable=no'>
<link rel='stylesheet' type='text/css' href='/wwmail/wwmail.css'>
</head>
<body>
<div id='main'>";
$htmlfoot="
</div>
</body>
</html>";
$config = parse_ini_string(file_read_without_comments("/etc/default/wwmail"));
var_dump($config);
$pathinfo = get_pathinfo();
var_dump($pathinfo);
phpinfo();
echo $htmlhead;
echo "<h2>Liberação de Quarentena</h2>";
if ($pathinfo) {
$command = 'sudo -u mail /usr/local/bin/junkrelease.sh ' . $pathinfo[0] . ' ' . $pathinfo[1] . '';
echo '<pre>' . $command . '</pre>';
}
echo $htmlfoot;
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment