Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Shaun E on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Alternative to HTTP-REFERER? 1

Status
Not open for further replies.

tviman

Programmer
Jul 25, 2002
2,123
US
Since HTTP-REFERER can be spoofed or is not sent by some browsers/firewalls, is there a viable alternative to making sure that a script is executed by a page on your own site?

There's always a better way. The fun is trying to find it!
 
not that i'm aware of - using LWP it seems easy to do - i've had no problems...


Kind Regards
Duncan
 
Thanks Duncan. I've not used LWP - can you give me a clue?

Thanks...



There's always a better way. The fun is trying to find it!
 
sorry - badley explained - I mean that I don't think you can stop Perl emulating a genuine web-page form action in any way


Kind Regards
Duncan
 
Sorry - maybe badly explained on my part... is there an alternative method to ensure that my form was executed from my website?

There's always a better way. The fun is trying to find it!
 
There is a programmatic way to handle it and a webserver way to handle this.

Programmatic:
On request log the timestamp in a file. Put the same timestamp into the URL or the form submission. On form submission make check this embedded timestamp against the timestamp on disk. if these match you are in business. The only way they can spoof you is with a brute force attack.

Using Apache and mod_rewrite you can make sure certain pages only get requests from certain other pages. Are you using apache?
 
hi [blsiberian[/b]

cute! no wonder you are at the top of the Forum MVPs tree!

have a star!!!

Cheers
Duncan
 
Amen to that!!! Heck... have another star!!!

And thanks for the help!

There's always a better way. The fun is trying to find it!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top