Disable direct access through frontend nginx in /reset/mail/

This commit is contained in:
dpeca 2018-04-12 00:09:35 +02:00 committed by GitHub
commit 4fa549c570
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -22,6 +22,7 @@ foreach ($arr as $arr_key => $arr_val) {
if ($ip == $_SERVER['SERVER_ADDR']) $ok=1;
if ($ip == '127.0.0.1') $ok=1;
if ($ok==0) exit;
if (isset($_SERVER['HTTP_X_REAL_IP']) || isset($_SERVER['HTTP_X_FORWARDED_FOR'])) exit;
//
// sourceforge.net/projects/postfixadmin/