Skip to main content
Filter by
Sorted by
Tagged with
0 votes
0 answers
31 views

HttpMethod.Post gives an 401 error even though it was supplied with credentials [duplicate]

I am trying to create a post method to create a data that pushes to my DB this is my service to call my API: public async Task CreateTest(TestsDto testDto) { try { var request = new ...
Ben's user avatar
  • 191
2 votes
0 answers
69 views

ASP.NET Core SignalR CORS issue: "Request header field X-Requested-With is not allowed by Access-Control-Allow-Headers in preflight response"

I'm facing an inconsistent CORS issue with SignalR in my ASP.NET Core and Angular application. On my machine, the connection works fine in Chrome but fails with a CORS error in Edge. However, for some ...
TuαΊ₯n Nguyα»…n TiαΊΏn's user avatar
1 vote
1 answer
202 views

CORS Error: Preflight Request (OPTIONS) Fails

I’m developing a translation API for a Chrome extension using Express and Netlify Functions. However, I’m encountering issues with CORS when making requests from the browser. The preflight OPTIONS ...
Jhj's user avatar
  • 43
1 vote
2 answers
356 views

How do I get Backblaze B2 to respond with Access-Control-Allow-Origin?

I'm trying to fetch an image using JavaScript from a Backblaze bucket that is set to allPrivate. I have a correct authorization code that works if I fetch the image like this: echo '<img src="'...
Castles's user avatar
  • 957
0 votes
1 answer
37 views

Why are my getting a preflight/Option request between server to server POST request

Please I'm making a POST request from my web Server(Node.js) to another web Server(Php). Can it be possible for my Node.js Server to make a preflight/OPTION request to the other PHP web server if the ...
Rareclint's user avatar
0 votes
1 answer
55 views

How to manually add response Access-Control-Allow headers to preflight requests

I have an express server ("express": "^4.19.2") set up and use this custom function to add response headers: const allowCORS = (req: Request, res: Response, next: NextFunction): ...
smaica's user avatar
  • 825
0 votes
0 answers
75 views

Preflight OPTIONS request fails fetching file from GitHub Pages site because of CORS error

I have an Android app and a Flutter-web app that fetch some files from my github pages site. The following command .\curl -v https://mygithubaccount.github.io/myrepository/config.yaml > log_command....
P5music's user avatar
  • 3,335
1 vote
0 answers
197 views

CORS breaks in Vite dev server but works in Webpack dev server

Most of our development uses a mock backend server running on the same machine as the Vite/Webpack dev server. We also need to connect the local dev server to the "real" Java BE server ...
Jordan Everscending's user avatar
4 votes
1 answer
9k views

CORS issue - Redirect is not allowed for a preflight request

UPDATE: I was able to solve the issue thanks to the Sean's suggestion below. Look at the response headers and see where the request wants to re-direct the client to (using the Location header). That ...
groove_of_course's user avatar
0 votes
2 answers
133 views

Google app engine: call from another domain not working

calling an app engine (jetty @WebServlet) from another domain gives an error. In the logs I see the 'preflight' successful result, but the servlet code is not reached (a printout as the first line ...
Edward Blurock's user avatar
0 votes
1 answer
509 views

Download a file from pre-signed url from s3 using Angular

Goal: My angular app needs to read this json file from AWS S3 Pre-signed URL Problem: When I'm trying to get with http call a Pre-signed URL from S3 bucket, I'm getting an error, https://mydomain has ...
Naor Yael's user avatar
  • 139
2 votes
0 answers
399 views

Preflight Request throwing an CORS error on AWS API Gateway

I am learning about nuances of AWS hosting. I have relatively small app that works well on localhost, and in combination with Postman. My setup is: S3 hosted React app - with Cloudfront distribution ...
Matija's user avatar
  • 31
0 votes
1 answer
433 views

ASP.NET Core 6 MVC : cors error on HttpPost only with authorization policy

I have added my ASP.NET Core 6 MVC application to Azure "App registrations" and I'm able to login using the Microsoft WebUI and perform GET requests to obtain e.g. my views. The application ...
Francesco B.'s user avatar
  • 3,187
-1 votes
2 answers
920 views

Call to web api blocked by CORS policy even though .net webapi allows all methods

UPDATE 2: SOLVED: See my answer below. UPDATE 1: Even if I hard code the program.cs in my webapi to ALWAYS set the Access-Control-Allow-Origin header the header is NOT set when calling the api with an ...
Toby Fieldgroove's user avatar
1 vote
0 answers
48 views

CORS preflight request is redirected and didn't passed

On my website, when user session is expired, the website redirects user to login page, nevertheless I have this CORS issue which doesn't allow me to do this: ...response to preflight request doesn't ...
SValley_Developer's user avatar

15 30 50 per page
1
2 3 4 5
…
29