建立跟使用 自我簽署憑證(Self-Signed SSL Certificate) 在 Amazon ELB (Elastic Load Balancing)
- 安裝 openssl http://slproweb.com/products/Win32OpenSSL.html,預設會裝在 C:\OpenSSL-Win32
- 打開 cmd [Command prompt], 切換目錄到 cd C:\OpenSSL-Win32\bin\
- 產生私鑰
openssl genrsa -des3 -out my_domain.key 1024
- 產生 CSR
openssl req -nodes -newkey rsa:2048 -keyout my_domain.key -out my_domain.csr
- 移除私鑰密碼
copy my_domain.key my_domain.key.org
openssl rsa -in my_domain.key.org -out my_domain.key
- 產生憑證
openssl x509 -req -days 365 -in domain.csr -signkey domain.key -out domain.crt
- 開啟 AWS Console 設定憑證 https://console.aws.amazon.com/acm/home?#/importwizard/
Certificate body* : openssl x509 -inform PEM -in domain.crt
Certificate private key* : openssl rsa -in domain.key -text
- 儲存設定,去AWS ELB上指定憑證
Related