I\'d like to restrict access to a PHP file on my server. This PHP file takes data from an HTTP GET request and appends it to a file. Simple. But I don\'t want this PHP fi
Define a salt in both your app and php file, then hash that salt combined with the current time. That's unlikely to ever get spoofed.
$hash = sha1(time() . 'bladieblasalt'); if($_GET['hash'] == sha1(time() . 'samehash')) { echo 'valid'; }