Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

Improve support for port numbers in allowedOriginPattern of CorsConfiguration #26926

Closed
rstoyanchev opened this issue May 10, 2021 · 2 comments
Closed
Labels
in: web Issues in web modules (web, webmvc, webflux, websocket) status: superseded An issue that has been superseded by another type: enhancement A general enhancement

Comments

@rstoyanchev
Copy link
Contributor

Currently it's not possible to support any port or multiple, specific ports with a single pattern. The workaround is to create two origin patterns such as "https://*.example.com" and "https://*.example.com:*".

One idea is to enhance the pattern syntax with a comma separated list of ports or a wildcard:

https://*.example.com:[8080]
https://*.example.com:[8080,9000]
https://*.example.com:[*]

This was originally reported in #26892.

@rstoyanchev rstoyanchev added in: web Issues in web modules (web, webmvc, webflux, websocket) type: enhancement A general enhancement labels May 10, 2021
@rstoyanchev rstoyanchev added this to the 5.x Backlog milestone May 10, 2021
@korektur
Copy link
Contributor

@rstoyanchev can I do the change myself and open a merge request?

korektur added a commit to korektur/spring-framework that referenced this issue May 10, 2021
korektur added a commit to korektur/spring-framework that referenced this issue May 16, 2021
@rstoyanchev rstoyanchev removed this from the 5.x Backlog milestone May 17, 2021
@rstoyanchev rstoyanchev added the status: superseded An issue that has been superseded by another label May 17, 2021
@izeye
Copy link
Contributor

izeye commented May 22, 2021

This seems to have been meant to be closed by @rstoyanchev as it has been superseded by #26927.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
in: web Issues in web modules (web, webmvc, webflux, websocket) status: superseded An issue that has been superseded by another type: enhancement A general enhancement
Projects
None yet
4 participants