tobiasbaum commented on PR #709: URL: https://github.com/apache/tomcat/pull/709#issuecomment-4269213763
I would like to see this feature added to Tomcat. Does anyone know the reason why it has not been merged, yet? Some background on my use case: When I have a secure (https) connector listening on some port (say 8080) and I accidentally call it without TLS (e.g., http://localhost:8080/ instead of https://localhost:8080/), I get an error response as follows: Bad Request This combination of host and port requires TLS. For non-technical users, this error response is not ideal. Therefore, I would like to be able to configure this response. Ideally in my case, the response would be a redirect that changes the protocol from http to https and leaves the remaining url the same. But serving a custom static HTML response would be sufficient, too (as I could then, e.g., implement the redirect in JavaScript or provide a user-friendly explanation). Also, in my case, configuration via code would be sufficient as I run Tomcat embedded as a library. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
