How To Redirect all HTTP Requests To HTTPS Requests in OHS
(Doc ID 259576.1)
Last updated on AUGUST 16, 2021
Applies to:Oracle HTTP Server - Version 9.0.2 and later
Information in this document applies to any platform.
This document was written for 9i but it also applies to 10g, 11g, and 12c.
Set up Oracle HTTP Server configuration to redirect all non-SSL HTTP traffic to the HTTPS port of the same server.
Having set up a Web Site with SSL, there is often still a way to access it through HTTP. And often it is a good idea to not close down HTTP connectivity but to redirect users to the same URL on HTTPS instead.
In this bulletin we cover how to achieve this with HTTP Server configuration options. We assume that the site has already been switched to HTTPS before, thus all (re)registrations that are involved in getting OracleAS components work as expected after the switch from non-SSL to SSL (SSO, Portal, etc.) have already been done.
We further assume port distribution like this:
- Webcache's HTTP port is 7777, forwarding to HTTP Server's HTTP port 7778.
So the HTTP entry point to the HTTP Server is 7777.
- Webcache's HTTPS port is 4443, forwarding to HTTP Server's HTTPS port 4444.
So the HTTPS entry point to the HTTP Server is 4443.
The configurations shown below have been tested and verified with OracleAS 10g Release 2 (10.1.2.x) and Oracle AS 10g Release 3 (10.1.3.x), but we assume they should generally work with HTTP Server versions 11g/12c and any other HTTP Server version, too.
To view full details, sign in with your My Oracle Support account.
Don't have a My Oracle Support account? Click to get started!
In this Document
|Three Alternative Ways|