啟用 MSIX 套件的允許區域 的登錄值 EnableMsixAllowedZones (Appx)電腦HKLM\Software\Policies\Microsoft\Windows\Appx

原則 ID
EnableMsixAllowedZones
適用範圍
電腦設定
支援的作業系統
至少需要 Windows 11 版本 24H2
來源
Administrative Templates (.admx) for Windows 11 2026 Update (26H2) (版本 1.0)
類別
Windows 元件 › 應用程式套件部署

登錄

EnableMsixAllowedZones

-電腦

LocalMachine

REG_DWORD電腦
啟用時的值
取決於選項值
元素
本機電腦
選項
項目儲存的值
封鎖0
允許1
以 .reg · CMD · PowerShell 套用
.reg
Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\Software\Policies\Microsoft\Windows\Appx\MsixAllowedZones]

; 選項 (只使用其中一個)
; 封鎖
"LocalMachine"=dword:00000000
; 允許
"LocalMachine"=dword:00000001
CMD
:: 選項 (只使用其中一個)

:: 封鎖
reg add "HKLM\Software\Policies\Microsoft\Windows\Appx\MsixAllowedZones" /v "LocalMachine" /t REG_DWORD /d 0 /f
:: 允許
reg add "HKLM\Software\Policies\Microsoft\Windows\Appx\MsixAllowedZones" /v "LocalMachine" /t REG_DWORD /d 1 /f
PowerShell
# 共通: 建立機碼
New-Item -Path 'HKLM:\Software\Policies\Microsoft\Windows\Appx\MsixAllowedZones' -Force | Out-Null

# 選項 (只使用其中一個)
# 封鎖
New-ItemProperty -Path 'HKLM:\Software\Policies\Microsoft\Windows\Appx\MsixAllowedZones' -Name 'LocalMachine' -PropertyType DWord -Value 0 -Force | Out-Null
# 允許
New-ItemProperty -Path 'HKLM:\Software\Policies\Microsoft\Windows\Appx\MsixAllowedZones' -Name 'LocalMachine' -PropertyType DWord -Value 1 -Force | Out-Null

Intranet

REG_DWORD電腦
啟用時的值
取決於選項值
元素
內部網路
選項
項目儲存的值
封鎖0
允許1
以 .reg · CMD · PowerShell 套用
.reg
Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\Software\Policies\Microsoft\Windows\Appx\MsixAllowedZones]

; 選項 (只使用其中一個)
; 封鎖
"Intranet"=dword:00000000
; 允許
"Intranet"=dword:00000001
CMD
:: 選項 (只使用其中一個)

:: 封鎖
reg add "HKLM\Software\Policies\Microsoft\Windows\Appx\MsixAllowedZones" /v "Intranet" /t REG_DWORD /d 0 /f
:: 允許
reg add "HKLM\Software\Policies\Microsoft\Windows\Appx\MsixAllowedZones" /v "Intranet" /t REG_DWORD /d 1 /f
PowerShell
# 共通: 建立機碼
New-Item -Path 'HKLM:\Software\Policies\Microsoft\Windows\Appx\MsixAllowedZones' -Force | Out-Null

# 選項 (只使用其中一個)
# 封鎖
New-ItemProperty -Path 'HKLM:\Software\Policies\Microsoft\Windows\Appx\MsixAllowedZones' -Name 'Intranet' -PropertyType DWord -Value 0 -Force | Out-Null
# 允許
New-ItemProperty -Path 'HKLM:\Software\Policies\Microsoft\Windows\Appx\MsixAllowedZones' -Name 'Intranet' -PropertyType DWord -Value 1 -Force | Out-Null

TrustedSites

REG_DWORD電腦
啟用時的值
取決於選項值
元素
信任的網站
選項
項目儲存的值
封鎖0
允許1
以 .reg · CMD · PowerShell 套用
.reg
Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\Software\Policies\Microsoft\Windows\Appx\MsixAllowedZones]

; 選項 (只使用其中一個)
; 封鎖
"TrustedSites"=dword:00000000
; 允許
"TrustedSites"=dword:00000001
CMD
:: 選項 (只使用其中一個)

:: 封鎖
reg add "HKLM\Software\Policies\Microsoft\Windows\Appx\MsixAllowedZones" /v "TrustedSites" /t REG_DWORD /d 0 /f
:: 允許
reg add "HKLM\Software\Policies\Microsoft\Windows\Appx\MsixAllowedZones" /v "TrustedSites" /t REG_DWORD /d 1 /f
PowerShell
# 共通: 建立機碼
New-Item -Path 'HKLM:\Software\Policies\Microsoft\Windows\Appx\MsixAllowedZones' -Force | Out-Null

# 選項 (只使用其中一個)
# 封鎖
New-ItemProperty -Path 'HKLM:\Software\Policies\Microsoft\Windows\Appx\MsixAllowedZones' -Name 'TrustedSites' -PropertyType DWord -Value 0 -Force | Out-Null
# 允許
New-ItemProperty -Path 'HKLM:\Software\Policies\Microsoft\Windows\Appx\MsixAllowedZones' -Name 'TrustedSites' -PropertyType DWord -Value 1 -Force | Out-Null

Internet

REG_DWORD電腦
啟用時的值
取決於選項值
元素
網際網路
選項
項目儲存的值
封鎖0
允許1
以 .reg · CMD · PowerShell 套用
.reg
Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\Software\Policies\Microsoft\Windows\Appx\MsixAllowedZones]

; 選項 (只使用其中一個)
; 封鎖
"Internet"=dword:00000000
; 允許
"Internet"=dword:00000001
CMD
:: 選項 (只使用其中一個)

:: 封鎖
reg add "HKLM\Software\Policies\Microsoft\Windows\Appx\MsixAllowedZones" /v "Internet" /t REG_DWORD /d 0 /f
:: 允許
reg add "HKLM\Software\Policies\Microsoft\Windows\Appx\MsixAllowedZones" /v "Internet" /t REG_DWORD /d 1 /f
PowerShell
# 共通: 建立機碼
New-Item -Path 'HKLM:\Software\Policies\Microsoft\Windows\Appx\MsixAllowedZones' -Force | Out-Null

# 選項 (只使用其中一個)
# 封鎖
New-ItemProperty -Path 'HKLM:\Software\Policies\Microsoft\Windows\Appx\MsixAllowedZones' -Name 'Internet' -PropertyType DWord -Value 0 -Force | Out-Null
# 允許
New-ItemProperty -Path 'HKLM:\Software\Policies\Microsoft\Windows\Appx\MsixAllowedZones' -Name 'Internet' -PropertyType DWord -Value 1 -Force | Out-Null

UntrustedSites

REG_DWORD電腦
啟用時的值
取決於選項值
元素
未受信任的網站
選項
項目儲存的值
封鎖0
允許1
以 .reg · CMD · PowerShell 套用
.reg
Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\Software\Policies\Microsoft\Windows\Appx\MsixAllowedZones]

; 選項 (只使用其中一個)
; 封鎖
"UntrustedSites"=dword:00000000
; 允許
"UntrustedSites"=dword:00000001
CMD
:: 選項 (只使用其中一個)

:: 封鎖
reg add "HKLM\Software\Policies\Microsoft\Windows\Appx\MsixAllowedZones" /v "UntrustedSites" /t REG_DWORD /d 0 /f
:: 允許
reg add "HKLM\Software\Policies\Microsoft\Windows\Appx\MsixAllowedZones" /v "UntrustedSites" /t REG_DWORD /d 1 /f
PowerShell
# 共通: 建立機碼
New-Item -Path 'HKLM:\Software\Policies\Microsoft\Windows\Appx\MsixAllowedZones' -Force | Out-Null

# 選項 (只使用其中一個)
# 封鎖
New-ItemProperty -Path 'HKLM:\Software\Policies\Microsoft\Windows\Appx\MsixAllowedZones' -Name 'UntrustedSites' -PropertyType DWord -Value 0 -Force | Out-Null
# 允許
New-ItemProperty -Path 'HKLM:\Software\Policies\Microsoft\Windows\Appx\MsixAllowedZones' -Name 'UntrustedSites' -PropertyType DWord -Value 1 -Force | Out-Null