Discussions of secure PHP coding. Security in software is important, so don't be afraid to ask. And when answering: be anal. Nitpick. No security vulnerability is too small.
I am writing a simple script that receives data from another site. The data is then processed and stored in my database. Since the data will always be coming from the same website, I'd like this forum's input on whether limiting access to the script based on host name is a legitimately secure tactic. Also, what is the php command to achieve this? Thanks for the advice in advance!
One way you could accomplish this is through a .htaccess command. Use the allow and deny directive on the file. I can't remember the exact directives. But you should be able find it googling for something like: htaccess deny allow...
maybe you could also try to simulate some public/private keys infrastructure.
Where sending site sends some key/token or whatever....that should be correct for your side to process....but this is probably not necessary
Make .htaccess approach first.