HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials

HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials (http://www.howtoforge.com/forums/index.php)
-   Installation/Configuration (http://www.howtoforge.com/forums/forumdisplay.php?f=27)
-   -   SSL Certificate for a subdomain? (http://www.howtoforge.com/forums/showthread.php?t=61967)

Steve85 25th May 2013 16:41

SSL Certificate for a subdomain?
 
Hello all,

how is it possible to create a SSL certificate for a subdomain?

"mydomain.com" is no problem but if i want to encrypt my mail traffic i need a certificate for "mail.mydomain.com".

Where can i setup this?

Best,
Steve

yucktoufoo 25th May 2013 23:02

I assume you mean a self signed certificate? If so, by running this command, when prompted for Common Name set it to mail.yourdomain.com


Code:

openssl req -x509 -newkey rsa:2048 -keyout key.pem -out cert.pem -days 365
That will sign a cert for 365 days, if you dont want a passphrase on the key (which you probably dont if the cert is for a mailserver), add the -nodes option.

Don't forget to make sure the permissions are correct on your key file.

Steve85 26th May 2013 12:16

Thanks for answer but this wasn`t the problem ;-)

If i create in the ISPConfig a subdomain like "login.mydomain.com" and i want to access login.mydomain.com over https i don`t find a way to create this? Maybe if i buy a wildcard certificate for "*.mydomain.com" but this shouldn`t the solution.

I want to create a certificate for only my subdomain which i create over ISPConfig.

Any idea? Not possible? Feature request?

yucktoufoo 26th May 2013 13:19

Quote:

Originally Posted by Steve85 (Post 297733)
Thanks for answer but this wasn`t the problem ;-)

If i create in the ISPConfig a subdomain like "login.mydomain.com" and i want to access login.mydomain.com over https i don`t find a way to create this? Maybe if i buy a wildcard certificate for "*.mydomain.com" but this shouldn`t the solution.

I want to create a certificate for only my subdomain which i create over ISPConfig.

Any idea? Not possible? Feature request?

I thought you were talking about mail server certificates!?

I am assuming that you have just added a subdomain rather than using a subdomain to create a new "site". In which case I think wildcard certificate is probably your only way, (im guessing this... http://wiki.apache.org/httpd/NameBasedSSLVHosts is not what you need either but here for reference anyway).

Maybe I am missing something with your setup though?

peggyp 27th May 2013 11:55

Hi,

For securing sub-domains, you will need to buy wildcard SSL that offers facility to secure unlimited sub-domain and host domain with single SSL.

pititis 28th May 2013 01:52

No problem if you add the subdomain as separate website:

- In ispconfig create your subdomain like a normal domain. Client->Domain->New (subdomain.domain.com)

- Create website and select your previous created subdomain.domain.com. Select SSL checkbox too.

- Create the new certificate in the SSL tab.

- Don't forget to add a A record in the dns zone for the subdomain

Cheers.

Steve85 28th May 2013 13:04

Quote:

Originally Posted by pititis (Post 297799)
No problem if you add the subdomain as separate website:

- In ispconfig create your subdomain like a normal domain. Client->Domain->New (subdomain.domain.com)

- Create website and select your previous created subdomain.domain.com. Select SSL checkbox too.

- Create the new certificate in the SSL tab.

- Don't forget to add a A record in the dns zone for the subdomain

Cheers.

Think this will work. I`m not sure if this is the right way but a for a workaround it should do.

Thank you!

till 28th May 2013 13:08

Quote:

Originally Posted by Steve85 (Post 297820)
Think this will work. I`m not sure if this is the right way but a for a workaround it should do.

Thank you!

Thats not a workaround, its described in the manual to create awebsite for a subomain if this subdomain shall have its own directory or needs any other features that exist only for vhosts in apache.


All times are GMT +2. The time now is 16:01.

Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.