{"id":14382,"date":"2020-02-04T18:11:21","date_gmt":"2020-02-04T17:11:21","guid":{"rendered":"https:\/\/www.oderland.se\/support\/artikel\/hur-skapar-jag-ett-sjalvsignerat-ssl-tls-certifikat\/"},"modified":"2025-01-14T13:10:39","modified_gmt":"2025-01-14T12:10:39","slug":"how-do-i-create-a-self-signed-ssl-tls-certificate","status":"publish","type":"ht_kb","link":"https:\/\/www.oderland.se\/support\/en\/artikel\/how-do-i-create-a-self-signed-ssl-tls-certificate\/","title":{"rendered":"How do I create a self-signed SSL\/TLS certificate?"},"content":{"rendered":"\n<p class=\"wp-block-ht-blocks-messages wp-block-hb-message wp-block-hb-message--withicon is-style-danger\">This guide is intended for those who know that they specifically need a self-signed certificate. If you need an ordinary SSL certificate, we recommend that you use a free certificate issued via <a href=\"https:\/\/www.oderland.se\/support\/en\/artikel\/how-does-autossl-work\/\" target=\"_blank\" rel=\"noreferrer noopener\">AutoSSL<\/a>.<\/p>\n\n\n\n<p class=\"wp-block-ht-blocks-messages wp-block-hb-message wp-block-hb-message--withicon is-style-alert\">Self-signed certificates will always trigger a warning from your web browser when you try to access a website using one. Therefore, you need to bypass the warning to reach the website.<\/p>\n\n\n\n<p>A self-signed SSL certificate can be used <em>e.g.<\/em> during a transfer of a website to us (from another provider) where the domain has been <a href=\"https:\/\/www.oderland.se\/support\/en\/artikel\/how-do-i-temporarily-point-a-domain-towards-another-server-locally\/\" data-type=\"ht_kb\" data-id=\"14336\" target=\"_blank\" rel=\"noreferrer noopener\">pointed locally<\/a> towards our server. You may <em>e.g.<\/em> do this to ensure that the website is working properly before pointing the domain globally (especially if the website uses an automatic redirect from http to https). These certificates are only meant to be used temporarily.<\/p>\n\n\n\n<p class=\"wp-block-ht-blocks-messages wp-block-hb-message wp-block-hb-message--withicon is-style-alert\"><strong>Self-signed certificates shouldn&#8217;t be used on live websites.<\/strong> This since the visitors will get a warning in their browsers regarding non-trusted certificate issuer.<\/p>\n\n\n\n<p>To create a self-signed SSL certificate, follow these steps:<\/p>\n\n\n\n<ol class=\"wp-block-list\">\n<li>Begin by <a rel=\"noreferrer noopener\" href=\"https:\/\/www.oderland.se\/support\/en\/artikel\/how-do-i-login-to-cpanel\/\" data-type=\"ht_kb\" data-id=\"4236\" target=\"_blank\">logging on to cPanel<\/a>.<\/li>\n\n\n\n<li>Click the icon <code>SSL\/TLS<\/code> under <code>Security<\/code>.<br><a href=\"https:\/\/www.oderland.se\/support\/wp-content\/uploads\/2020\/02\/cpanel_icon_ssl-tls-1.png\"><img loading=\"lazy\" decoding=\"async\" width=\"726\" height=\"313\" class=\"wp-image-18715\" style=\"width: 726px;\" src=\"https:\/\/www.oderland.se\/support\/wp-content\/uploads\/2020\/02\/cpanel_icon_ssl-tls-1.png\" alt=\"\" srcset=\"https:\/\/www.oderland.se\/support\/wp-content\/uploads\/2020\/02\/cpanel_icon_ssl-tls-1.png 726w, https:\/\/www.oderland.se\/support\/wp-content\/uploads\/2020\/02\/cpanel_icon_ssl-tls-1-300x129.png 300w, https:\/\/www.oderland.se\/support\/wp-content\/uploads\/2020\/02\/cpanel_icon_ssl-tls-1-50x22.png 50w, https:\/\/www.oderland.se\/support\/wp-content\/uploads\/2020\/02\/cpanel_icon_ssl-tls-1-60x26.png 60w, https:\/\/www.oderland.se\/support\/wp-content\/uploads\/2020\/02\/cpanel_icon_ssl-tls-1-100x43.png 100w\" sizes=\"auto, (max-width: 726px) 100vw, 726px\" \/><\/a><br><\/li>\n\n\n\n<li>First, you need to create a private key for the certificate. Therefore, click the link under <code>Private keys<\/code>.<br><a href=\"https:\/\/www.oderland.se\/support\/wp-content\/uploads\/2020\/02\/cpanel_ssl-tls_private_keys.png\"><img loading=\"lazy\" decoding=\"async\" width=\"1132\" height=\"633\" class=\"wp-image-18718\" style=\"width: 1132px;\" src=\"https:\/\/www.oderland.se\/support\/wp-content\/uploads\/2020\/02\/cpanel_ssl-tls_private_keys.png\" alt=\"\" srcset=\"https:\/\/www.oderland.se\/support\/wp-content\/uploads\/2020\/02\/cpanel_ssl-tls_private_keys.png 1132w, https:\/\/www.oderland.se\/support\/wp-content\/uploads\/2020\/02\/cpanel_ssl-tls_private_keys-300x168.png 300w, https:\/\/www.oderland.se\/support\/wp-content\/uploads\/2020\/02\/cpanel_ssl-tls_private_keys-1024x573.png 1024w, https:\/\/www.oderland.se\/support\/wp-content\/uploads\/2020\/02\/cpanel_ssl-tls_private_keys-768x429.png 768w, https:\/\/www.oderland.se\/support\/wp-content\/uploads\/2020\/02\/cpanel_ssl-tls_private_keys-50x28.png 50w, https:\/\/www.oderland.se\/support\/wp-content\/uploads\/2020\/02\/cpanel_ssl-tls_private_keys-60x34.png 60w, https:\/\/www.oderland.se\/support\/wp-content\/uploads\/2020\/02\/cpanel_ssl-tls_private_keys-100x56.png 100w\" sizes=\"auto, (max-width: 1132px) 100vw, 1132px\" \/><\/a><br><\/li>\n\n\n\n<li>Here, select the <code>Key Type<\/code> and add a <code>Description<\/code> for the key:<br><a href=\"https:\/\/www.oderland.se\/support\/wp-content\/uploads\/2020\/02\/cpanel_ssl-tls_generate_private_key.png\"><img loading=\"lazy\" decoding=\"async\" width=\"548\" height=\"559\" class=\"wp-image-14391\" style=\"width: 548px;\" src=\"https:\/\/www.oderland.se\/support\/wp-content\/uploads\/2020\/02\/cpanel_ssl-tls_generate_private_key.png\" alt=\"\"><\/a><br><strong>Key Type<\/strong>: Choose <code>RSA, 4096-bit<\/code> here.<br><br><strong>Description<\/strong>: Enter a description for the key, so that you&#8217;ll recognise it in the list of keys if you have more than one. Our plan in this example is to issue a certificate for the domain exempel.se, so we name the key accordingly.<br><br>Create the key by clicking the <code>Generate<\/code> button.<\/li>\n\n\n\n<li>Your key will now be generated and displayed. You don&#8217;t have to do anything with the displayed key, just scroll down and click <code>Return to SSL Manager<\/code>.<br><a href=\"https:\/\/www.oderland.se\/support\/wp-content\/uploads\/2020\/02\/cpanel_ssl-tls_private_keys_return_to_ssl_manager.png\"><img loading=\"lazy\" decoding=\"async\" width=\"441\" height=\"72\" class=\"wp-image-14393\" style=\"width: 441px;\" src=\"https:\/\/www.oderland.se\/support\/wp-content\/uploads\/2020\/02\/cpanel_ssl-tls_private_keys_return_to_ssl_manager.png\" alt=\"\"><\/a><br><\/li>\n\n\n\n<li>Now, click the link below <code>Certificates<\/code>. You will not have to worry about a CSR when you create a self-signed certificate.<br><a href=\"https:\/\/www.oderland.se\/support\/wp-content\/uploads\/2020\/02\/cpanel_ssl-tls_crt-1.png\"><img loading=\"lazy\" decoding=\"async\" width=\"1132\" height=\"633\" class=\"wp-image-18720\" style=\"width: 1132px;\" src=\"https:\/\/www.oderland.se\/support\/wp-content\/uploads\/2020\/02\/cpanel_ssl-tls_crt-1.png\" alt=\"\" srcset=\"https:\/\/www.oderland.se\/support\/wp-content\/uploads\/2020\/02\/cpanel_ssl-tls_crt-1.png 1132w, https:\/\/www.oderland.se\/support\/wp-content\/uploads\/2020\/02\/cpanel_ssl-tls_crt-1-300x168.png 300w, https:\/\/www.oderland.se\/support\/wp-content\/uploads\/2020\/02\/cpanel_ssl-tls_crt-1-1024x573.png 1024w, https:\/\/www.oderland.se\/support\/wp-content\/uploads\/2020\/02\/cpanel_ssl-tls_crt-1-768x429.png 768w, https:\/\/www.oderland.se\/support\/wp-content\/uploads\/2020\/02\/cpanel_ssl-tls_crt-1-50x28.png 50w, https:\/\/www.oderland.se\/support\/wp-content\/uploads\/2020\/02\/cpanel_ssl-tls_crt-1-60x34.png 60w, https:\/\/www.oderland.se\/support\/wp-content\/uploads\/2020\/02\/cpanel_ssl-tls_crt-1-100x56.png 100w\" sizes=\"auto, (max-width: 1132px) 100vw, 1132px\" \/><\/a><br><\/li>\n\n\n\n<li>Scroll down until you find <code>Generate a New Certificate<\/code> and fill out the form:<br><a href=\"https:\/\/www.oderland.se\/support\/wp-content\/uploads\/2020\/02\/cpanel_ssl-tls_create_self-signed_cert-1.png\"><img loading=\"lazy\" decoding=\"async\" width=\"894\" height=\"1321\" class=\"wp-image-14397\" style=\"width: 894px;\" src=\"https:\/\/www.oderland.se\/support\/wp-content\/uploads\/2020\/02\/cpanel_ssl-tls_create_self-signed_cert-1.png\" alt=\"\"><\/a><br><strong>Key<\/strong>: Select the key created under step 4 above.<br><br><strong>Domains<\/strong>: Enter the domain name(s) the certificate shall cover. In this case, we use &#8220;exempel.se&#8221;, but you enter the domain(s) that you&#8217;re using.<br><br><strong>City<\/strong>: Enter the city that should be included in the certificate. You can enter anything you want, as long as you only use A-Z. We enter &#8220;Gothenburg&#8221; in this case.<br><br><strong>State<\/strong>: Since we don&#8217;t have states in Sweden, we enter &#8220;NA&#8221; here (as in &#8220;Not Applicable&#8221;).<br><br><strong>Country<\/strong>: Choose the most fitting one, we select &#8220;SE (Sweden)&#8221;.<br><br><strong>Company<\/strong>: Just as for City above, it doesn&#8217;t matter what you type in here, as long as it only consists of A-Z.<br><br>You do not have to enter anything in the rest of the fields.<br><br>Once you&#8217;re done, click <code>Generate<\/code> to create the certificate.<\/li>\n\n\n\n<li>You will now get a confirmation that the certificate is created. Click the link to the installer to install the certificate on the domain(s), since this is not done automatically.<br><a href=\"https:\/\/www.oderland.se\/support\/wp-content\/uploads\/2020\/02\/cpanel_ssl-tls_selfsigned_created.png\"><img loading=\"lazy\" decoding=\"async\" width=\"884\" height=\"312\" class=\"wp-image-18722\" style=\"width: 884px;\" src=\"https:\/\/www.oderland.se\/support\/wp-content\/uploads\/2020\/02\/cpanel_ssl-tls_selfsigned_created.png\" alt=\"\" srcset=\"https:\/\/www.oderland.se\/support\/wp-content\/uploads\/2020\/02\/cpanel_ssl-tls_selfsigned_created.png 884w, https:\/\/www.oderland.se\/support\/wp-content\/uploads\/2020\/02\/cpanel_ssl-tls_selfsigned_created-300x106.png 300w, https:\/\/www.oderland.se\/support\/wp-content\/uploads\/2020\/02\/cpanel_ssl-tls_selfsigned_created-768x271.png 768w, https:\/\/www.oderland.se\/support\/wp-content\/uploads\/2020\/02\/cpanel_ssl-tls_selfsigned_created-50x18.png 50w, https:\/\/www.oderland.se\/support\/wp-content\/uploads\/2020\/02\/cpanel_ssl-tls_selfsigned_created-60x21.png 60w, https:\/\/www.oderland.se\/support\/wp-content\/uploads\/2020\/02\/cpanel_ssl-tls_selfsigned_created-100x35.png 100w\" sizes=\"auto, (max-width: 884px) 100vw, 884px\" \/><\/a><br><\/li>\n\n\n\n<li>Scroll down until you find <code>Install an SSL Website<\/code>.<br><br>Select the domain you wish to install the certificate on via the dropdown menu next to <code>Domain<\/code> and click the <code>Autofill by Domain<\/code> button.<br><a href=\"https:\/\/www.oderland.se\/support\/wp-content\/uploads\/2020\/02\/cpanel_ssl-tls_install_self-signed.png\"><img loading=\"lazy\" decoding=\"async\" width=\"466\" height=\"1209\" class=\"wp-image-14402\" style=\"width: 466px;\" src=\"https:\/\/www.oderland.se\/support\/wp-content\/uploads\/2020\/02\/cpanel_ssl-tls_install_self-signed.png\" alt=\"\"><\/a><br>The textfields for <code>Certificate (CRT)<\/code> and <code>Private Key (KEY)<\/code> will be autofilled. You will not have to enter anything in the textfield for <code>Certificate Authority Bundle (CABUNDLE)<\/code>, since you do not have one. Finally, click <code>Install Certificate<\/code>.<\/li>\n\n\n\n<li>You will now see a popup box confirming that the certificate has been installed!<br><a href=\"https:\/\/www.oderland.se\/support\/wp-content\/uploads\/2020\/02\/cpanel_ssl-tls_self-signed_installed.png\"><img loading=\"lazy\" decoding=\"async\" width=\"394\" height=\"168\" class=\"wp-image-14404\" style=\"width: 394px;\" src=\"https:\/\/www.oderland.se\/support\/wp-content\/uploads\/2020\/02\/cpanel_ssl-tls_self-signed_installed.png\" alt=\"\"><\/a><\/li>\n<\/ol>\n\n\n\n<p class=\"wp-block-ht-blocks-messages wp-block-hb-message wp-block-hb-message--withicon is-style-info\">If you now try surfing towards the https:\/\/ version of your website, your browser should warn you that the certificate isn&#8217;t trusted &#8211; bypass this warning to reach the site.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>A self-signed SSL certificate can be used e.g. during a transfer of a website to us (from another provider) where the domain has been pointed locally towards our server. You may e.g. do this to ensure that the website is working properly before pointing the domain globally (especially if the&#8230;<\/p>\n","protected":false},"author":12,"comment_status":"open","ping_status":"closed","template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"ht-kb-category":[211],"ht-kb-tag":[],"class_list":["post-14382","ht_kb","type-ht_kb","status-publish","format-standard","hentry","ht_kb_category-ssl-tls-en"],"acf":[],"_links":{"self":[{"href":"https:\/\/www.oderland.se\/support\/en\/wp-json\/wp\/v2\/ht-kb\/14382","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.oderland.se\/support\/en\/wp-json\/wp\/v2\/ht-kb"}],"about":[{"href":"https:\/\/www.oderland.se\/support\/en\/wp-json\/wp\/v2\/types\/ht_kb"}],"author":[{"embeddable":true,"href":"https:\/\/www.oderland.se\/support\/en\/wp-json\/wp\/v2\/users\/12"}],"replies":[{"embeddable":true,"href":"https:\/\/www.oderland.se\/support\/en\/wp-json\/wp\/v2\/comments?post=14382"}],"version-history":[{"count":19,"href":"https:\/\/www.oderland.se\/support\/en\/wp-json\/wp\/v2\/ht-kb\/14382\/revisions"}],"predecessor-version":[{"id":23884,"href":"https:\/\/www.oderland.se\/support\/en\/wp-json\/wp\/v2\/ht-kb\/14382\/revisions\/23884"}],"wp:attachment":[{"href":"https:\/\/www.oderland.se\/support\/en\/wp-json\/wp\/v2\/media?parent=14382"}],"wp:term":[{"taxonomy":"ht_kb_category","embeddable":true,"href":"https:\/\/www.oderland.se\/support\/en\/wp-json\/wp\/v2\/ht-kb-category?post=14382"},{"taxonomy":"ht_kb_tag","embeddable":true,"href":"https:\/\/www.oderland.se\/support\/en\/wp-json\/wp\/v2\/ht-kb-tag?post=14382"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}