Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

ignoring invalid cors headers on Ingress "*" #1014

Closed
a180285 opened this issue Jul 4, 2023 · 2 comments
Closed

ignoring invalid cors headers on Ingress "*" #1014

a180285 opened this issue Jul 4, 2023 · 2 comments
Labels
Milestone

Comments

@a180285
Copy link

a180285 commented Jul 4, 2023

Description of the problem

I want to set CORS access-control-allow-headers to "*". but I got this errror.

ignoring invalid cors headers on Ingress "xx/xx" *

base on description here. "*" should be valid headers.

* (wildcard)
The value "*" only counts as a special wildcard value for requests without credentials (requests without [HTTP cookies]

(https://developer.mozilla.org/en-US/docs/Web/HTTP/Cookies) or HTTP authentication information). In requests with credentials, it is

 treated as the literal header name "*" without special semantics. Note that the [Authorization](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Authorization) header can't be wildcarded and always needs to be listed explicitly.


Expected behavior

Steps to reproduce the problem

  1. add annotation of haproxy-ingress.github.io/cors-allow-headers: '*' to ingress

Environment information

HAProxy Ingress version: v0.xx
image version: quay.io/jcmoraisjr/haproxy-ingress:v0.14.2

Root cause

Code corsHeadersRegex are hard coded. and without "*".

@a180285
Copy link
Author

a180285 commented Jul 10, 2023

@jcmoraisjr Thanks for quick fix.

@jcmoraisjr
Copy link
Owner

You're welcome. Closing.

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants