-
Notifications
You must be signed in to change notification settings - Fork 41.1k
server.port=8443 without SSL redirects login to 8080 #6140
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
Comments
/cc @rwinch |
@fmarot Thank you for the feedback. This is due to Spring Security's PortResolverImpl which attempts to work around a well know IE bug. From the javadoc:
If you want to use HTTP, the easiest solution is to select a port other than 8443 which is typically used for HTTPS and thus remapped to work around the IE bug. |
Thanks, @rwinch |
fmarot please wirte how u configure https to solve the problem of 8443 as soon as possible please please. |
Hi, I ran into the inverse of this problem, where I had configured ssl, but hadn't changed the default In this case, redirections go to port 8443. I understand this this is due to the IE bug, but it may be worth documenting that if you enable ssl that you need to change the value for |
Yup I'm having the same issue. I'm constrained by a broken OAuth2 redirect config that I have no control over. |
I just ran into this issue as well (with HTTPS configured to 8080) - log errors/warnings would be helpful if this case is triggered |
It's a little more complicated than that as it only becomes a problem if you're also using Spring Security.
This is an interesting suggestion, but I think any change would be more broadly applicable if it was made in Spring Security. There's nothing Spring Boot-specific about the behaviour. |
Why this issue is marked as invalid? I'm running into the same issue as the others above: I have configured Spring to work over SSL on 8080 port, but for some weird reason, I'm being redirected to 8443. I tried everything: overriding |
I have created an issue here: spring-projects/spring-security#8140 |
I have the same problem, but I found when I stopped the server and the Ide I use the problem is there still when nothing is running. I don't understand how that happens. |
Hello,
I face a problem in my everyday job app that I have been able to reproduce easily in the official sample "spring-boot-sample-web-secure-custom" ( https://github.com/spring-projects/spring-boot/tree/master/spring-boot-samples/spring-boot-sample-web-secure-custom ).
In application.properties, if I set server.port=8443 (while keeping classic http protocol, no https at all), then when I try to open url http://127.0.0.1:8443/FOOBAR then I am redirected to url http://127.0.0.1:8080/login (see the port has changed !)
Any port other than 8443 seems to be fine.
As 443 is the HTTP_S_ port, there must be something hardcoded with 8443 somewhere.
In my own app, configuring https solves the problem. But I'd like users to be able to switch to http if they want without knowing that they also have to use a port other than 8443.
Thanks for the good job Spring Boot Team !
The text was updated successfully, but these errors were encountered: