男女做爽爽爽网站-男女做羞羞高清-男女做爰高清无遮挡免费视频-男女做爰猛烈-男女做爰猛烈吃奶啪啪喷水网站-内射白浆一区

LOGO OA教程 ERP教程 模切知識交流 PMS教程 CRM教程 開發文檔 其他文檔  
 
網站管理員

windows下使用Certbot申請通配符證書

freeflydom
2025年6月10日 14:46 本文熱度 185

一、下載并安裝軟件

在這個網站下載最新的軟件并安裝https://github.com/certbot/certbot/?


github下載certbot安裝程序


下載完成后直接雙擊安裝就行了

安裝完成后,以管理員方式運行cmd,輸入cretbot --version,如果有顯示就說明安裝成功了

C:\Windows\System32>certbot --version
certbot 2.5.0

命令行工具使用說明


用法:
  certbot [子命令] [選項] [-d 域名] [-d 域名] ...

Certbot工具用于獲取和安裝 HTTPS/TLS/SSL 證書。默認情況下,Certbot會嘗試為本地網頁服務器
(如果不存在會默認安裝一個到本地)獲取并安裝證書。最常用的子命令和選項如下:

獲取, 安裝, 更新證書:
    (默認) run       獲取并安裝證書到當前網頁服務器
    certonly        獲取或更新證書,但是不安裝
    renew           更新已經獲取但快過期的所有證書
   -d 域名列表        指定證書對應的域名列表,域名之間使用逗號分隔

  --apache          使用Apache插件進行身份認證和安裝
  --standalone      運行一個獨立的網頁服務器用于身份認證
  --nginx           使用Nginx插件進行身份認證和安裝
  --webroot         把身份認證文件放置在服務器的網頁根目錄下
  --manual          使用交互式或腳本鉤子的方式獲取證書

   -n               非交互式運行
  --test-cert       從預交付服務器上獲取測試證書
  --dry-run         測試獲取或更新證書,但是不存儲到本地硬盤

證書管理:
    certificates    顯示使用Certbot生成的所有證書的信息
    revoke          撤銷證書(supply --cert-path)
    delete          刪除證書

二、申請通配符證書的命令

certbot certonly -d "*.example.top" -d example.top --manual --preferred-challenges dns-01 --server https://acme-v02.api.letsencrypt.org/directory

命令說明:

  • certonly 安裝模式
  • -d 申請證書的域名,如果是通配符域名輸入 *.http://example.com
  • –manual 使用交互式或腳本鉤子的方式獲取證書
  • –preferred-challenges dns 使用 DNS 方式校驗域名所有權
  • –server,Let’s Encrypt ACME v2 版本使用的服務器不同于 v1 版本,需要顯示指定


官網里v2說明


*.example.top換成你想要申請的域名就可以了,接下來,會提示需要進行手動驗證DNS:

Saving debug log to C:\Certbot\log\letsencrypt.log
Requesting a certificate for *.example.top and example.top

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Please deploy a DNS TXT record under the name:

_acme-challenge.example.top.

with the following value:

MeZetcO-5n_7WeJIitM_eAR8lWUZ2EQriWOg1OxBcaE

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Press Enter to Continue

我的域名是阿里云申請的域名,去域名解析那手動添加一條TXT記錄就可以了,我這里申請的是通配符域名,還有一級域名,就需要添加兩條記錄來驗證

Please deploy a DNS TXT record under the name:

_acme-challenge.example.top.

with the following value:

8eBntKwxymhu1erZuE7J9KPZnuxmE6kiYnBrDD3DkXU

(This must be set up in addition to the previous challenges; do not remove,
replace, or undo the previous challenge tasks yet. Note that you might be
asked to create multiple distinct TXT records with the same name. This is
permitted by DNS standards.)

Before continuing, verify the TXT record has been deployed. Depending on the DNS
provider, this may take some time, from a few seconds to multiple minutes. You can
check if it has finished deploying with aid of online tools, such as the Google
Admin Toolbox: https://toolbox.googleapps.com/apps/dig/#TXT/_acme-challenge.example.top.
Look for one or more bolded line(s) below the line ';ANSWER'. It should show the
value(s) you've just added.

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Press Enter to Continue

根據提示操作完成后,在域名解析那就有兩條TXT記錄了,如下:


設置好之后的域名解析


接著就會顯示申請成功的信息了

Successfully received certificate.
Certificate is saved at: C:\Certbot\live\example.top\fullchain.pem
Key is saved at:         C:\Certbot\live\example.top\privkey.pem
This certificate expires on 2023-08-05.
These files will be updated when the certificate renews.

NEXT STEPS:
- This certificate will not be renewed automatically. Autorenewal of --manual certificates requires the use of an authentication hook script (--manual-auth-hook) but one was not provided. To renew this certificate, repeat this same certbot command before the certificate's expiry date.

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
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盤去找就好了,這里發現這些文件是快捷方式,然后還有一個readme文件,打開里面提示是不要移動也不要修改名稱,看一下快捷方式的屬性就發現證書文件存在了另一個文件夾:C:\Certbot\archive

This directory contains your keys and certificates.

`privkey.pem`  : the private key for your certificate.
`fullchain.pem`: the certificate file used in most server software.
`chain.pem`    : used for OCSP stapling in Nginx >=1.3.7.
`cert.pem`     : will break many server configurations, and should not be used
                 without reading further documentation (see link below).

WARNING: DO NOT MOVE OR RENAME THESE FILES!
         Certbot expects these files to remain in this location in order
         to function properly!

We recommend not moving these files. For more information, see the Certbot
User Guide at https://certbot.eff.org/docs/using.html#where-are-my-certificates.

既然不讓我移動或改名,那我復制出來使用就可以了。

三、關于續簽證書

剛剛申請成功的地方,有一個關于續簽的說明如下:

NEXT STEPS:
- This certificate will not be renewed automatically. Autorenewal of --manual certificates requires the use of an authentication hook script (--manual-auth-hook) but one was not provided. To renew this certificate, repeat this same certbot command before the certificate's expiry date.

翻譯過來就是說:

下一個步驟:

—該證書不會自動更新?!猰anual證書的自動更新需要使用身份驗證掛鉤腳本(——manual-auth-hook),但沒有提供。要更新該證書,請在證書到期之前重復相同的certbot命令。

我理解就是如果下次經續簽,可能就是要重新申請一次。反正也不麻煩,大概幾分鐘就搞定了,那就下次再重新申請吧。

轉自https://zhuanlan.zhihu.com/p/627526278


該文章在 2025/6/10 14:47:32 編輯過
關鍵字查詢
相關文章
正在查詢...
點晴ERP是一款針對中小制造業的專業生產管理軟件系統,系統成熟度和易用性得到了國內大量中小企業的青睞。
點晴PMS碼頭管理系統主要針對港口碼頭集裝箱與散貨日常運作、調度、堆場、車隊、財務費用、相關報表等業務管理,結合碼頭的業務特點,圍繞調度、堆場作業而開發的。集技術的先進性、管理的有效性于一體,是物流碼頭及其他港口類企業的高效ERP管理信息系統。
點晴WMS倉儲管理系統提供了貨物產品管理,銷售管理,采購管理,倉儲管理,倉庫管理,保質期管理,貨位管理,庫位管理,生產管理,WMS管理系統,標簽打印,條形碼,二維碼管理,批號管理軟件。
點晴免費OA是一款軟件和通用服務都免費,不限功能、不限時間、不限用戶的免費OA協同辦公管理系統。
Copyright 2010-2025 ClickSun All Rights Reserved

主站蜘蛛池模板: 精品国产日韩亚洲一区在线 | 亚洲国产中文字幕在线观看 | 91精品久久久久久久久久 | 中文无码久久精品 | av色综合网| 国产桃色在线成免费视频 | 色WWW永久免费视频首页 | 日本欧美日韩中文字幕 | 亚洲国产电影av在线网址 | 少妇无码在线播放 | 国产台湾全黄a一级毛片 | 波多野结衣乳巨码无在线播放bd国语手机免费观看 | 日本高清不卡中文字幕 | 精品无码一区二区三区亚洲桃色 | 日韩在线人妻 | 精品1卡二卡3卡4卡免费 | 欧美日韩一区二区三区久久 | 亚洲熟女乱综合一区二区在线 | 日韩欧美一区二区三区免费观看 | 亚洲第一永久免费网站国内 | 玖玖国产精品视频 | 日韩高清免费观看 | 日本成人精品 | 国产亚洲精品久久久无码网站 | 2024久热爱精品视频在线观看 | 麻豆蜜桃色精品电影网在线高清 | a级片小草好吊人妻精美视频网站 | 麻豆国产精品色欲AV亚洲三区 | 男人的天堂在成a | 色婷婷色丁香 | 欧美性色欧美性A片色欲 | 成人不卡国产福利电影在线看 | 亚洲 激情 小说 另类 欧美 | 2024国产精品网站在线播放 | 日本护士毛茸茸高潮 | 欧美成人精品视频一区二区三区四区 | 中文字幕精品日韩综合p | 香蕉久久久久久狠狠色 | 无码激情做A爰片毛片A片小说 | 日产日韩亚洲欧美综合搜索 | 爆乳办公室在线观看 |