{"id":5366,"date":"2016-09-25T01:26:20","date_gmt":"2016-09-24T17:26:20","guid":{"rendered":"https:\/\/sdeno.com\/?p=5366"},"modified":"2016-09-25T01:26:20","modified_gmt":"2016-09-24T17:26:20","slug":"ubuntu%e5%bc%80%e5%90%afhttps","status":"publish","type":"post","link":"https:\/\/sdeno.com\/?p=5366","title":{"rendered":"ubuntu\u5f00\u542fhttps"},"content":{"rendered":"<pre>sudo openssl req -x509 -nodes -days 365 -newkey rsa:2048 -keyout \/etc\/apache2\/ssl\/apache.key -out \/etc\/apache2\/ssl\/apache.crt<\/pre>\n<p>&nbsp;<\/p>\n<pre style=\"color: #000000;\">&lt;IfModule mod_ssl.c&gt;\r\n    &lt;VirtualHost _default_:443&gt;\r\n        ServerAdmin <span class=\"highlight\" style=\"color: #e94849;\">admin@example.com<\/span>\r\n        <span class=\"highlight\" style=\"color: #e94849;\">ServerName your_domain.com<\/span>\r\n        <span class=\"highlight\" style=\"color: #e94849;\">ServerAlias www.your_domain.com<\/span>\r\n        DocumentRoot <span class=\"highlight\" style=\"color: #e94849;\">\/var\/www\/html<\/span>\r\n        ErrorLog ${APACHE_LOG_DIR}\/error.log\r\n        CustomLog ${APACHE_LOG_DIR}\/access.log combined\r\n        SSLEngine on\r\n        SSLCertificateFile <span class=\"highlight\" style=\"color: #e94849;\">\/etc\/apache2\/ssl\/apache.crt<\/span>\r\n        SSLCertificateKeyFile <span class=\"highlight\" style=\"color: #e94849;\">\/etc\/apache2\/ssl\/apache.key<\/span>\r\n        &lt;FilesMatch \"\\.(cgi|shtml|phtml|php)$\"&gt;\r\n                        SSLOptions +StdEnvVars\r\n        &lt;\/FilesMatch&gt;\r\n        &lt;Directory \/usr\/lib\/cgi-bin&gt;\r\n                        SSLOptions +StdEnvVars\r\n        &lt;\/Directory&gt;\r\n        BrowserMatch \"MSIE [2-6]\" \\\r\n                        nokeepalive ssl-unclean-shutdown \\\r\n                        downgrade-1.0 force-response-1.0\r\n        BrowserMatch \"MSIE [17-9]\" ssl-unclean-shutdown\r\n    &lt;\/VirtualHost&gt;\r\n&lt;\/IfModule&gt;<\/pre>\n<p>&nbsp;<\/p>\n<p>&nbsp;<\/p>\n","protected":false},"excerpt":{"rendered":"<p>sudo openssl req -x509 -nodes -days 365 -newkey rsa:204 [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[39],"tags":[],"class_list":["post-5366","post","type-post","status-publish","format-standard","hentry","category-ubuntu"],"_links":{"self":[{"href":"https:\/\/sdeno.com\/index.php?rest_route=\/wp\/v2\/posts\/5366","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/sdeno.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/sdeno.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/sdeno.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/sdeno.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=5366"}],"version-history":[{"count":0,"href":"https:\/\/sdeno.com\/index.php?rest_route=\/wp\/v2\/posts\/5366\/revisions"}],"wp:attachment":[{"href":"https:\/\/sdeno.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=5366"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/sdeno.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=5366"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/sdeno.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=5366"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}