Re: Origin (was: Re: XHR LC Draft Feedback)

On Mon, Jun 23, 2008 at 1:18 PM, Bjoern Hoehrmann <> wrote:
> * Adam Barth wrote:
>>There are three cases:
>>1) Origin header missing:  This is a non-supporting browser.  Fall
>>back to existing CSRF defenses.
>>2) Origin header has a trusted value:  Accept the request.
>>3) Origin header has an untrusted value:  Reject the request.
> Yes, and I am saying, if the first case properly protects against these
> attacks, then you do not need the header. If it does not, then you have
> an insecure web application at least until you drop this case.

In this situation, users of non-supporting browsers are subject to
CSRF attacks but users of supporting browsers are protected from these
attacks.  This is incentive for browser vendors to adopt the Origin
header for cross-origin POSTs and is true of any client-side mechanism
for protecting against CSRF.

> For this
> kind of web application, when it needs to be used cross-site, the header
> does indeed have some "advantage" over the simpler cross-site indicator,
> but making inherently insecure applications a little less insecure, if
> you could also fully secure them, does not strike me as a good deal.

I don't understand this point.  Why is it inherently insecure for
Facebook or Slashdot to use multiple domains?  I don't see any
security risk in hosting IT Slashdot articles on and
Developer Slashdot articles on  Furthermore,
it seem entirely reasonable for Slashdot to want to issue POST
requests across these subdomains.  For example, each category might
wish to POST a search query to

> I would be quite interested in having an indicator
> that helps blocking unwanted cross site requests, like legacy cross site
> form posts, I just don't see how the non-"XHR2+AC"-'Origin' header is
> better than a much simpler, more difficult to manipulate, and privacy-
> enhanced cross site indicator.

The Origin header is better because it lets sites that use multiple
domains protect themselves from CSRF, whereas "Pragma: cross-site"
does not.  How can the Origin header be manipulated for cross-origin


Received on Monday, 23 June 2008 21:07:46 UTC