cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
833
Views
0
Helpful
2
Replies

Redirect HTTP traffic to HTTPS on CSM

Mohamad Qayoom
Level 3
Level 3

Greetings,

Does anyone know how to redirect HTTP traffic to HTTPS when using CSM and SSL?

Thanks,

Mohamad

1 Accepted Solution

Accepted Solutions

Sean Merrow
Level 4
Level 4

Hi Mohamad,

I've seen this done in slightly different ways.  One way is at the very bottom of the following examples from the Cisco.com CSM-S config guide:

CSM-S Configuration Examples

http://www.cisco.com/en/US/docs/interfaces_modules/services_modules/csms/2.1.1/configuration/guide/cfgxpls.html

Another way is like this:

serverfarm REDIRECT
  nat server
  no nat client
   redirect-vserver REDIRECT
    webhost relocation https://www.example.com/
    inservice
!
serverfarm SSL_DC
  no nat server
  no nat client
  real 192.168.78.36 local
   inservice
!
vserver VSERVER_80
  virtual 192.168.78.35 tcp 80
  serverfarm REDIRECT
  persistent rebalance
  inservice
!
vserver VSERVER_443
  virtual 192.168.78.35 tcp 443
  serverfarm SSL_DC
  persistent rebalance
  inservice

Hope this helps get you started.

Sean

View solution in original post

2 Replies 2

Sean Merrow
Level 4
Level 4

Hi Mohamad,

I've seen this done in slightly different ways.  One way is at the very bottom of the following examples from the Cisco.com CSM-S config guide:

CSM-S Configuration Examples

http://www.cisco.com/en/US/docs/interfaces_modules/services_modules/csms/2.1.1/configuration/guide/cfgxpls.html

Another way is like this:

serverfarm REDIRECT
  nat server
  no nat client
   redirect-vserver REDIRECT
    webhost relocation https://www.example.com/
    inservice
!
serverfarm SSL_DC
  no nat server
  no nat client
  real 192.168.78.36 local
   inservice
!
vserver VSERVER_80
  virtual 192.168.78.35 tcp 80
  serverfarm REDIRECT
  persistent rebalance
  inservice
!
vserver VSERVER_443
  virtual 192.168.78.35 tcp 443
  serverfarm SSL_DC
  persistent rebalance
  inservice

Hope this helps get you started.

Sean

Thank you Sean,

I was able to make the redirects works by doing something similar to what you mentioned.

Thanks,

Mohamad