1

According to W3.org, all sent XHRs with 'Date' header are terminated.

I am working on an extension that interacts with web server api that requires the 'Date' headers to be sent as part of the request.

Is there a different way to send the date header from chrome extension?

Sudarshan
  • 18,140
  • 7
  • 53
  • 61
ganoro
  • 508
  • 5
  • 11
  • 1
    Do you have any control over the API? Can you maybe use a custom `X-Data` header? – abraham Dec 05 '11 at 04:59
  • re: `all sent XHRs with 'Date' header are terminated.` Not according to my reading of the [specification](https://xhr.spec.whatwg.org/#the-setrequestheader%28%29-method) . It says "the remaining STEPS are teminated." And the steps refer to how a header is set into the request. The request itself still gets sent, but without the forbidden header. – Cheeso Mar 02 '17 at 18:27

1 Answers1

0

There's no special mechanism to do XHR from Chrome extensions. The same behavior should apply, and you should be able to set headers as in a regular web context.

Seems like a broken API though. This might help: What's the rationale behind the HTTP Date header?

Community
  • 1
  • 1
Boris Smus
  • 8,220
  • 2
  • 36
  • 33