X-Git-Url: https://mop.ddnsfree.com/gitweb/?a=blobdiff_plain;f=web%2FObj%2Fprovider_proxy.phh;h=fc01ababc2ee5049d36eaa3a2581eb232a6a2a03;hb=1fa748bc1611126b0ddc1f6cc86d9926f1b743d2;hp=b1a4d954a1c54554cc926f46731d6374937883eb;hpb=be3641128b5416644c41236d49b8884626f3ecb9;p=brisk.git diff --git a/web/Obj/provider_proxy.phh b/web/Obj/provider_proxy.phh index b1a4d95..fc01aba 100644 --- a/web/Obj/provider_proxy.phh +++ b/web/Obj/provider_proxy.phh @@ -80,7 +80,7 @@ class ProviderProxy } } - function realip($header, $ip) + function realip(&$header, $ip) { fprintf(STDERR, "PP realip: [%d]\n", count($this->pp)); if ($this->pp != NULL) { @@ -89,7 +89,9 @@ class ProviderProxy if ($pp_item->ipclass->check($ip)) { if (isset($header[$pp_item->headitem])) { fprintf(STDERR, "PP: match public proxy [%s][%s]\n", $pp_name, $header[$pp_item->headitem]); - return ($header[$pp_item->headitem]); + $ret = $header['POST_'.$pp_item->headitem] = $header[$pp_item->headitem]; + unset($header[$pp_item->headitem]); + return ($ret); } } }