HTTP_GET Access to Password protected File
#4

I believe you can only structure an FTP URL like that. I also don't think it is even possible to circumvent the authorization with the HTTP() function, because you can't send the required HTTP Authorization headers. http://en.wikipedia.org/wiki/Basic_a...on#Client_side

I recommend writing a PHP script that can only be accessed from the localhost and the server's IP. This is probably the easiest way to keep unwanted persons out. Replace the x'es with your server IP.

PHP код:
<?php
    
if($_SERVER['REMOTE_IP'] != '127.0.0.1' && $_SERVER['REMOTE_IP'] != 'x.x.x.x')
    {
        
header('HTTP/1.1 403 Forbidden');
        exit();
    }
?>

Rest of file here
Reply


Messages In This Thread
HTTP_GET Access to Password protected File - by Dragony92 - 23.09.2013, 04:26
Re: HTTP_GET Access to Password protected File - by whatthefuck123 - 23.09.2013, 05:03
Re: HTTP_GET Access to Password protected File - by Dragony92 - 23.09.2013, 06:07
Re: HTTP_GET Access to Password protected File - by Vince - 23.09.2013, 09:20
Re: HTTP_GET Access to Password protected File - by Dragony92 - 23.09.2013, 09:37
Re: HTTP_GET Access to Password protected File - by iJumbo - 23.09.2013, 09:46
Re: HTTP_GET Access to Password protected File - by Dragony92 - 23.09.2013, 10:12

Forum Jump:


Users browsing this thread: 1 Guest(s)