{"id":2195,"date":"2020-11-17T05:50:27","date_gmt":"2020-11-17T05:50:27","guid":{"rendered":"https:\/\/ubiq.co\/tech-blog\/?p=2195"},"modified":"2025-08-26T04:39:50","modified_gmt":"2025-08-26T04:39:50","slug":"how-to-create-a-self-signed-ssl-certificate-for-apache-in-ubuntu-debian","status":"publish","type":"post","link":"https:\/\/ubiq.co\/tech-blog\/how-to-create-a-self-signed-ssl-certificate-for-apache-in-ubuntu-debian\/","title":{"rendered":"How To Create a Self-Signed SSL Certificate for Apache in Ubuntu\/Debian"},"content":{"rendered":"\n<p>SSL certificates allow you to securely transfer data to\/from server, without the possibility of anyone else intercepting it. They also help in site verification. In this article, we will look at how to create self-signed SSL certificate for Apache. However, it is important to note that self-signed certificates can be used only if you don&#8217;t have public facing domain names and web pages. For publicly accessible websites, you need to install third-party SSL certificates.<\/p>\n\n\n\n<div id=\"ez-toc-container\" class=\"ez-toc-v2_0_82_2 counter-hierarchy ez-toc-counter ez-toc-grey ez-toc-container-direction\">\n<div class=\"ez-toc-title-container\">\n<p class=\"ez-toc-title\" style=\"cursor:inherit\">Table of Contents<\/p>\n<span class=\"ez-toc-title-toggle\"><a href=\"#\" class=\"ez-toc-pull-right ez-toc-btn ez-toc-btn-xs ez-toc-btn-default ez-toc-toggle\" aria-label=\"Toggle Table of Content\"><span class=\"ez-toc-js-icon-con\"><span class=\"\"><span class=\"eztoc-hide\" style=\"display:none;\">Toggle<\/span><span class=\"ez-toc-icon-toggle-span\"><svg style=\"fill: #999;color:#999\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" class=\"list-377408\" width=\"20px\" height=\"20px\" viewBox=\"0 0 24 24\" fill=\"none\"><path d=\"M6 6H4v2h2V6zm14 0H8v2h12V6zM4 11h2v2H4v-2zm16 0H8v2h12v-2zM4 16h2v2H4v-2zm16 0H8v2h12v-2z\" fill=\"currentColor\"><\/path><\/svg><svg style=\"fill: #999;color:#999\" class=\"arrow-unsorted-368013\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"10px\" height=\"10px\" viewBox=\"0 0 24 24\" version=\"1.2\" baseProfile=\"tiny\"><path d=\"M18.2 9.3l-6.2-6.3-6.2 6.3c-.2.2-.3.4-.3.7s.1.5.3.7c.2.2.4.3.7.3h11c.3 0 .5-.1.7-.3.2-.2.3-.5.3-.7s-.1-.5-.3-.7zM5.8 14.7l6.2 6.3 6.2-6.3c.2-.2.3-.5.3-.7s-.1-.5-.3-.7c-.2-.2-.4-.3-.7-.3h-11c-.3 0-.5.1-.7.3-.2.2-.3.5-.3.7s.1.5.3.7z\"\/><\/svg><\/span><\/span><\/span><\/a><\/span><\/div>\n<nav><ul class='ez-toc-list ez-toc-list-level-1 ' ><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-1\" href=\"https:\/\/ubiq.co\/tech-blog\/how-to-create-a-self-signed-ssl-certificate-for-apache-in-ubuntu-debian\/#What_is_Self-Signed_Certificate\" >What is Self-Signed Certificate<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-2\" href=\"https:\/\/ubiq.co\/tech-blog\/how-to-create-a-self-signed-ssl-certificate-for-apache-in-ubuntu-debian\/#Why_Need_Self-Signed_Certificate\" >Why Need Self-Signed Certificate<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-3\" href=\"https:\/\/ubiq.co\/tech-blog\/how-to-create-a-self-signed-ssl-certificate-for-apache-in-ubuntu-debian\/#How_To_Create_a_Self-Signed_SSL_Certificate_for_Apache\" >How To Create a Self-Signed SSL Certificate for Apache<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-4\" href=\"https:\/\/ubiq.co\/tech-blog\/how-to-create-a-self-signed-ssl-certificate-for-apache-in-ubuntu-debian\/#1_Create_Self-Signed_Certificate\" >1. Create Self-Signed Certificate<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-5\" href=\"https:\/\/ubiq.co\/tech-blog\/how-to-create-a-self-signed-ssl-certificate-for-apache-in-ubuntu-debian\/#2_Configure_Apache_to_Use_SSL_Certificate\" >2. Configure Apache to Use SSL Certificate<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-6\" href=\"https:\/\/ubiq.co\/tech-blog\/how-to-create-a-self-signed-ssl-certificate-for-apache-in-ubuntu-debian\/#3_Enable_mod_ssl\" >3. Enable mod_ssl<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-7\" href=\"https:\/\/ubiq.co\/tech-blog\/how-to-create-a-self-signed-ssl-certificate-for-apache-in-ubuntu-debian\/#4_Activate_SSL_configuration\" >4. Activate SSL configuration<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-8\" href=\"https:\/\/ubiq.co\/tech-blog\/how-to-create-a-self-signed-ssl-certificate-for-apache-in-ubuntu-debian\/#5_Restart_Apache_Server\" >5. Restart Apache Server<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-9\" href=\"https:\/\/ubiq.co\/tech-blog\/how-to-create-a-self-signed-ssl-certificate-for-apache-in-ubuntu-debian\/#Conclusion\" >Conclusion<\/a><\/li><\/ul><\/nav><\/div>\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"What_is_Self-Signed_Certificate\"><\/span>What is Self-Signed Certificate<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p>There are two types of SSL certificates &#8211; self-signed and those signed by reputed third-parties such as RapidSSL, Comodo, etc. Generally, SSL Certificates are signed by a third-party Certificate Authority (CA). But a self-signed certificate is signed by its own creator and not a public authority. As a result, they are not recognized, by default, by web browsers. When you use self-signed certificates, web browsers will immediately show a warning message saying the &#8216;page is not secure&#8217;. But there is a workaround for this. You will need to force the web browser to trust your self-signed certificate by adding it to the list of trusted Certificate Authority. Nevertheless, self-signed certificates have their benefits and should not be completely ignored.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"Why_Need_Self-Signed_Certificate\"><\/span>Why Need Self-Signed Certificate<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p>There are several reasons why we need self-signed certificates. SSL certificates issued by public CA&#8217;s are not free and require annual payments. On the other hand, self-signed certificates are free. They encrypt data using the same algorithms as those issued by public CA&#8217;s. So they are very useful in development environments and intranet systems, which are not publicly accessible but need network data to be encrypted.<\/p>\n\n\n\n<p>Secondly, public SSL certificates expire after one or more years. You need to keep paying increasing amount of money to renew it and re-install new certificates. On the other hand, self-signed SSL certificates do not expire so you can create them once and use them forever.<\/p>\n\n\n\n<p>Thirdly, SSL certificates issues by public CA&#8217;s can be revoked anytime, at their discretion. But self-signed certificates can never be revoked by anyone, so you are at your own mercy.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"How_To_Create_a_Self-Signed_SSL_Certificate_for_Apache\"><\/span>How To Create a Self-Signed SSL Certificate for Apache<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p>Here are the steps to create self-signed SSL certificate for Apache. When you install a third-party SSL certificate, we need to create a certificate signing request (CSR), submit it to certificate authority to obtain the SSL certificates from them. In case of self-signed certificate, there is no such requirement, since you are the certificate authority. You can directly create the certificates with a single command.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"1_Create_Self-Signed_Certificate\"><\/span>1. Create Self-Signed Certificate<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p>We will use <a href=\"https:\/\/www.openssl.org\/\" target=\"_blank\" rel=\"noreferrer noopener\">OpenSSL<\/a> to create self-signed certificate. It is available for Windows, Linux and Mac systems and is free to use. Open terminal and run the following command<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">$ sudo openssl req -x509 -nodes -days 365 -newkey rsa:2048 -keyout \/etc\/ssl\/private\/selfsigned.key -out \/etc\/ssl\/certs\/selfsigned.crt<\/pre>\n\n\n\n<p>Let us look at the above command in detail, <\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>openssl &#8211; command line tool to create self-signed certificate<\/li>\n\n\n\n<li>req &#8211; specifies to use X.509 standard for certificate creation, making it more secure.<\/li>\n\n\n\n<li>-x509 &#8211; for generation of self-signed certificate as opposed to certificate signing request<\/li>\n\n\n\n<li>-nodes &#8211; tells openSSL to secure our certificate without a passphrase<\/li>\n\n\n\n<li>-days 365 &#8211; specifies validity of SSL certificate, that is, 365 days<\/li>\n\n\n\n<li>-newkey rsa:2048 &#8211; tells openSSL to create certificate as well as the key together. rsa:2048 indicates that RSA key should be 2048 bits long<\/li>\n\n\n\n<li>-keyout &#8211; location to place generated private key file<\/li>\n\n\n\n<li>-out &#8211; location to place generated certificate <\/li>\n<\/ul>\n\n\n\n<p>You will see the following set of prompts where you need to enter various details about your website like its country name, state, etc.<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">Country Name (2 letter code) [AU]:US<br>State or Province Name (full name) [Some-State]:California<br>Locality Name (eg, city) []:San Francisco<br>Organization Name (eg, company) [Internet Widgits Pty Ltd]:Example.com<br>Organizational Unit Name (eg, section) []:  IT Department<br>Common Name (e.g. server FQDN or YOUR name) []:<strong>server_IP_address<\/strong><br>Email Address []:admin@example.com<br><\/pre>\n\n\n\n<p>The most important line in above prompts is for Common Name (e.g server FQDN or YOUR name). Here you need to correctly specify your website&#8217;s domain or public IP address.<\/p>\n\n\n\n<p>In our case, both the certificate and private key file will be generated at \/etc\/ssl.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"2_Configure_Apache_to_Use_SSL_Certificate\"><\/span>2. Configure Apache to Use SSL Certificate<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p>We will edit the default SSL configuration file that ships with Apache, to enable our SSL certificate. Run the following command<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">$ sudo vi \/etc\/apache2\/sites-available\/default-ssl.conf<\/pre>\n\n\n\n<p>You will see a virtual host tag in the file that looks something like, <\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">&lt;IfModule mod_ssl.c&gt;\n        &lt;VirtualHost _default_:443&gt;\n                ServerAdmin webmaster@localhost\n\n                DocumentRoot \/var\/www\/html\n\n                ErrorLog ${APACHE_LOG_DIR}\/error.log\n                CustomLog ${APACHE_LOG_DIR}\/access.log combined\n\n                SSLEngine on\n\n                SSLCertificateFile      \/etc\/ssl\/certs\/ssl-cert-snakeoil.pem\n                SSLCertificateKeyFile \/etc\/ssl\/private\/ssl-cert-snakeoil.key\n\n                &lt;FilesMatch \"\\.(cgi|shtml|phtml|php)$\"&gt;\n                                SSLOptions +StdEnvVars\n                &lt;\/FilesMatch&gt;\n                &lt;Directory \/usr\/lib\/cgi-bin&gt;\n                                SSLOptions +StdEnvVars\n                &lt;\/Directory&gt;\n\n        &lt;\/VirtualHost&gt;\n&lt;\/IfModule&gt;<\/pre>\n\n\n\n<p>We will modify couple of lines in it to update the ServerAdmin, SSLCertificateFile and SSLCertificateKeyFile attributes. They are highlighted in <strong>bold<\/strong>.<\/p>\n\n\n\n<pre id=\"block-c92aa076-eecf-4cb9-979f-a1f42b368bde\" class=\"wp-block-preformatted\">&lt;IfModule mod_ssl.c&gt;\n        &lt;VirtualHost _default_:443&gt;\n                ServerAdmin <strong>admin@example.com<\/strong>\n\n                DocumentRoot \/var\/www\/html\n\n                ErrorLog ${APACHE_LOG_DIR}\/error.log\n                CustomLog ${APACHE_LOG_DIR}\/access.log combined\n\n                SSLEngine on\n\n                SSLCertificateFile      \/etc\/ssl\/certs\/<strong>selfsigned.crt<\/strong>\n                SSLCertificateKeyFile \/etc\/ssl\/private\/<strong>selfsigned.key<\/strong>\n\n                &lt;FilesMatch \"\\.(cgi|shtml|phtml|php)$\"&gt;\n                                SSLOptions +StdEnvVars\n                &lt;\/FilesMatch&gt;\n                &lt;Directory \/usr\/lib\/cgi-bin&gt;\n                                SSLOptions +StdEnvVars\n                &lt;\/Directory&gt;\n\n        &lt;\/VirtualHost&gt;\n&lt;\/IfModule&gt;<\/pre>\n\n\n\n<p>Save and quit the file.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"3_Enable_mod_ssl\"><\/span>3. Enable mod_ssl<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p>We need mod_ssl Apache module to use SSL certificates on our Apache server. Run the following command to activate <em>mod_ssl<\/em>.<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">$ sudo a2enmod ssl<\/pre>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"4_Activate_SSL_configuration\"><\/span>4. Activate SSL configuration<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p>Run the following command to activate SSL configuration<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">$ sudo a2ensite default-ssl<\/pre>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"5_Restart_Apache_Server\"><\/span>5. Restart Apache Server<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p>Run the following command to test Apache configuration. <\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">$ sudo apache2 -t<\/pre>\n\n\n\n<p>If you see no error, run the following command to restart Apache web server and apply changes.<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">$ sudo service apache2 restart<\/pre>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"Conclusion\"><\/span>Conclusion<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p>Hopefully, this article will help you create self-signed SSL certificate for Apache. We have learnt what is a self-signed certificate, how it is different from those SSL certificates signed by public CAs. We have also learnt how to generate self-signed certificate and install it in Apache server. <\/p>\n\n\n\n<p><a href=\"https:\/\/ubiq.co\/\">Ubiq<\/a>&nbsp;makes it easy to visualize data, and monitor them in real-time dashboards.&nbsp;<a href=\"https:\/\/ubiq.co\/accounts\/register\">Try Ubiq<\/a>&nbsp;for free.<\/p>\n\n\n\n<p>Also read : <br><a href=\"https:\/\/ubiq.co\/tech-blog\/how-to-use-apache-bench-for-load-testing\/\">How to Use Apache Bench for Testing<\/a><br><a href=\"https:\/\/ubiq.co\/tech-blog\/how-to-install-memcached-in-apache\/\">How to Install memcached in Apache<\/a><br><a href=\"https:\/\/ubiq.co\/tech-blog\/how-to-install-fail2ban-to-protect-apache-server\/\">How to Install Fail2ban in Apache<\/a><br><a href=\"https:\/\/ubiq.co\/tech-blog\/how-to-remove-index-php-from-url\/\">How to Remove .php from URL in Apache<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Self-Signed Certificate allows you to securely send &#038; receive data between client and server. Here is how to create self-signed SSL certificate for Apache.<\/p>\n","protected":false},"author":1,"featured_media":2203,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_jetpack_memberships_contains_paid_content":false,"footnotes":""},"categories":[3],"tags":[227,62],"class_list":["post-2195","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-apache","tag-self-signed-certificate","tag-ssl-certificate"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.3 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>How To Create a Self-Signed SSL Certificate for Apache in Ubuntu\/Debian - Ubiq BI<\/title>\n<meta name=\"description\" content=\"Self-Signed Certificate allows you to securely send &amp; receive data between client and server. Here is how to create self-signed SSL certificate for Apache.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/ubiq.co\/tech-blog\/how-to-create-a-self-signed-ssl-certificate-for-apache-in-ubuntu-debian\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"How To Create a Self-Signed SSL Certificate for Apache in Ubuntu\/Debian - Ubiq BI\" \/>\n<meta property=\"og:description\" content=\"Self-Signed Certificate allows you to securely send &amp; receive data between client and server. Here is how to create self-signed SSL certificate for Apache.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/ubiq.co\/tech-blog\/how-to-create-a-self-signed-ssl-certificate-for-apache-in-ubuntu-debian\/\" \/>\n<meta property=\"og:site_name\" content=\"Ubiq BI\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/ubiqbi\" \/>\n<meta property=\"article:published_time\" content=\"2020-11-17T05:50:27+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2025-08-26T04:39:50+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/ubiq.co\/tech-blog\/wp-content\/uploads\/2020\/11\/self-signed-ssl-certificate.png\" \/>\n\t<meta property=\"og:image:width\" content=\"935\" \/>\n\t<meta property=\"og:image:height\" content=\"526\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/png\" \/>\n<meta name=\"author\" content=\"Sreeram Sreenivasan\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@UbiqBI\" \/>\n<meta name=\"twitter:site\" content=\"@UbiqBI\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Sreeram Sreenivasan\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"4 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/ubiq.co\\\/tech-blog\\\/how-to-create-a-self-signed-ssl-certificate-for-apache-in-ubuntu-debian\\\/#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/ubiq.co\\\/tech-blog\\\/how-to-create-a-self-signed-ssl-certificate-for-apache-in-ubuntu-debian\\\/\"},\"author\":{\"name\":\"Sreeram Sreenivasan\",\"@id\":\"https:\\\/\\\/ubiq.co\\\/tech-blog\\\/#\\\/schema\\\/person\\\/db98d49a766a3a111d8510935ab90abc\"},\"headline\":\"How To Create a Self-Signed SSL Certificate for Apache in Ubuntu\\\/Debian\",\"datePublished\":\"2020-11-17T05:50:27+00:00\",\"dateModified\":\"2025-08-26T04:39:50+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/ubiq.co\\\/tech-blog\\\/how-to-create-a-self-signed-ssl-certificate-for-apache-in-ubuntu-debian\\\/\"},\"wordCount\":867,\"image\":{\"@id\":\"https:\\\/\\\/ubiq.co\\\/tech-blog\\\/how-to-create-a-self-signed-ssl-certificate-for-apache-in-ubuntu-debian\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/i0.wp.com\\\/ubiq.co\\\/tech-blog\\\/wp-content\\\/uploads\\\/2020\\\/11\\\/self-signed-ssl-certificate.png?fit=935%2C526&ssl=1\",\"keywords\":[\"self-signed certificate\",\"ssl certificate\"],\"articleSection\":[\"Apache\"],\"inLanguage\":\"en-US\"},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/ubiq.co\\\/tech-blog\\\/how-to-create-a-self-signed-ssl-certificate-for-apache-in-ubuntu-debian\\\/\",\"url\":\"https:\\\/\\\/ubiq.co\\\/tech-blog\\\/how-to-create-a-self-signed-ssl-certificate-for-apache-in-ubuntu-debian\\\/\",\"name\":\"How To Create a Self-Signed SSL Certificate for Apache in Ubuntu\\\/Debian - Ubiq BI\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/ubiq.co\\\/tech-blog\\\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\\\/\\\/ubiq.co\\\/tech-blog\\\/how-to-create-a-self-signed-ssl-certificate-for-apache-in-ubuntu-debian\\\/#primaryimage\"},\"image\":{\"@id\":\"https:\\\/\\\/ubiq.co\\\/tech-blog\\\/how-to-create-a-self-signed-ssl-certificate-for-apache-in-ubuntu-debian\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/i0.wp.com\\\/ubiq.co\\\/tech-blog\\\/wp-content\\\/uploads\\\/2020\\\/11\\\/self-signed-ssl-certificate.png?fit=935%2C526&ssl=1\",\"datePublished\":\"2020-11-17T05:50:27+00:00\",\"dateModified\":\"2025-08-26T04:39:50+00:00\",\"author\":{\"@id\":\"https:\\\/\\\/ubiq.co\\\/tech-blog\\\/#\\\/schema\\\/person\\\/db98d49a766a3a111d8510935ab90abc\"},\"description\":\"Self-Signed Certificate allows you to securely send & receive data between client and server. Here is how to create self-signed SSL certificate for Apache.\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/ubiq.co\\\/tech-blog\\\/how-to-create-a-self-signed-ssl-certificate-for-apache-in-ubuntu-debian\\\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/ubiq.co\\\/tech-blog\\\/how-to-create-a-self-signed-ssl-certificate-for-apache-in-ubuntu-debian\\\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/ubiq.co\\\/tech-blog\\\/how-to-create-a-self-signed-ssl-certificate-for-apache-in-ubuntu-debian\\\/#primaryimage\",\"url\":\"https:\\\/\\\/i0.wp.com\\\/ubiq.co\\\/tech-blog\\\/wp-content\\\/uploads\\\/2020\\\/11\\\/self-signed-ssl-certificate.png?fit=935%2C526&ssl=1\",\"contentUrl\":\"https:\\\/\\\/i0.wp.com\\\/ubiq.co\\\/tech-blog\\\/wp-content\\\/uploads\\\/2020\\\/11\\\/self-signed-ssl-certificate.png?fit=935%2C526&ssl=1\",\"width\":935,\"height\":526,\"caption\":\"create self-signed certificate in apache\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/ubiq.co\\\/tech-blog\\\/how-to-create-a-self-signed-ssl-certificate-for-apache-in-ubuntu-debian\\\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/ubiq.co\\\/tech-blog\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"How To Create a Self-Signed SSL Certificate for Apache in Ubuntu\\\/Debian\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/ubiq.co\\\/tech-blog\\\/#website\",\"url\":\"https:\\\/\\\/ubiq.co\\\/tech-blog\\\/\",\"name\":\"Ubiq BI\",\"description\":\"Build dashboards &amp; reports in minutes\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/ubiq.co\\\/tech-blog\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Person\",\"@id\":\"https:\\\/\\\/ubiq.co\\\/tech-blog\\\/#\\\/schema\\\/person\\\/db98d49a766a3a111d8510935ab90abc\",\"name\":\"Sreeram Sreenivasan\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/4b3127ed2d4bb8efb3fa0bbb52cf2efd4d0156c97fc05a503537c883e8279947?s=96&d=mm&r=g\",\"url\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/4b3127ed2d4bb8efb3fa0bbb52cf2efd4d0156c97fc05a503537c883e8279947?s=96&d=mm&r=g\",\"contentUrl\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/4b3127ed2d4bb8efb3fa0bbb52cf2efd4d0156c97fc05a503537c883e8279947?s=96&d=mm&r=g\",\"caption\":\"Sreeram Sreenivasan\"},\"description\":\"Sreeram Sreenivasan is the Founder of Ubiq. He has helped many Fortune 500 companies in the areas of BI &amp; software development.\",\"sameAs\":[\"https:\\\/\\\/www.linkedin.com\\\/in\\\/sreeram-sreenivasan\\\/\"],\"url\":\"https:\\\/\\\/ubiq.co\\\/tech-blog\\\/author\\\/wordpress\\\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"How To Create a Self-Signed SSL Certificate for Apache in Ubuntu\/Debian - Ubiq BI","description":"Self-Signed Certificate allows you to securely send & receive data between client and server. Here is how to create self-signed SSL certificate for Apache.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/ubiq.co\/tech-blog\/how-to-create-a-self-signed-ssl-certificate-for-apache-in-ubuntu-debian\/","og_locale":"en_US","og_type":"article","og_title":"How To Create a Self-Signed SSL Certificate for Apache in Ubuntu\/Debian - Ubiq BI","og_description":"Self-Signed Certificate allows you to securely send & receive data between client and server. Here is how to create self-signed SSL certificate for Apache.","og_url":"https:\/\/ubiq.co\/tech-blog\/how-to-create-a-self-signed-ssl-certificate-for-apache-in-ubuntu-debian\/","og_site_name":"Ubiq BI","article_publisher":"https:\/\/www.facebook.com\/ubiqbi","article_published_time":"2020-11-17T05:50:27+00:00","article_modified_time":"2025-08-26T04:39:50+00:00","og_image":[{"width":935,"height":526,"url":"https:\/\/ubiq.co\/tech-blog\/wp-content\/uploads\/2020\/11\/self-signed-ssl-certificate.png","type":"image\/png"}],"author":"Sreeram Sreenivasan","twitter_card":"summary_large_image","twitter_creator":"@UbiqBI","twitter_site":"@UbiqBI","twitter_misc":{"Written by":"Sreeram Sreenivasan","Est. reading time":"4 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/ubiq.co\/tech-blog\/how-to-create-a-self-signed-ssl-certificate-for-apache-in-ubuntu-debian\/#article","isPartOf":{"@id":"https:\/\/ubiq.co\/tech-blog\/how-to-create-a-self-signed-ssl-certificate-for-apache-in-ubuntu-debian\/"},"author":{"name":"Sreeram Sreenivasan","@id":"https:\/\/ubiq.co\/tech-blog\/#\/schema\/person\/db98d49a766a3a111d8510935ab90abc"},"headline":"How To Create a Self-Signed SSL Certificate for Apache in Ubuntu\/Debian","datePublished":"2020-11-17T05:50:27+00:00","dateModified":"2025-08-26T04:39:50+00:00","mainEntityOfPage":{"@id":"https:\/\/ubiq.co\/tech-blog\/how-to-create-a-self-signed-ssl-certificate-for-apache-in-ubuntu-debian\/"},"wordCount":867,"image":{"@id":"https:\/\/ubiq.co\/tech-blog\/how-to-create-a-self-signed-ssl-certificate-for-apache-in-ubuntu-debian\/#primaryimage"},"thumbnailUrl":"https:\/\/i0.wp.com\/ubiq.co\/tech-blog\/wp-content\/uploads\/2020\/11\/self-signed-ssl-certificate.png?fit=935%2C526&ssl=1","keywords":["self-signed certificate","ssl certificate"],"articleSection":["Apache"],"inLanguage":"en-US"},{"@type":"WebPage","@id":"https:\/\/ubiq.co\/tech-blog\/how-to-create-a-self-signed-ssl-certificate-for-apache-in-ubuntu-debian\/","url":"https:\/\/ubiq.co\/tech-blog\/how-to-create-a-self-signed-ssl-certificate-for-apache-in-ubuntu-debian\/","name":"How To Create a Self-Signed SSL Certificate for Apache in Ubuntu\/Debian - Ubiq BI","isPartOf":{"@id":"https:\/\/ubiq.co\/tech-blog\/#website"},"primaryImageOfPage":{"@id":"https:\/\/ubiq.co\/tech-blog\/how-to-create-a-self-signed-ssl-certificate-for-apache-in-ubuntu-debian\/#primaryimage"},"image":{"@id":"https:\/\/ubiq.co\/tech-blog\/how-to-create-a-self-signed-ssl-certificate-for-apache-in-ubuntu-debian\/#primaryimage"},"thumbnailUrl":"https:\/\/i0.wp.com\/ubiq.co\/tech-blog\/wp-content\/uploads\/2020\/11\/self-signed-ssl-certificate.png?fit=935%2C526&ssl=1","datePublished":"2020-11-17T05:50:27+00:00","dateModified":"2025-08-26T04:39:50+00:00","author":{"@id":"https:\/\/ubiq.co\/tech-blog\/#\/schema\/person\/db98d49a766a3a111d8510935ab90abc"},"description":"Self-Signed Certificate allows you to securely send & receive data between client and server. Here is how to create self-signed SSL certificate for Apache.","breadcrumb":{"@id":"https:\/\/ubiq.co\/tech-blog\/how-to-create-a-self-signed-ssl-certificate-for-apache-in-ubuntu-debian\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/ubiq.co\/tech-blog\/how-to-create-a-self-signed-ssl-certificate-for-apache-in-ubuntu-debian\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/ubiq.co\/tech-blog\/how-to-create-a-self-signed-ssl-certificate-for-apache-in-ubuntu-debian\/#primaryimage","url":"https:\/\/i0.wp.com\/ubiq.co\/tech-blog\/wp-content\/uploads\/2020\/11\/self-signed-ssl-certificate.png?fit=935%2C526&ssl=1","contentUrl":"https:\/\/i0.wp.com\/ubiq.co\/tech-blog\/wp-content\/uploads\/2020\/11\/self-signed-ssl-certificate.png?fit=935%2C526&ssl=1","width":935,"height":526,"caption":"create self-signed certificate in apache"},{"@type":"BreadcrumbList","@id":"https:\/\/ubiq.co\/tech-blog\/how-to-create-a-self-signed-ssl-certificate-for-apache-in-ubuntu-debian\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/ubiq.co\/tech-blog\/"},{"@type":"ListItem","position":2,"name":"How To Create a Self-Signed SSL Certificate for Apache in Ubuntu\/Debian"}]},{"@type":"WebSite","@id":"https:\/\/ubiq.co\/tech-blog\/#website","url":"https:\/\/ubiq.co\/tech-blog\/","name":"Ubiq BI","description":"Build dashboards &amp; reports in minutes","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/ubiq.co\/tech-blog\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Person","@id":"https:\/\/ubiq.co\/tech-blog\/#\/schema\/person\/db98d49a766a3a111d8510935ab90abc","name":"Sreeram Sreenivasan","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/secure.gravatar.com\/avatar\/4b3127ed2d4bb8efb3fa0bbb52cf2efd4d0156c97fc05a503537c883e8279947?s=96&d=mm&r=g","url":"https:\/\/secure.gravatar.com\/avatar\/4b3127ed2d4bb8efb3fa0bbb52cf2efd4d0156c97fc05a503537c883e8279947?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/4b3127ed2d4bb8efb3fa0bbb52cf2efd4d0156c97fc05a503537c883e8279947?s=96&d=mm&r=g","caption":"Sreeram Sreenivasan"},"description":"Sreeram Sreenivasan is the Founder of Ubiq. He has helped many Fortune 500 companies in the areas of BI &amp; software development.","sameAs":["https:\/\/www.linkedin.com\/in\/sreeram-sreenivasan\/"],"url":"https:\/\/ubiq.co\/tech-blog\/author\/wordpress\/"}]}},"jetpack_featured_media_url":"https:\/\/i0.wp.com\/ubiq.co\/tech-blog\/wp-content\/uploads\/2020\/11\/self-signed-ssl-certificate.png?fit=935%2C526&ssl=1","jetpack_shortlink":"https:\/\/wp.me\/pbGGTT-zp","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/ubiq.co\/tech-blog\/wp-json\/wp\/v2\/posts\/2195","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/ubiq.co\/tech-blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/ubiq.co\/tech-blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/ubiq.co\/tech-blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/ubiq.co\/tech-blog\/wp-json\/wp\/v2\/comments?post=2195"}],"version-history":[{"count":27,"href":"https:\/\/ubiq.co\/tech-blog\/wp-json\/wp\/v2\/posts\/2195\/revisions"}],"predecessor-version":[{"id":9290,"href":"https:\/\/ubiq.co\/tech-blog\/wp-json\/wp\/v2\/posts\/2195\/revisions\/9290"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/ubiq.co\/tech-blog\/wp-json\/wp\/v2\/media\/2203"}],"wp:attachment":[{"href":"https:\/\/ubiq.co\/tech-blog\/wp-json\/wp\/v2\/media?parent=2195"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/ubiq.co\/tech-blog\/wp-json\/wp\/v2\/categories?post=2195"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/ubiq.co\/tech-blog\/wp-json\/wp\/v2\/tags?post=2195"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}