{"id":304,"date":"2019-10-26T15:09:16","date_gmt":"2019-10-26T15:09:16","guid":{"rendered":"http:\/\/www.linuxsystems.ovh\/?p=304"},"modified":"2021-10-17T13:01:09","modified_gmt":"2021-10-17T13:01:09","slug":"ustawianie-wlasnego-poprawnego-certyfikatuj-w-dovecot-oraz-postfix","status":"publish","type":"post","link":"https:\/\/www.linuxsystems.ovh\/?p=304","title":{"rendered":"Ustawianie w\u0142asnego (poprawnego) certyfikatu w dovecot, oraz postfix"},"content":{"rendered":"\n<p>Po wst\u0119pnej konfiguracji swojego serwera pocztowego, warto zadba\u0107, aby mia\u0142 on poprawne certyfikaty \ud83d\ude42 .<\/p>\n\n\n\n<!--more-->\n\n\n\n<p>Po wygenerowaniu certyfikat\u00f3w przez letsencrypt wrzucam je do <strong>\/etc\/ssl<\/strong>, w kt\u00f3rym to daj\u0119 2 pliki:<\/p>\n\n\n\n<p>nazwa_certyfikatu.key -&gt; w kt\u00f3rym mam klucz do certyfikatu SSL<br>nazwa_certyfikatu.ssl -&gt; w kt\u00f3rym trzymam certyfikat SSL, oraz klucze po\u015brednie \ud83d\ude42<\/p>\n\n\n\n<p>Edytuj\u0119 plik \/etc\/postfix\/main.cf<\/p>\n\n\n\n<p>na samym dole mamy:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>smtpd_tls_key_file = \/etc\/ssl\/nazwa_certyfikatu.key\nsmtpd_tls_cert_file = \/etc\/ssl\/nazwa_certyfikatu.crt<\/code><\/pre>\n\n\n\n<p>oraz robimy restart postfixa:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>systemctl restart postfix<\/code><\/pre>\n\n\n\n<p>Nast\u0119pnie edytujemy plik dovecot, dotycz\u0105cy konfiguracji SSL:<\/p>\n\n\n\n<p>\/etc\/dovecot\/conf.d\/10-ssl.conf<\/p>\n\n\n\n<p>i zmieniamy tam:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>ssl_cert = &lt;\/etc\/ssl\/nazwa_certyfikatu.crt\nssl_key = &lt;\/etc\/ssl\/nazwa_certyfikatu.key<\/code><\/pre>\n\n\n\n<p>i restartujemy dovecot:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>systemctl restart dovecot<\/code><\/pre>\n\n\n\n<p>Je\u017celi przesz\u0142o wszystko poprawnie, od teraz mo\u017cemy \u0142\u0105czy\u0107 si\u0119 z nasz\u0105 skrzynk\u0105 pocztow\u0105 i wysy\u0142a\u0107 z niej maile, bez \u017cadnych &#8222;wyj\u0105tk\u00f3w na certyfikaty&#8221; \ud83d\ude42<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Po wst\u0119pnej konfiguracji swojego serwera pocztowego, warto zadba\u0107, aby mia\u0142 on poprawne certyfikaty \ud83d\ude42 .<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[38],"tags":[],"class_list":["post-304","post","type-post","status-publish","format-standard","hentry","category-linux"],"_links":{"self":[{"href":"https:\/\/www.linuxsystems.ovh\/index.php?rest_route=\/wp\/v2\/posts\/304","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.linuxsystems.ovh\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.linuxsystems.ovh\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.linuxsystems.ovh\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.linuxsystems.ovh\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=304"}],"version-history":[{"count":4,"href":"https:\/\/www.linuxsystems.ovh\/index.php?rest_route=\/wp\/v2\/posts\/304\/revisions"}],"predecessor-version":[{"id":504,"href":"https:\/\/www.linuxsystems.ovh\/index.php?rest_route=\/wp\/v2\/posts\/304\/revisions\/504"}],"wp:attachment":[{"href":"https:\/\/www.linuxsystems.ovh\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=304"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.linuxsystems.ovh\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=304"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.linuxsystems.ovh\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=304"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}