Hi there,
Can someone point me to the right direction to validate a $_GET variable and in case is not IPV4 format, to ignore that request?
The proper URL format is: https://domain.com/myWS/reporting.php?key=1234&ip=xxx.xxx.xxx.xxx&other=1234
Sometimes, I get the following URL: https://domain.com/myWS/reporting.php?key=1234&ip=<!DOCTYPE...&other=1234
What I want is that if I have something different from a regexp matching the IP V4 format, I want to ignore/drop that request, not even log it in the log file (this will be an extra).
I want to achieve this in the sites-enabled config for that site, probably in the 'server' or 'location' directive, or wherever, just to get it working.
Thanks a lot in advance!
Edited 1 time(s). Last edit at 12/04/2012 05:19AM by cicovy.