設定無效的雜湊演算法 的登錄值 invalidhashalg使用者HKCU\software\policies\microsoft\office\16.0\common\signatures

原則 ID
L_SelectDigitalSignatureInvalidHashingAlgorithm
適用範圍
使用者設定
支援的作業系統
至少需要 Windows Server 2008 R2 或 Windows 7
來源
Microsoft 365 Apps / Office Administrative Templates (版本 5568.1000)
類別
Microsoft Office 2016 › 安全性設定 › 數位簽章

登錄

invalidhashalg

REG_SZ使用者
啟用時的值
取決於選項值
元素
-
選項
項目儲存的值
MD5md5
SHA1sha1
SHA256sha256
SHA384sha384
以 .reg · CMD · PowerShell 套用
.reg
Windows Registry Editor Version 5.00

[HKEY_CURRENT_USER\software\policies\microsoft\office\16.0\common\signatures]

; 選項 (只使用其中一個)
; MD5
"invalidhashalg"="md5"
; SHA1
"invalidhashalg"="sha1"
; SHA256
"invalidhashalg"="sha256"
; SHA384
"invalidhashalg"="sha384"
CMD
:: 選項 (只使用其中一個)

:: MD5
reg add "HKCU\software\policies\microsoft\office\16.0\common\signatures" /v "invalidhashalg" /t REG_SZ /d "md5" /f
:: SHA1
reg add "HKCU\software\policies\microsoft\office\16.0\common\signatures" /v "invalidhashalg" /t REG_SZ /d "sha1" /f
:: SHA256
reg add "HKCU\software\policies\microsoft\office\16.0\common\signatures" /v "invalidhashalg" /t REG_SZ /d "sha256" /f
:: SHA384
reg add "HKCU\software\policies\microsoft\office\16.0\common\signatures" /v "invalidhashalg" /t REG_SZ /d "sha384" /f
PowerShell
# 共通: 建立機碼
New-Item -Path 'HKCU:\software\policies\microsoft\office\16.0\common\signatures' -Force | Out-Null

# 選項 (只使用其中一個)
# MD5
New-ItemProperty -Path 'HKCU:\software\policies\microsoft\office\16.0\common\signatures' -Name 'invalidhashalg' -PropertyType String -Value 'md5' -Force | Out-Null
# SHA1
New-ItemProperty -Path 'HKCU:\software\policies\microsoft\office\16.0\common\signatures' -Name 'invalidhashalg' -PropertyType String -Value 'sha1' -Force | Out-Null
# SHA256
New-ItemProperty -Path 'HKCU:\software\policies\microsoft\office\16.0\common\signatures' -Name 'invalidhashalg' -PropertyType String -Value 'sha256' -Force | Out-Null
# SHA384
New-ItemProperty -Path 'HKCU:\software\policies\microsoft\office\16.0\common\signatures' -Name 'invalidhashalg' -PropertyType String -Value 'sha384' -Force | Out-Null