Please whitelist cPanel in your adblocker so that you’re able to see our version release promotions, thanks!

The Community Forums

Interact with an entire community of cPanel & WHM users!

Can you use AutoSSL on a Subdomain that's pointing to another server/IP

Discussion in 'Security' started by Sounds, Feb 14, 2018.

Tags:
  1. Sounds

    Sounds Registered

    Joined:
    Feb 14, 2018
    Messages:
    3
    Likes Received:
    1
    Trophy Points:
    3
    Location:
    Ireland
    cPanel Access Level:
    Root Administrator
    Hi folks,

    I need a few pointers on securing a Subdomain with SSL, that's pointing to another server.
    This is the first time I tried this across two servers, main dedicated server and linux VPS.

    On the main server I have WHM/cPanel, and domain1.com
    That domain has its own cPanel account and AutoSSL is working on it.

    www, domain1.com, and http URLs are redirecting to https, so I guess it's working.

    What I want to do now is assign AutoSSL to a Subdomain, but I am pointing this
    Subdomain to a different server/IP, which is on a VPS with Linux, Ubuntu 16.04 and LAMP.

    I already set up a virtual host for the Subdomain on the second server with Apache2.
    So the public_html directory exists on the second server/vps for clients.domain1.com

    Next

    I went into the cPanel account for domain1.com and clicked Subdomains,
    I created a new Subdomain there "clients"

    This new subdomain doesn't have a cPanel account.

    I went into DNS Functions > Edit DNS Zones, and selected domain1.com
    I can see there are 4 new records in there for "clients"

    clients | 1140 | IN | 354.474.484.485
    www.clients| 1140 | IN | 354.474.484.485
    default._domainkey.clients| 1140 | TXT | Some long key
    clients| 1140 | TXT | "v=spf1 +a +mx +ip4:354.474.484.485 ~all"

    I changed the IP's for the first two, clients and www.clients to the IP of my second server.
    So now I can access clients.domain1.com's public_html directory on the second server.

    Should I change "v=spf1 +a +mx +ip4:354.474.484.485 ~all" to the second server IP??

    Actually that's as far as I've got so far, maybe someone could correct me if I'm wrong,
    Back on server 1 I had a look at Manage SSL Hosts and could see two records for:

    clients.domain1.com
    www.clients.domain1.com

    They both have green locks on them.

    I'm still seeing the security warning of I visit https://www.clients.domain1.com
     
  2. 24x7server

    24x7server Well-Known Member

    Joined:
    Apr 17, 2013
    Messages:
    1,864
    Likes Received:
    89
    Trophy Points:
    78
    Location:
    India
    cPanel Access Level:
    Root Administrator
    Hi,

    AutoSSL will only issue certificate for the domains and subdomains hosted on the server where AutoSSL is issued and for this very same reason, AutoSSL validate the domain existence on the server and then only issues and install the certificate..
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  3. Sounds

    Sounds Registered

    Joined:
    Feb 14, 2018
    Messages:
    3
    Likes Received:
    1
    Trophy Points:
    3
    Location:
    Ireland
    cPanel Access Level:
    Root Administrator
    Can I assign an SSL cert on the other server where the Subdomain is pointed to?
    Linux server, Ubuntu 16.04, LAMP setup.
     
  4. cPanelMichael

    cPanelMichael Technical Support Community Manager
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    44,749
    Likes Received:
    1,885
    Trophy Points:
    363
    cPanel Access Level:
    Root Administrator
    Twitter:
    Hello,

    AutoSSL certificates are only supported for domain names or subdomains that resolve to the cPanel server the certificate is generated on. If the domain resolves to a remote server, then it's not possible to generate a certificate for it using the AutoSSL feature.

    You could technically install a self-signed or commercial SSL certificate for that subdomain on the remote server, but keep in mind you won't be able to use a certificate generated via the AutoSSL feature. Additionally, it's unsupported so we wouldn't be able to troubleshoot any issues that arise from the installation attempt.

    Thank you.
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  5. Sounds

    Sounds Registered

    Joined:
    Feb 14, 2018
    Messages:
    3
    Likes Received:
    1
    Trophy Points:
    3
    Location:
    Ireland
    cPanel Access Level:
    Root Administrator
    I have openssl on the vps, maybe I'll try that in the terminal, have no control panel on the vps.

    Thanks for the info.
     
    cPanelMichael likes this.
Loading...

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice