Forwarding hosts in rspamd
parent
76720f3e94
commit
8822eb57c8
|
@ -31,6 +31,30 @@ catch (PDOException $e) {
|
||||||
|
|
||||||
?>
|
?>
|
||||||
settings {
|
settings {
|
||||||
|
whitelist_forwarding_hosts {
|
||||||
|
priority = high;
|
||||||
|
<?php
|
||||||
|
try {
|
||||||
|
$stmt = $pdo->query("SELECT `host` FROM `forwarding_hosts`");
|
||||||
|
$rows = $stmt->fetchAll(PDO::FETCH_COLUMN);
|
||||||
|
}
|
||||||
|
catch (PDOException $e) {
|
||||||
|
$rows = array();
|
||||||
|
}
|
||||||
|
|
||||||
|
foreach ($rows as $host) {
|
||||||
|
echo "\t\t" . 'ip = "' . $host . '";' . "\n";
|
||||||
|
}
|
||||||
|
?>
|
||||||
|
apply "default" {
|
||||||
|
actions {
|
||||||
|
reject = 999.9;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
symbols [
|
||||||
|
"WHITELIST_FORWARDING_HOST"
|
||||||
|
]
|
||||||
|
}
|
||||||
<?php
|
<?php
|
||||||
$stmt = $pdo->query("SELECT DISTINCT `object` FROM `filterconf` WHERE `option` = 'highspamlevel' OR `option` = 'lowspamlevel'");
|
$stmt = $pdo->query("SELECT DISTINCT `object` FROM `filterconf` WHERE `option` = 'highspamlevel' OR `option` = 'lowspamlevel'");
|
||||||
$rows = $stmt->fetchAll(PDO::FETCH_ASSOC);
|
$rows = $stmt->fetchAll(PDO::FETCH_ASSOC);
|
||||||
|
|
Loading…
Reference in New Issue