The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

If https is pointing to the wrong place, try this!

Discussion in 'General Discussion' started by jasoncollege24, May 1, 2014.

  1. jasoncollege24

    Joined:
    Mar 25, 2012
    Messages:
    15
    Likes Received:
    0
    Trophy Points:
    1
    Location:
    Portsmouth, Virginia, United States
    cPanel Access Level:
    Root Administrator
    I've seen it mentioned in older threads where people said that trying to access their sites using SSL (https) pointed to the wrong place on the web server, or that they received a 404 error (443) when trying to access SSL websites.

    For anyone else who has this issue, it is fairly easy to resolve. In WHM 11.4x the procedure is fairly simple. I'll explain using the example domain http://example.com, and the example subdomain http://sub.example.com. The following procedure assumes that you prefer not to pay for a signed SSL certificate from a trusted certificate authority.

    1. Login to http://example.com/whm with the server's root account
    2. On the home screen, click on SSL/TLS
    3. Click on "Generate an SSL Certificate and Signing request"
    4. Fill in only the fields marked "Required" using *.example.com as the only domain, and click the Create button at the bottom (fill in all fields if you're going to submit the signing request to purchased a signed certificate)
    5. Once this is completed, a self signed SSL/TLS certificate is automatically installed on the server that can be used for http://example.com, and any subdomains of that domain.
    6. Return to the SSL/TLS screen.
    7. Click on "Install an SSL certificate on a domain"
    8. Click the button that says "Browse certificates"
    9. If not already selected, select the certificate for *.example.com and click the "User certificate" button
    10. in the domain field, change *.example.com to sub.example.com then scroll to the bottom, and click the Install button.
    11. Login to WHM, and repeat steps 6-10 for example.com itself, any any other subdomains of example.com where you want to use SSL (https)

    NOTE: Self signed certificates created, and used in this manner will cause browser warnings, because the certificate isn't signed by a trusted certificate authority. If you're dong this for your own server, you and your clients can safely ignore these warnings.
     
  2. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    30,854
    Likes Received:
    676
    Trophy Points:
    113
    cPanel Access Level:
    Root Administrator
    Hello :)

    Is there any reason why you prefer to use a wildcard certificate? You could generate a self-signed certificate for the actual subdomain and it will work as intended. Support for SNI was introduced in cPanel version 11.38, so it's now possible to install multiple certificates on a shared IP address.

    Thank you.
     
  3. jasoncollege24

    Joined:
    Mar 25, 2012
    Messages:
    15
    Likes Received:
    0
    Trophy Points:
    1
    Location:
    Portsmouth, Virginia, United States
    cPanel Access Level:
    Root Administrator
    Using a wildcard saves time by eliminating the need to go through the process of creating a self signed certificate for every subdomain. Such a process would be fairly tedious for servers where a single domain has a lot of subdomains.
     
Loading...

Share This Page