Control use of the Web Serial API: wartość rejestru DefaultSerialGuardSettingUżytkownikHKCU\Software\Policies\Mozilla\Firefox

Brak oficjalnego tekstu w tym języku (wyświetlono oryginał angielski)

Identyfikator zasady
DefaultSerialGuardSetting
Zakres
Konfiguracja komputera, Konfiguracja użytkownika
Obsługiwane w systemach
Firefox 151 or later
Źródło
Mozilla Firefox Policy Templates (wersja 8.3)
Kategoria
Mozilla › Firefox

Rejestr

DefaultSerialGuardSetting

REG_DWORDUżytkownikKomputer
…\Software\Policies\Mozilla\FirefoxHKCU\Software\Policies\Mozilla\Firefox Bieżący klucz
HKLM\Software\Policies\Mozilla\Firefox
Wartość włączona
Zależy od wartości opcji
Element
-
Opcje
PozycjaZapisana wartość
Do not allow any site to request access to serial ports via the Web Serial API2
Allow sites to ask the user to grant access to a serial port3
Zastosuj przez .reg · CMD · PowerShell
UżytkownikUstawienie dla każdego konta
.reg
Windows Registry Editor Version 5.00

[HKEY_CURRENT_USER\Software\Policies\Mozilla\Firefox]

; Opcje (użyj tylko jednej)
; Do not allow any site to request access to serial ports via the Web Serial API
"DefaultSerialGuardSetting"=dword:00000002
; Allow sites to ask the user to grant access to a serial port
"DefaultSerialGuardSetting"=dword:00000003
CMD
:: Opcje (użyj tylko jednej)

:: Do not allow any site to request access to serial ports via the Web Serial API
reg add "HKCU\Software\Policies\Mozilla\Firefox" /v "DefaultSerialGuardSetting" /t REG_DWORD /d 2 /f
:: Allow sites to ask the user to grant access to a serial port
reg add "HKCU\Software\Policies\Mozilla\Firefox" /v "DefaultSerialGuardSetting" /t REG_DWORD /d 3 /f
PowerShell
# Wspólne: utwórz klucz
New-Item -Path 'HKCU:\Software\Policies\Mozilla\Firefox' -Force | Out-Null

# Opcje (użyj tylko jednej)
# Do not allow any site to request access to serial ports via the Web Serial API
New-ItemProperty -Path 'HKCU:\Software\Policies\Mozilla\Firefox' -Name 'DefaultSerialGuardSetting' -PropertyType DWord -Value 2 -Force | Out-Null
# Allow sites to ask the user to grant access to a serial port
New-ItemProperty -Path 'HKCU:\Software\Policies\Mozilla\Firefox' -Name 'DefaultSerialGuardSetting' -PropertyType DWord -Value 3 -Force | Out-Null
KomputerUstawienie dla całego komputera
.reg
Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\Software\Policies\Mozilla\Firefox]

; Opcje (użyj tylko jednej)
; Do not allow any site to request access to serial ports via the Web Serial API
"DefaultSerialGuardSetting"=dword:00000002
; Allow sites to ask the user to grant access to a serial port
"DefaultSerialGuardSetting"=dword:00000003
CMD
:: Opcje (użyj tylko jednej)

:: Do not allow any site to request access to serial ports via the Web Serial API
reg add "HKLM\Software\Policies\Mozilla\Firefox" /v "DefaultSerialGuardSetting" /t REG_DWORD /d 2 /f
:: Allow sites to ask the user to grant access to a serial port
reg add "HKLM\Software\Policies\Mozilla\Firefox" /v "DefaultSerialGuardSetting" /t REG_DWORD /d 3 /f
PowerShell
# Wspólne: utwórz klucz
New-Item -Path 'HKLM:\Software\Policies\Mozilla\Firefox' -Force | Out-Null

# Opcje (użyj tylko jednej)
# Do not allow any site to request access to serial ports via the Web Serial API
New-ItemProperty -Path 'HKLM:\Software\Policies\Mozilla\Firefox' -Name 'DefaultSerialGuardSetting' -PropertyType DWord -Value 2 -Force | Out-Null
# Allow sites to ask the user to grant access to a serial port
New-ItemProperty -Path 'HKLM:\Software\Policies\Mozilla\Firefox' -Name 'DefaultSerialGuardSetting' -PropertyType DWord -Value 3 -Force | Out-Null