Let’s Encrypt 【https://letsencrypt.org/】是免費的 CA,只是,有效期限只有三個月,必須要常常更新…
SSL for free【https://www.sslforfree.com/】是 Let’s Encrypt 的簡易申請
申請方法是比較簡單的,只需要輸入網址
最後會有一個檢查 URL 的動作,所以,這個 domain 必須是 Internet 可以正常名稱解析,https 服務已經 ready 好,測試環境就無緣了…
點選【Manual Verification】->【Manual Verify Domain】
點選【Manually Verify Domain】
點選【Download File #1】
按照網頁上的需求建立目錄,並上傳檔案
並且確認網址是否可以存取?
回到原來的申請網頁,點選【Download SSL Certificate】
這個畫面是個提醒的機制,因為 Certificate 只有三個月有效,過期前一個星期,會 email 提醒
Certificate 是經過 base64 encode 編碼的純文字,可以直接從網頁 copy/paste,也可以下載檔案再 upload 到 Web Server
先確定一下 Web Server 預設的 Certificate 放在哪裡
CA public key –> /etc/pki/tls/certs/ca-bundle.crt
Web Server private key –> /etc/httpd/conf/server.key
Web Server Certificate –> /etc/httpd/conf/server.crt
點選【Download All SSL Certificate Files】,觀察一下檔案
兩相比較之後,就比較清楚了
ca_bundle.crt -> /etc/pki/tls/certs/ca-bundle.crt
certificate.crt -> /etc/httpd/conf/server.crt
private.key -> /etc/httpd/conf/server.key
上傳 *.zip 檔到 Web Server,並解壓縮
將檔案 copy 到正確的位置
重新啟動服務,開啟瀏覽器,使用 https:// 連線,應該是不會出現警告訊息,可以檢視憑證,確認一下。