续订Exchange Server证书
思韵闪耀
2022-09-16
0

每个证书都有内置的到期日期。 在Exchange Server中,安装在Exchange服务器上的默认自签名证书在服务器上安装Exchange后 5 年过期。 您可以使用 Exchange 管理中心 (EAC) 或 Exchange 命令行管理程序 续订 Exchange 证书。 这包括 Exchange 自签名证书和由证书机构 (CA) 颁发的证书。

开始前,需要知道什么?

  • 估计完成时间:5 分钟

  • 若要了解如何在本地 Exchange 组织中打开 Exchange 命令行管理程序,请参阅 Open the Exchange Management Shell

  • 对于由 CA 颁发的证书,确认 CA 的证书请求要求。Exchange 生成使用 Base64 编码(默认)或可分辨编码规则 (DER) 的 PKCS #10 请求 (.req) 文件,使用 1024、2048(默认)或 4096 位的 RSA 公钥。请注意,编码和公钥选项仅在 Exchange 命令行管理程序 中可用。

  • 若要续订由 CA 颁发的证书,需使用由同一 CA 颁发的证书来续订证书。 如果更改 CA,或尝试续订证书时原始证书出错,您需要为新的证书创建新的证书请求(也称为证书签名请求或 CSR)。 有关详细信息,请参阅为证书颁发机构创建Exchange Server证书请求

  • 如果续订或替换由订阅的边缘传输服务器上的 CA 颁发的证书,则需要删除旧证书,然后删除并重新创建边缘订阅。有关详细信息,请参阅边缘订阅进程

  • 您必须先获得权限,然后才能执行此过程或多个过程。若要查看所需的权限,请参阅 客户端和移动设备权限主题中的"客户端访问服务安全"条目。

  • 若要了解本主题中的过程可能适用的键盘快捷键,请参阅 Exchange 管理中心内的键盘快捷键

 提示

遇到问题?请访问以下 Exchange 论坛寻求帮助:Exchange ServerExchange Online 或 Exchange Online Protection

续订由证书颁发机构颁发的证书。

获取由内部 CA(例如,Active Directory 证书服务)或商业 CA 颁发的证书的过程是相同的。

若要续订由 CA 颁发的证书,需创建证书续订请求,然后向 CA 发送请求。 之后 CA 将向您发送实际证书文件(该文件需要在 Exchange 服务器上安装)。 该步骤和通过在服务器上安装证书以完成新证书的请求的步骤几乎是相同的。 有关说明,请参阅“完成挂起的Exchange Server证书请求

使用 EAC 创建面向证书颁发机构的证书续订请求

  1. Open the EAC and navigate to Servers > Certificates.

  2. In the Select server list, select the Exchange server that holds the certificate that you want to renew.

  3. All valid certificates have a Renew link in the details pane that's visible when you select the certificate from the list. Select the certificate that you want to renew, and then click Renew in the details pane.

  4. On the Renew Exchange certificate page that opens, in the Save the certificate request to the following file field, enter the UNC path and filename for the new certificate renewal request file. 例如,\\FileServer01\Data\ContosoCertRenewal.req。 完成后,单击 “确定”。

The certificate request appears in the list of Exchange certificates with a status value of Pending.

使用 Exchange 命令行管理程序 创建面向证书颁发机构的证书续订请求

若要为证书颁发机构创建新的证书续订请求,请使用以下语法:

  • 如果需要将证书续订请求文件 的内容 发送到 CA,请使用以下语法创建 Base64 编码的请求文件:

    PowerShell

    $txtrequest = Get-ExchangeCertificate -Thumbprint <Thumbprint> | New-ExchangeCertificate -GenerateRequest [-KeySize <1024 | 2048 | 4096>] [-Server <ServerIdentity>]
    [System.IO.File]::WriteAllBytes('<FilePathOrUNCPath>\<FileName>.req', [System.Text.Encoding]::Unicode.GetBytes($txtrequest))
    
  • 如果需要将 证书续订请求文件 发送到 CA,请使用以下语法创建 DER 编码的请求文件:

    PowerShell

    $binrequest = Get-ExchangeCertificate -Thumbprint <Thumbprint> | New-ExchangeCertificate -GenerateRequest -BinaryEncoded [-KeySize <1024 | 2048 | 4096>] [-Server <ServerIdentity>]
    [System.IO.File]::WriteAllBytes('<FilePathOrUNCPath>\<FileName>.pfx', $binrequest.FileData)
    

若要找到您想续订的证书的指纹值,请运行以下命令:

PowerShell

Get-ExchangeCertificate | where {$_.Status -eq "Valid" -and $_.IsSelfSigned -eq $false} | Format-List FriendlyName,Subject,CertificateDomains,Thumbprint,NotBefore,NotAfter

有关详细语法和参数信息,请参阅 Get-ExchangeCertificate 和 New-ExchangeCertificate

注意:

  • 如果不使用 KeySize 参数,则证书请求具有 2048 位 RSA 公钥。
  • 如果不使用 服务器 参数,则该命令将运行本地Exchange服务器。

此示例为具有指纹值 5DB9879E38E36BCB60B761E29794392B23D1C054的现有证书创建 Base64 编码的证书续订请求:

PowerShell

$txtrequest = Get-ExchangeCertificate -Thumbprint 5DB9879E38E36BCB60B761E29794392B23D1C054 | New-ExchangeCertificate -GenerateRequest
[System.IO.File]::WriteAllBytes('\\FileServer01\Data\ContosoCertRenewal.req', [System.Text.Encoding]::Unicode.GetBytes($txtrequest))

此示例为同一证书创建 DER (二进制) 编码的证书续订请求:

PowerShell

$binrequest = Get-ExchangeCertificate -Thumbprint <Thumbprint> | New-ExchangeCertificate -GenerateRequest -BinaryEncoded
[System.IO.File]::WriteAllBytes('\\FileServer01\Data\ContosoCertRenewal.pfx', $binrequest.FileData)

如何知道已成功创建证书续订请求?

若要确认是否已成功为证书颁发机构创建了证书续订请求,请执行以下步骤之一:

  • In the EAC at Servers > Certificates, verify the server where you stored the certificate request is selected. The request should be in the list of certificates with the Status value Pending request.

  • 在用于存储证书请求的服务器上的 Exchange 命令行管理程序 中,运行以下命令:

    PowerShell

    Get-ExchangeCertificate | where {$_.Status -eq "PendingRequest" -and $_.IsSelfSigned -eq $false} | Format-List FriendlyName,Subject,CertificateDomains,Thumbprint
    

续订 Exchange 自签名证书

续订 Exchange 自签名证书的过程基本上相当于制作了一个新的证书。

使用 EAC 以续订 Exchange 自签名证书

  1. Open the EAC and navigate to Servers > Certificates.

  2. In the Select server list, select the Exchange server that holds the certificate that you want to renew.

  3. All valid certificates have a Renew link in the details pane that's visible when you select the certificate from the list. Select the certificate that you want to renew, and then click Renew in the details pane.

  4. On the Renew Exchange certificate page that opens, verify the read-only list of Exchange services that the existing certificate is assigned to, and then click OK.

使用 Exchange 命令行管理程序 以续订 Exchange 自签名证书

若要续订自签名证书,请使用以下语法:

PowerShell

Get-ExchangeCertificate -Thumbprint <Thumbprint> | New-ExchangeCertificate [-Force] [-PrivateKeyExportable <$true | $false>]

若要找到您想续订的证书的指纹值,请运行以下命令:

PowerShell

Get-ExchangeCertificate | where {$_.IsSelfSigned -eq $true} | Format-List FriendlyName,Subject,CertificateDomains,Thumbprint,NotBefore,NotAfter

本示例将在本地 Exchange 服务器上续订自签名证书,并使用以下设置:

  • 要续订的现有自签名证书的指纹值为 BC37CBE2E59566BFF7D01FEAC9B6517841475F2D
  • 强制 开关在没有确认提示的情况下替换原始自签名证书。
  • 该私钥是可以导出的。这样,您可以导出证书并将其导入到其他服务器上。

PowerShell

Get-ExchangeCertificate -Thumbprint BC37CBE2E59566BFF7D01FEAC9B6517841475F2D | New-ExchangeCertificate -Force -PrivateKeyExportable $true

如何知道已成功续订Exchange自签名证书?

若要确认您是否已成功地续订了 Exchange 自签名证书,请使用以下过程之一:

  • In the EAC at Servers > Certificates, verify the server where you installed the certificate is selected. In the list of certificates, verify that the certificate has Status property value Valid.

  • 在续订自签名证书的服务器上的 Exchange 命令行管理程序 中,运行以下命令以确认属性值:

PowerShell

Get-ExchangeCertificate | where {$_.Status -eq "Valid" -and $_.IsSelfSigned -eq $true} | Format-List FriendlyName,Subject,CertificateDomains,Thumbprint,NotBefore,NotAfter

【版权声明】
本站部分内容来源于互联网,本站不拥有所有权,不承担相关法律责任。如果发现本站有侵权的内容,欢迎发送邮件至masing@13sy.com 举报,并提供相关证据,一经查实,本站将立刻删除涉嫌侵权内容。

相关内容

将IIS设置克隆到新服务器...
将IIS设置克隆到新服务器的最佳方法是使用IIS配置文件。以下是详...
2025-06-06
网页保护、网页图片保护
1、禁止另存网页,把如下代码加入到网页body/body中 程序代...
2025-05-30
搭建Git服务器及本机克隆...
Git是什么?Git是目前世界上最先进的分布式版本控制系统。SVN...
2025-03-17
ubuntu环境下搭建gi...
操作环境:服务器:Ubuntu 24.04.2 LTS+git 2...
2025-03-17
docker-compos...
1.Compose介绍 DockerCompose是一个用来定义和...
2024-04-26
firewall-cmd ...
firewalld的简要说明:firewalld 、firewal...
2024-03-15

热门资讯

Exchange 2013/2... Exchange 2013/2016/2019邮件大小限制 可以在三个位置上配置Exchange上的...
SMTP 发送邮件错误码和解决... SMTP错误码/建议解决方法 错误总表 420 1. Timeout Communication P...
Exchange 2013 O... 最近在Exchange 2013环境中,遇到OWA/ECP无法访问的问题;用户是可以正常通过...
彻底卸载Exchange Se... 一般来说,我们安装完Exchange Server 2016之后,可以通过正常卸载程序来进行卸载,但...
Exchange 2013批量... 一批量删除特定主题的邮件 1.1批量删除所有数据库中特定主题的邮件 1)群发了几封主题为backup...
快速查看已安装Exchange... Exchange 2010的版本号在Exchange管理控制台(EMC)显示的,好像不准确了。比如,...
在 Exchange 2016... 用户邮箱是与人员关联的 Exchange 邮箱,通常为每人一个邮箱。每个用户邮箱都有一个关联的 Ac...
exchange2013域名(... 需要对 接受的域 和 电子邮件地址策略进行配置: 首先外网域名要做解析和增加mx记录,这里就不具体说...
如何为AD 添加多个UPN后缀 今天我在群里看到有群友在问User principal name (UPN)多后缀的问题,我在这里就...
EMS实用命令收集 Exchange Server 2013 运维系列运行邮件删除命令 Exchange Managem...