0

Request header is not present on fetch request in Chrome. (This same request is working on Mozilla)

https://docs.aws.amazon.com/AmazonS3/latest/userguide/cors.html

The request's Origin header must match an AllowedOrigin element

enter image description here

Also i have already enabled CORS Policy on Bucket.

Please suggest me where i am doing mistake!

Thanks in Advance!

Raj Kumar
  • 31
  • 6
  • yes @JaromandaX. But no request header present in request. Can you please help me out of this ? – Raj Kumar Aug 22 '22 at 05:36
  • @JaromandaX This same request is working on Firefox. – Raj Kumar Aug 22 '22 at 05:37
  • @JaromandaX I have already removed the MODE. Now AWS giving CORS error because ORIGIN is not present in header. – Raj Kumar Aug 22 '22 at 06:30
  • @JaromandaX Yes i have installed Nimbuzz, AdBlocker and CyberGhost. Should i remove all these three adons ? – Raj Kumar Aug 22 '22 at 06:38
  • @JaromandaX i removed all these three adons and restarted chrome. Giving same result as before http://i.imgur.com/FtuZYX4.png – Raj Kumar Aug 22 '22 at 06:50
  • @JaromandaX I have checked Edge Browser and same result. https://ibb.co/gM9MHm9 . – Raj Kumar Aug 22 '22 at 07:15
  • @JaromandaX Please have look to my code. https://codeshare.io/loEr9R I am using Angular v12 for this. – Raj Kumar Aug 22 '22 at 08:18
  • @JaromandaX Yes i have checked our 3 Systems and Also checked on Client MAC OS. And its giving same error. Also when i use XHR. Same thing happening with me. IDK whats happening with me ? Do you need screen recording for more clarify ? – Raj Kumar Aug 22 '22 at 09:01
  • @JaromandaX Please check screen recording both browser -> https://drive.google.com/drive/folders/1ND-LcLsCdGjQGzAN_u_DX1rEN5F6HenD?usp=sharing – Raj Kumar Aug 22 '22 at 09:10
  • no, I know what "there's no request headers" means - I just don't get why only chrome is having the issue, and why chrome works fine for me (except I get a 403 error - but request headers are sent) – Jaromanda X Aug 22 '22 at 09:10
  • Damn it - there's no request headers when the request is fulfilled by chromes cache – Jaromanda X Aug 22 '22 at 09:23
  • @JaromandaX That's why i m confused. You can solve it bro. I believe (: – Raj Kumar Aug 22 '22 at 10:39
  • 1
    try adding a "cache buster" to the url ... `\`?_=${Math.random()}\`` - of course, in the developer tools you can just disable caching :p – Jaromanda X Aug 22 '22 at 10:41
  • @JaromandaX Bro you are Genius. `disable caching` is worked for me. Now i am trying ?_=${Math.random()}. Thanks a lot bro – Raj Kumar Aug 22 '22 at 13:39
  • @JaromandaX Bro you are such a Great Genious.`?_=${Math.random()}` Its worked for me. http://i.imgur.com/2HFRWpc.png . Please post you answer i will accept you answer immediately. Bro please let me know where learned these things. – Raj Kumar Aug 22 '22 at 13:47
  • Can't add an answer unfortunately – Jaromanda X Aug 22 '22 at 13:53

0 Answers0