{"id":509,"date":"2007-04-20T01:31:58","date_gmt":"2007-04-19T16:31:58","guid":{"rendered":"http:\/\/pecos.myhome.cx\/wordpress\/?p=509"},"modified":"2007-04-20T01:31:58","modified_gmt":"2007-04-19T16:31:58","slug":"pop-over-ssl","status":"publish","type":"post","link":"https:\/\/pecos.ddns.net\/wordpress\/?p=509","title":{"rendered":"POP over SSL"},"content":{"rendered":"<p>\u4f55\u6545\u304b\u524d\u56de\u4f5c\u3063\u305fKey\u3067\u306f\u30c0\u30e1\u3060\u3063\u305f\u306e\u3067\u5c02\u7528\u306b\u4f5c\u308a\u76f4\u3057\u3001iptables\u306e995\u3082\u540c\u6642\u306b\u958b\u3051\u308b<br \/>\n<!--more--><br \/>\n\u8a3c\u660e\u66f8\u306e\u4f5c\u6210<\/p>\n<blockquote><p># mkdir -p \/usr\/local\/sslpop<br \/>\n# openssl req -new -nodes -out req.pem -keyout \/usr\/local\/sslpop\/cert.pem<br \/>\nCountry Name (2 letter code) [AU]:<strong>JP<\/strong><br \/>\nState or Province Name (full name) [Some-State]:<strong>Aichi<\/strong><br \/>\nLocality Name (eg, city) []:<strong>Okazaki<\/strong><br \/>\nOrganization Name (eg, company) [Internet Widgits Pty Ltd]:<strong>pecos.myhome.cx<\/strong><br \/>\nOrganizational Unit Name (eg, section) []:<br \/>\nCommon Name (eg, your name or your server&#8217;s hostname) []:<strong>pecos.myhome.cx<\/strong><br \/>\nEmail Address []:<strong>xxx@pecos.myhome.cx<\/strong><br \/>\nA challenge password[]:<br \/>\nAn optional company name []:\n<\/p><\/blockquote>\n<p>\u8a3c\u660e\u66f8\u306e\u8a8d\u8a3c<\/p>\n<blockquote><p># openssl genrsa -des3 -out ca.key 1024<br \/>\nEnter pass phrase for ca.key: <strong>< \u30d1\u30b9\u30d5\u30ec\u30fc\u30ba\u203b1><\/strong><br \/>\nVerifying &#8211; Enter pass phrase for ca.key: <strong>< \u30d1\u30b9\u30d5\u30ec\u30fc\u30ba\u203b1\u518d><\/strong>\n<\/p><\/blockquote>\n<p>\u4ee5\u964d\u306f\u3082\u3046\u53c2\u8003\u306b\u3057\u305f\u30b5\u30a4\u30c8\u901a\u308a\u306b\uff57<\/p>\n<blockquote><p>#openssl req -new -x509 -days 365 -key ca.key -out ca.crt<br \/>\nEnter pass phrase for ca.key:<strong>< \u30d1\u30b9\u30d5\u30ec\u30fc\u30ba\u203b1><\/strong><br \/>\nCountry Name (2 letter code) [AU]:<strong>JP<\/strong><br \/>\nState or Province Name (full name) [Some-State]:<strong>Aichi<\/strong><br \/>\nLocality Name (eg, city) []:<strong>Okazaki<\/strong><br \/>\nOrganization Name (eg, company) [Internet Widgits Pty Ltd]:<strong>pecos.myhome.cx<\/strong><br \/>\nOrganizational Unit Name (eg, section) []:<br \/>\nCommon Name (eg, YOUR name) []:<strong>pecos.myhome.cx<\/strong><br \/>\nEmail Address []:<strong>xxx@peocs.myhome.cx<\/strong>\n<\/p><\/blockquote>\n<p>\u52ff\u8ad6\u3001\u610f\u5473\u306f\u308f\u304b\u3063\u3066\u307e\u305b\u3093\uff57<\/p>\n<blockquote><p># openssl x509 -req -CA ca.crt -CAkey ca.key -days 365 -in req.pem -out signed-req.pem -CAcreateserial<br \/>\nEnter pass phrase for ca.key:<strong>< \u30d1\u30b9\u30d5\u30ec\u30fc\u30ba\u203b1><\/strong>\n<\/p><\/blockquote>\n<p>\u4f55\u304b\u9023\u7d50\u3059\u308b\u3089\u3057\u3044\u305e\uff57<\/p>\n<blockquote><p># (cat signed-req.pem ; cat cert.pem) > mail.pem<br \/>\n# chown pop mail.pem<br \/>\n# chmod 660 mail.pem\n<\/p><\/blockquote>\n<p>qpopper\u3092\u30ad\u30c3\u30af\u3055\u305b\u308bxinetd\u306e\u8a2d\u5b9a<\/p>\n<blockquote><p># vi \/etc\/xinet.d\/qpopper<br \/>\nservice pop3s<br \/>\n{<br \/>\n\u3000\u3000\u3000flags = REUSE NAMEINARGS<br \/>\n\u3000\u3000\u3000socket_type = stream<br \/>\n\u3000\u3000\u3000wait = no<br \/>\n\u3000\u3000\u3000user = root<br \/>\n\u3000\u3000\u3000server = \/usr\/sbin\/in.qpopper<br \/>\n\u3000\u3000\u3000server_args = popper -f \/etc\/qpopper995.cfg -s<br \/>\n\u3000\u3000\u3000instances = 50<br \/>\n\u3000\u3000\u3000disable = no<br \/>\n\u3000\u3000\u3000per_source = 10<br \/>\n}\n<\/p><\/blockquote>\n<p>cfg\u306f\u65b0\u898f\u3067\u4f5c\u6210\u3089\u3057\u3044\u305e\uff57<\/p>\n<blockquote><p># vi \/etc\/qpopper995.cfg<br \/>\nset clear-text-password = ssl<br \/>\nset tls-support = alternate-port<br \/>\nset tls-version = default<br \/>\nset tls-server-cert-file = \/usr\/local\/sslpop\/mail.pem<br \/>\n# \/etc\/init.d\/xinetd restart\n<\/p><\/blockquote>\n<p>\u9db4\u4e80\u30e1\u30fc\u30eb\u304b\u3089\u306fPOP over SSL\u3067\u7e4b\u304c\u3063\u305f\u3088\u3046\u3060<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u4f55\u6545\u304b\u524d\u56de\u4f5c\u3063\u305fKey\u3067\u306f\u30c0\u30e1\u3060\u3063\u305f\u306e\u3067\u5c02\u7528\u306b\u4f5c\u308a\u76f4\u3057\u3001iptables\u306e995\u3082\u540c\u6642\u306b\u958b\u3051\u308b<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[5],"tags":[],"class_list":["post-509","post","type-post","status-publish","format-standard","hentry","category-5"],"_links":{"self":[{"href":"https:\/\/pecos.ddns.net\/wordpress\/index.php?rest_route=\/wp\/v2\/posts\/509","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/pecos.ddns.net\/wordpress\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/pecos.ddns.net\/wordpress\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/pecos.ddns.net\/wordpress\/index.php?rest_route=\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/pecos.ddns.net\/wordpress\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=509"}],"version-history":[{"count":0,"href":"https:\/\/pecos.ddns.net\/wordpress\/index.php?rest_route=\/wp\/v2\/posts\/509\/revisions"}],"wp:attachment":[{"href":"https:\/\/pecos.ddns.net\/wordpress\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=509"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/pecos.ddns.net\/wordpress\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=509"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/pecos.ddns.net\/wordpress\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=509"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}