Certbot SSL인증서 만들기 5단계

Certbot SSL인증서 만들기

https://certbot.eff.org/instructions?ws=other&os=windows&tab=standard

certbot 인증서 발급/갱신/삭제 명령어는 다음과같다.

  • 인증서 만료기간 확인 c:\Certbot>certbot certificates
  • 인증서 갱신 테스트 c:\Certbot>certbot renew –dry-run
  • 인증서 갱신하기 c:\Certbot>certbot renew
  • 강재갱신 C:\Certbot> certbot renew –force-renew –cert-name www.daum.net
  • 인증서 삭제 C:\Certbot> certbot delete (실행후 삭제할 인증서 선택하면됨)

cerbot인증서는 아파치 서비스 중에도 갱신할수있으나, 적용을 위해서는 아파치를 재시작 해줘야하며
예약작업에서 아래와같이 적용하면 적용후 아파치를 재시작 할수있다

$ 0 18 1 * * /usr/bin/certbot renew –renew-hook=”sudo systemctl restart apache2″

certbot 다운로드 및 설치방법

다운로드는홈페이지 https://github.com/certbot/certbot/releases 에서 다운받으면 됩니다. 하지만 아래 설명과 똑같은 버전은 첨부파일을 참고하면 됩니다.

반드시 관리자권한으로 cmd실행한다.

실행에 앞서 iis 또는 apache에서 http서비스를 하나 만든다. 만든다음 설치중에 wwwroot 경로를 입력해야한다.

Microsoft Windows [Version 10.0.14393]
C:\>cd certbot
C:\Certbot>certbot certonly
Saving debug log to C:\Certbot\log\letsencrypt.log

How would you like to authenticate with the ACME CA?
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
1: Spin up a temporary webserver (standalone)
2: Place files in webroot directory (webroot)
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Select the appropriate number [1-2] then [enter] (press 'c' to cancel): 2
Enter email address (used for urgent renewal and security notices)
 (Enter 'c' to cancel): yesgeg@hanmail.net

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Please read the Terms of Service at
https://letsencrypt.org/documents/LE-SA-v1.3-September-21-2022.pdf. You must
agree in order to register with the ACME server. Do you agree?
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
(Y)es/(N)o: y

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Would you be willing, once your first certificate is successfully issued, to
share your email address with the Electronic Frontier Foundation, a founding
partner of the Let's Encrypt project and the non-profit organization that
develops Certbot? We'd like to send you email about our work encrypting the web,
EFF news, campaigns, and ways to support digital freedom.
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
(Y)es/(N)o: y
Account registered.
Please enter the domain name(s) you would like on your certificate (comma and/or
space separated) (Enter 'c' to cancel): vod.mbcdy.com
Requesting a certificate for vod.mbcdy.com
Input the webroot for vod.mbcdy.com: (Enter 'c' to cancel): C:\Certbot\wowza

Successfully received certificate.
Certificate is saved at: C:\Certbot\live\vod.mbcdy.com\fullchain.pem
Key is saved at:         C:\Certbot\live\vod.mbcdy.com\privkey.pem
This certificate expires on 2024-01-28.
These files will be updated when the certificate renews.
Certbot has set up a scheduled task to automatically renew this certificate in the background.

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
If you like Certbot, please consider supporting our work by:
 * Donating to ISRG / Let's Encrypt:   https://letsencrypt.org/donate
 * Donating to EFF:                    https://eff.org/donate-le
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

C:\Certbot>

리눅스 서버에서 설치하기

Ubuntu (raspberry) 에서 설치하기

# apt-get update
# apt-get install letsencrypt (또는  apt-get install certbot)

상세설치방법은 https://blog.lael.be/post/5107 를 참고한다.

centos(rocky linux) 에서 설치하기

# yum install certbot python2-certbot-apache

설치방법은 아래 사이트를 참고한다.