{"id":571,"date":"2018-11-08T03:57:13","date_gmt":"2018-11-07T18:57:13","guid":{"rendered":"https:\/\/www7390uo.sakura.ne.jp\/wordpress\/?p=571"},"modified":"2022-05-21T23:46:38","modified_gmt":"2022-05-21T14:46:38","slug":"apache%e3%81%abssl%e3%82%b5%e3%83%bc%e3%83%90%e8%a8%bc%e6%98%8e%e6%9b%b8%e3%81%ae%e8%a8%ad%e5%ae%9a%e3%82%92%e3%81%8a%e3%81%93%e3%81%aa%e3%81%86","status":"publish","type":"post","link":"https:\/\/www7390uo.sakura.ne.jp\/wordpress\/archives\/571","title":{"rendered":"Apache\u306bSSL\u30b5\u30fc\u30d0\u8a3c\u660e\u66f8\u306e\u8a2d\u5b9a\u3092\u304a\u3053\u306a\u3046"},"content":{"rendered":"\n<p>OS: Ubuntu Server 18.04.1 LTS<br>Apache 2.4.35<\/p>\n\n\n\n<p><a href=\"https:\/\/www7390uo.sakura.ne.jp\/wordpress\/archives\/566\">SSL\u30b5\u30fc\u30d0\u8a3c\u660e\u66f8\u3092\u53d6\u5f97<\/a>\u3057\u305f\u3089Web\u30b5\u30fc\u30d0\u306e\u8a2d\u5b9a\u3082\u30a2\u30bf\u30dc\u30a6\u306b\u5fc5\u8981\u3067\u3042\u308b\u3002\u30bd\u30fc\u30b9\u304b\u3089\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3057\u305fApache2\u306e\u8a2d\u5b9a\u30d5\u30a1\u30a4\u30eb\u3092\u7de8\u96c6\u3057\u3066\u3086\u304f\u3002\u5e78\u3044 <code>conf\/extra\/httpd-ssl.conf<\/code> \u306b\u96db\u5f62\u304c\u7528\u610f\u3055\u308c\u3066\u3044\u308b\u306e\u3067\u5927\u304d\u304f\u66f8\u304d\u63db\u3048\u308b\u5fc5\u8981\u304c\u7121\u304f\u3066\u5927\u5909\u6709\u96e3\u3044\u3082\u306e\u3067\u3042\u308b\u3002<\/p>\n\n\n\n<p>\u6697\u53f7\u5316\u901a\u4fe1\u3092\u304a\u3053\u306a\u3046\u305f\u3081\u306e\u30e2\u30b8\u30e5\u30fc\u30eb\u304c\u30ed\u30fc\u30c9\u3055\u308c\u3066\u3044\u306a\u3044\u3068<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">AH00526: Syntax error on line 2 of \/usr\/local\/apache2\/conf\/extra\/httpd-ssl.conf:\nInvalid command 'SSLCipherSuite', perhaps misspelled or defined by a module not included in the server configuration<\/pre>\n\n\n\n<p>\u3068\u3044\u3046\u30a8\u30e9\u30fc\u30e1\u30c3\u30bb\u30fc\u30b8\u3092\u9802\u6234\u3057\u305f\u308a<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">AH00526: Syntax error on line 8 of \/usr\/local\/apache2\/conf\/extra\/httpd-ssl.conf:\nSSLSessionCache: 'shmcb' session cache not supported (known names: ). Maybe you need to load the appropriate socache module (mod_socache_shmcb?).<\/pre>\n\n\n\n<p>\u3068\u3044\u3046\u5177\u5408\u306b<a href=\"http:\/\/httpd.apache.org\/docs\/2.4\/mod\/mod_ssl.html#sslsessioncache\">SSL\u30bb\u30c3\u30b7\u30e7\u30f3\u3092\u30ad\u30e3\u30c3\u30b7\u30e5<\/a>\u3059\u308b\u6a5f\u80fd\u3092\u6d3b\u7528\u3059\u308b\u305f\u3081\u306e\u30e2\u30b8\u30e5\u30fc\u30eb\u304c\u5fc5\u8981\u3067\u3042\u308b\u65e8\u3001\u77e5\u3089\u3055\u308c\u308b\u3002\u4e88\u3081\u5404\u30e2\u30b8\u30e5\u30fc\u30eb\u3092\u30ed\u30fc\u30c9\u3059\u308b\u3088\u3046\u306b\u9805\u76ee\u306e\u30b3\u30e1\u30f3\u30c8\u3092\u5916\u3057\u3066\u304a\u304f\u3002<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">$ sudo vi \/usr\/local\/apache2\/conf\/httpd.conf \nLoadModule ssl_module modules\/mod_ssl.so\nLoadModule socache_shmcb_module modules\/mod_socache_shmcb.so\nInclude conf\/extra\/httpd-ssl.conf<\/pre>\n\n\n\n<p>\u3042\u3068\u306fhttpd-ssl.conf\u306e\u96db\u5f62\u3092\u5229\u7528\u3057\u3066VirtualHost\u306e\u8a2d\u5b9a\u3092\u3057\u305f\u308a\u8a3c\u660e\u66f8\u3084\u79d8\u5bc6\u9375\u3092\u8aad\u307f\u8fbc\u3080\u3088\u3046\u3088\u3057\u306a\u306b\u66f8\u304d\u63db\u3048\u3066configtest\u3067Syntax OK\u304c\u51fa\u308c\u3070\u7d42\u3044\u3067\u3042\u308b\u3002<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">$ sudo vi \/usr\/local\/apache2\/conf\/extra\/httpd-ssl.conf\nSSLCertificateFile \"\/etc\/letsencrypt\/live\/www7390uo.sakura.ne.jp\/fullchain.pem\"\nSSLCertificateKeyFile \"\/etc\/letsencrypt\/live\/www7390uo.sakura.ne.jp\/privkey.pem\"\n\n$ sudo \/usr\/local\/apache2\/bin\/apachectl configtest\nSyntax OK<\/pre>\n\n\n\n<div class=\"wp-block-image\"><figure class=\"aligncenter\"><a href=\"https:\/\/www7390uo.sakura.ne.jp\/wordpress\/wp-content\/uploads\/2018\/10\/apache-ssl.png\"><img loading=\"lazy\" decoding=\"async\" width=\"443\" height=\"353\" src=\"https:\/\/www7390uo.sakura.ne.jp\/wordpress\/wp-content\/uploads\/2018\/10\/apache-ssl.png\" alt=\"\" class=\"wp-image-572\" srcset=\"https:\/\/www7390uo.sakura.ne.jp\/wordpress\/wp-content\/uploads\/2018\/10\/apache-ssl.png 443w, https:\/\/www7390uo.sakura.ne.jp\/wordpress\/wp-content\/uploads\/2018\/10\/apache-ssl-300x239.png 300w\" sizes=\"auto, (max-width: 443px) 100vw, 443px\" \/><\/a><figcaption>\u56f31. \u30b5\u30fc\u30d0\u8a3c\u660e\u66f8\u304c\u6b63\u5e38\u306b\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3055\u308c\u305f\u69d8\u5b50<\/figcaption><\/figure><\/div>\n\n\n\n<p>\u3053\u306e\u969b\u3001mod_rewrite\u3067\u4ee5\u3063\u3066HTTP\u3067\u306e\u30a2\u30af\u30bb\u30b9\u3092HTTPS\u3078\u30ea\u30c0\u30a4\u30ec\u30af\u30c8\u3055\u305b\u308b\u70ba\u306b.htaccess\u3082\u8ffd\u52a0\u3057\u3066\u3084\u3063\u305f\u3002\u30af\u30e9\u30a4\u30a2\u30f3\u30c8\u3078\u8fd4\u3059HTTP\u30b9\u30c6\u30fc\u30bf\u30b9\u30b3\u30fc\u30c9\u306f301 Moved Parmanently\u306b\u3057\u3066\u3084\u308c\u3070\u826f\u3055\u305d\u3046\u306a\u60c5\u52e2\u3067\u3042\u308b\u3002<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">$ vi .htaccess\nRewriteEngine On\nRewriteCond %{HTTPS} off\nRewriteRule ^(.*)$ https:\/\/%{HTTP_HOST}%{REQUEST_URI} [R=301,L]<\/pre>\n","protected":false},"excerpt":{"rendered":"<p>OS: Ubuntu Server 18.04.1 LTSApache 2.4.35 SSL\u30b5\u30fc\u30d0\u8a3c\u660e\u66f8\u3092\u53d6\u5f97\u3057\u305f\u3089Web\u30b5\u30fc\u30d0\u306e\u8a2d\u5b9a\u3082\u30a2\u30bf\u30dc\u30a6\u306b\u5fc5\u8981\u3067\u3042\u308b\u3002\u30bd\u30fc\u30b9\u304b\u3089\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3057\u305fApache2\u306e\u8a2d\u5b9a\u30d5\u30a1\u30a4\u30eb\u3092\u7de8\u96c6\u3057\u3066\u3086\u304f\u3002\u5e78\u3044 conf\/extra\/httpd-ssl.conf \u306b\u96db\u5f62\u304c\u7528\u610f\u3055\u308c\u3066\u3044\u308b\u306e\u3067\u5927\u304d\u304f\u66f8\u304d\u63db\u3048\u308b\u5fc5\u8981\u304c\u7121\u304f\u3066\u5927\u5909\u6709\u96e3\u3044\u3082\u306e\u3067\u3042\u308b\u3002 \u6697\u53f7\u5316\u901a\u4fe1\u3092\u304a\u3053\u306a\u3046\u305f\u3081\u306e\u30e2\u30b8\u30e5\u30fc\u30eb &#8230; <a title=\"Apache\u306bSSL\u30b5\u30fc\u30d0\u8a3c\u660e\u66f8\u306e\u8a2d\u5b9a\u3092\u304a\u3053\u306a\u3046\" class=\"read-more\" href=\"https:\/\/www7390uo.sakura.ne.jp\/wordpress\/archives\/571\" aria-label=\"Apache\u306bSSL\u30b5\u30fc\u30d0\u8a3c\u660e\u66f8\u306e\u8a2d\u5b9a\u3092\u304a\u3053\u306a\u3046 \u306b\u3064\u3044\u3066\u3055\u3089\u306b\u8aad\u3080\">\u7d9a\u304d\u3092\u8aad\u3080<\/a><\/p>\n","protected":false},"author":1,"featured_media":1178,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[162],"tags":[187,192],"class_list":["post-571","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-162","tag-apache","tag-192"],"views":11965,"_links":{"self":[{"href":"https:\/\/www7390uo.sakura.ne.jp\/wordpress\/wp-json\/wp\/v2\/posts\/571","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www7390uo.sakura.ne.jp\/wordpress\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www7390uo.sakura.ne.jp\/wordpress\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www7390uo.sakura.ne.jp\/wordpress\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www7390uo.sakura.ne.jp\/wordpress\/wp-json\/wp\/v2\/comments?post=571"}],"version-history":[{"count":0,"href":"https:\/\/www7390uo.sakura.ne.jp\/wordpress\/wp-json\/wp\/v2\/posts\/571\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www7390uo.sakura.ne.jp\/wordpress\/wp-json\/wp\/v2\/media\/1178"}],"wp:attachment":[{"href":"https:\/\/www7390uo.sakura.ne.jp\/wordpress\/wp-json\/wp\/v2\/media?parent=571"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www7390uo.sakura.ne.jp\/wordpress\/wp-json\/wp\/v2\/categories?post=571"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www7390uo.sakura.ne.jp\/wordpress\/wp-json\/wp\/v2\/tags?post=571"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}