Install SSL Let’s Encrypt di Zimbra 8.8.6 Centos 7

Install SSL Let’s Encrypt di Zimbra 8.8.6 Centos 7

Install SSL Let’s Encrypt di Zimbra 8.8.6 Centos 7, Let’s Encrypt merupakan Certificate SSL yang valid, automated, open certificate authority dan free digunakan. Ini salah satu pilihan untuk memproteksi zimbra mail server. Berikut langkah instalasi

hostname: zimbra.saad.web.id

1. Validate dan Generate SSL

Matikan service proxy dan mailbox zimbra (user zimbra)

zmproxyctl stop
zmmailboxdctl stop

Letakkan Clone folder letsencrypt pada /opt dengan perintah git, bila belum ada git. bisa install dengan perintah yum

yum install -y git
cd /opt
git clone https://github.com/letsencrypt/letsencrypt
cd letsencrypt

Masukkan perintah berikut untuk request certificate single hostname

root@zimbra:~/tmp/letsencrypt# ./letsencrypt-auto certonly --standalone

Masukkan perintah berikut untuk request certificate multi hostname dalam satu SSL

root@zimbra:~/tmp/letsencrypt# ./letsencrypt-auto certonly --standalone -d apache.example.com -d zmail.example.com

Masukkan akun email anda, untuk pemberitahuan dan pemulihan key

<em>enter email address (used for urgent notices and lost key recovery):</em>
admin@saad.web.id

Pilih Agree. pada term of service

<em>pleased read the term of service at:</em>
agree

Masukkan hostname. dalam hal ini yang digunakan zimbra.saad.web.id

Please enter in your domain name(s) (comma and/or space separated)
zimbra.saad.web.id

Tunggu proses validate, sampai muncul keterangan berikut

IMPORTANT NOTES:
 - Congratulations! Your certificate and chain have been saved at
   /etc/letsencrypt/live/zimbra86.zimbra.io/fullchain.pem. Your cert
   will expire on 2016-03-04. To obtain a new version of the
   certificate in the future, simply run Let's Encrypt again.
 - If like Let's Encrypt, please consider supporting our work by:

   Donating to ISRG / Let's Encrypt:   https://letsencrypt.org/donate
   Donating to EFF:                    https://eff.org/donate-le

Lokasi certificate pada /etc/letsencrypt/live/zimbra.saad.web.id/

ubah chain.pem dengan perintah

nano /etc/letsencrypt/live/zimbra.saad.web.id/chain.pem

tambahkan pada baris paling bawah certificate dibawah dan simpan. certificate di peroleh dari https://www.ident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FBM5
JDGFoqgCWjBH4d1QB7wCCZAA62RjYJsWvIjJEubSfZGL+T0yjWW06XyxV3bqxbYo
Ob8VZRzI9neWagqNdwvYkQsEjgfbKbYK7p2CNTUQ
-----END CERTIFICATE-----

2. Verify certificate

Copy seluruh file /etc/letsencrypt/live/zimbra.saad.web.id ke dalam /opt/zimbra/ssl/letsencrypt

root@zimbra:~# mkdir /opt/zimbra/ssl/letsencrypt
root@zimbra:~# cp /etc/letsencrypt/live/zimbra.saad.web.id/* /opt/zimbra/ssl/letsencrypt/
root@zimbra:~# chown zimbra:zimbra /opt/zimbra/ssl/letsencrypt/*
root@zimbra:~# ls -la /opt/zimbra/ssl/letsencrypt/
total 24
drwxr-xr-x 2 root   root   4096 Jul 15 22:59 .
drwxr-xr-x 8 zimbra zimbra 4096 Jul 15 22:59 ..
-rw-r--r-- 1 zimbra zimbra 1809 Jul 15 22:59 cert.pem
-rw-r--r-- 1 zimbra zimbra 2847 Jul 15 22:59 chain.pem
-rw-r--r-- 1 zimbra zimbra 3456 Jul 15 22:59 fullchain.pem
-rw-r--r-- 1 zimbra zimbra 1704 Jul 15 22:59 privkey.pem

open folder /opt/zimbra/ssl/letsencrypt masukkan perintah berikut untuk verify ssl (user zimbra)

cd /opt/zimbra/ssl/letsencrypt
/opt/zimbra/bin/zmcertmgr verifycrt comm privkey.pem cert.pem chain.pem

Bila berhasil di verify maka akan muncul seperti dibawah ini

zimbra@zimbra:/opt/zimbra/ssl/letsencrypt/# /opt/zimbra/bin/zmcertmgr verifycrt comm privkey.pem cert.pem chain.pem 
** Verifying cert.pem against privkey.pem
Certificate (cert.pem) and private key (privkey.pem) match.
Valid Certificate: cert.pem: OK

3. Deploy SSL

Backup terlebih dahulu folder ssl zimbra dengan perintah berikut:

cp -a /opt/zimbra/ssl/zimbra /opt/zimbra/ssl/zimbra.$(date "+%Y%m%d")

Copy private key ke commercial key dengan perintah berikut

cp /opt/zimbra/ssl/letsencrypt/privkey.pem /opt/zimbra/ssl/zimbra/commercial/commercial.key

Deploy ssl dengan perintah berikut

/opt/zimbra/bin/zmcertmgr deploycrt comm cert.pem chain.pem

Restart Zimbra

zmcontrol restart

Selesai

 

~~ Bila ragu menggunakan Let’s Encrypt bisa membeli certificate SSL Berbayar dari kami, klik disini untuk info lengkapnya. ~~

Please follow and like us:

Enjoy this blog? Please spread the word :)

WhatsApp us