Bug: Not respecting CORS policy causes blocked requests #291
Answered
by
JimBobSquarePants
account00001
asked this question in
Q&A
Answered by
JimBobSquarePants
Oct 16, 2022
Replies: 2 comments 14 replies
|
You can use It would be good to automate that though. |
13 replies
Answer selected by
account00001
|
These symptoms are unlike anything I have ever heard and the middleware is used on thousands of sites serving millions of images. With the default hashing strategy in place collision opportunities are 1 in 10s of millions. I haven’t forgotten about the CORS fix. I have local code that returns the correct response I’m just not sure whether the middleware is the best place to do so. Normally CORS behaviours are configured against individual endpoints in the routing configuration. |
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment









You can use
ImageSharpMiddlewareOptions.OnPrepareResponseAsyncto further augment the response headers before sending.It would be good to automate that though.