3 ms·
Well cookies have a same-origin security policy for good reason, right? You don't want a http://en.wikipedia.org/wiki/Confused_deputy_problem http://en.wikipedi
by EGreg 12y ago
Well cookies have a same-origin security policy for good reason, right? You don't want a http://en.wikipedia.org/wiki/Confused_deputy_problem http://en.wikipedia.org/wiki/Confused_deputy_problem ... otherwise the web would be horribly insecure.
And imagine that any site could request any document from another site that you're logged into ... I could just steal your bank account info or anything else, by writing a LOLcats site that gives you 15GB of free storage, while silently sending targeted requests to all the banks. Your cookies would be submitted along with those requests and MY SITE would get the info.
Proxies can't send your cookies like the browser can.
No, there are good reasons for these restrictions. Servers should whitelist certain resources and sites. Now there is only this: http://xkcd.com/792/ http://xkcd.com/792/
- captainmuon 12y agoWell, a script should be able to set of a naked HTTP request to `othersite.com` without sending along the cookies for `othersite.com`. I don't see how that would allow new vulnerabilities. Basically, make XMLHttpRequest not use any cookies etc. when making requests to other domains.
- EGreg 12y agoYes without cookies it should be able to, since it can via a proxy. this should be a capability of browsers