AWS 上で運用しているメールサーバーの証明書の更新を行った。

証明書発行の手順


その他


証明書送付先:public_mail@hmuna.com

証明書の購入

証明書発行会社の名前が から "SSLストア" に変更になったようだ。

発行された証明書

[AWS] ubuntu:~/work$ openssl x509 -in mail_hmuna_com.crt -noout -dates
notBefore=Jul  5 00:00:00 2019 GMT
notAfter=Aug  4 23:59:59 2021 GMT
[AWS] ubuntu:~/work$ openssl x509 -in mail_hmuna_com.crt -noout -subject
subject= /OU=Domain Control Validated/CN=mail.hmuna.com

(参考) 今回失効する証明書

[AWS] ubuntu:~/work$ openssl x509 -in /etc/ssl/certs/mail_hmuna_com.crt -noout -dates
notBefore=Jul 21 00:00:00 2016 GMT
notAfter=Sep 27 23:59:59 2019 GMT

発行は 2016/7/21 だが、何故か失効は 2019/9/27(3年と2ヶ月強)になっている。

AWS 上のメールサーバーに必要なファイルをコピー

/etc/dovecot/conf.d/10-ssl.conf への証明書の登録

# PEM encoded X.509 SSL/TLS certificate and private key. They're opened before$
# dropping root privileges, so keep the key file unreadable by anyone but$
# root. Included doc/mkcert.sh can be used to easily generate self-signed$
# certificate, just make sure to update the domains in dovecot-openssl.cnf$
#ssl_cert = </etc/dovecot/dovecot.pem$
#ssl_key = </etc/dovecot/private/dovecot.pema$
ssl_cert = </etc/ssl/certs/mail_hmuna_com.crt$
ssl_key  = </etc/ssl/private/mail_hmuna.key$

# If key file is password protected, give the password here. Alternatively$
# give it when starting dovecot with -p parameter. Since this file is often$
# world-readable, you may want to place this setting instead to a different$
# root owned 0600 file by using ssl_key_password = <path.$
#ssl_key_password =$

# PEM encoded trusted certificate authority. Set this only if you intend to use$
# ssl_verify_client_cert=yes. The file should contain the CA certificate(s)$
# followed by the matching CRL(s). (e.g. ssl_ca = </etc/ssl/certs/ca.pem)$
#ssl_ca =-$
ssl_ca  = </etc/apache2/ssl.crt/mail_hmuna_com.ca-bundle$

トップ   新規 一覧 検索 最終更新   ヘルプ   最終更新のRSS