[GH-ISSUE #486] [Bug] 生成的私钥文件与证书不匹配 #308

Closed
opened 2026-03-03 01:02:21 +03:00 by kerem · 7 comments
Owner

Originally created by @czjge on GitHub (Mar 6, 2025).
Original GitHub issue: https://github.com/certimate-go/certimate/issues/486

描述问题
生成的私钥文件与证书不匹配
提示:nginx: [emerg] SSL_CTX_use_PrivateKey("/.../private.key") failed (SSL: error:0B080074:x509 certificate routines:X509_check_private_key:key values mismatch)

环境

  • 操作系统: Ubuntu 20.04.6 LTS
  • 浏览器: Chrome 133.0.6943.142
  • 仓库版本: v0.2.23-beta
  • 证书类型:Let's Encrypt
Originally created by @czjge on GitHub (Mar 6, 2025). Original GitHub issue: https://github.com/certimate-go/certimate/issues/486 **描述问题** 生成的私钥文件与证书不匹配 提示:nginx: [emerg] SSL_CTX_use_PrivateKey("/.../private.key") failed (SSL: error:0B080074:x509 certificate routines:X509_check_private_key:key values mismatch) **环境** - 操作系统: Ubuntu 20.04.6 LTS - 浏览器: Chrome 133.0.6943.142 - 仓库版本: v0.2.23-beta - 证书类型:Let's Encrypt
kerem 2026-03-03 01:02:21 +03:00
Author
Owner

@fudiwei commented on GitHub (Mar 6, 2025):

咋部署的?

<!-- gh-comment-id:2703081448 --> @fudiwei commented on GitHub (Mar 6, 2025): 咋部署的?
Author
Owner

@czjge commented on GitHub (Mar 6, 2025):

docker部署,用了一段时间了,之前都没问题

<!-- gh-comment-id:2703099063 --> @czjge commented on GitHub (Mar 6, 2025): docker部署,用了一段时间了,之前都没问题
Author
Owner

@fudiwei commented on GitHub (Mar 6, 2025):

我是说证书咋部署到 nginx 上的?

<!-- gh-comment-id:2703108432 --> @fudiwei commented on GitHub (Mar 6, 2025): 我是说证书咋部署到 nginx 上的?
Author
Owner

@czjge commented on GitHub (Mar 6, 2025):

SSH 部署

<!-- gh-comment-id:2703111379 --> @czjge commented on GitHub (Mar 6, 2025): SSH 部署
Author
Owner

@fudiwei commented on GitHub (Mar 6, 2025):

奇怪…… 😕

先检查一下你部署路径的证书文件和私钥文件内容有没有损坏吧,以及文件最后修改时间看一下和部署时间对不对得上。

<!-- gh-comment-id:2703119662 --> @fudiwei commented on GitHub (Mar 6, 2025): 奇怪…… 😕 先检查一下你部署路径的证书文件和私钥文件内容有没有损坏吧,以及文件最后修改时间看一下和部署时间对不对得上。
Author
Owner

@czjge commented on GitHub (Mar 6, 2025):

没有损坏,时间也对的上。。。

<!-- gh-comment-id:2703153914 --> @czjge commented on GitHub (Mar 6, 2025): 没有损坏,时间也对的上。。。
Author
Owner

@fudiwei commented on GitHub (Mar 6, 2025):

无法复现问题 😕

Issue 先开着看看其他人有没有类似的情况没吧。

<!-- gh-comment-id:2703399182 --> @fudiwei commented on GitHub (Mar 6, 2025): 无法复现问题 😕 Issue 先开着看看其他人有没有类似的情况没吧。
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/certimate#308
No description provided.