diff options
Diffstat (limited to 'mirror.php')
-rw-r--r-- | mirror.php | 9 |
1 files changed, 9 insertions, 0 deletions
@@ -19,6 +19,15 @@ $ea = fopen($wurzel."erlaubteAdressen","r"); while (! feof($ea)) { $zeile = trim(fgets($ea)); + if ((strpos($zeile,"x:")!==false) && + (strpos($_SERVER["SERVER_ADDR"],":")!==false)) { + $zeile = explode(":",$zeile); + $my_addr = explode(":",$_SERVER["SERVER_ADDR"]); + foreach ($zeile as $key => $val) + if ($val=="x") + $zeile[$key]=$my_addr[$key]; + $zeile = implode(":",$zeile); + } if ($zeile == $_SERVER["REMOTE_ADDR"]) break; } |