Share via


SerialAllowUsbDevicesForUrls

Automatically grant sites permission to connect to USB serial devices

Supported versions

  • On Windows and macOS since 97 or later

Description

Setting the policy lets you list sites that are automatically granted permission to access USB serial devices with vendor and product IDs that match the vendor_id and product_id fields.

Optionally you can omit the product_id field. This enables site access to all the vendor's devices. When you provide a product ID, then you give the site access to a specific device from the vendor but not all devices.

The URLs must be valid, or the policy is ignored. Only the origin (scheme, host, and port) of the URL is considered.

This policy overrides DefaultSerialGuardSetting, SerialAskForUrls, SerialBlockedForUrls and the user's preferences.

This policy only affects access to USB devices through the Web Serial API. To grant access to USB devices through the WebUSB API see the WebUsbAllowDevicesForUrls policy.

Supported features

  • Can be mandatory: Yes
  • Can be recommended: No
  • Dynamic Policy Refresh: Yes
  • Per Profile: No
  • Applies to a profile that is signed in with a Microsoft account: Yes

Data type

  • Dictionary

Windows information and settings

Group Policy (ADMX) info

  • GP unique name: SerialAllowUsbDevicesForUrls
  • GP name: Automatically grant sites permission to connect to USB serial devices
  • GP path (Mandatory): Administrative Templates/Microsoft Edge/Content settings
  • GP path (Recommended): N/A
  • GP ADMX file name: MSEdge.admx

Example value

[{"devices": [{"product_id": 5678, "vendor_id": 1234}], "urls": ["https://specific-device.example.com"]}, {"devices": [{"vendor_id": 1234}], "urls": ["https://all-vendor-devices.example.com"]}]

Registry settings

  • Path (Mandatory): SOFTWARE\Policies\Microsoft\Edge
  • Path (Recommended): N/A
  • Value name: SerialAllowUsbDevicesForUrls
  • Value type: REG_SZ

Example registry value

[{"devices": [{"product_id": 5678, "vendor_id": 1234}], "urls": ["https://specific-device.example.com"]}, {"devices": [{"vendor_id": 1234}], "urls": ["https://all-vendor-devices.example.com"]}]

Expanded example registry value

[
  {
    "devices": [
      {
        "product_id": 5678,
        "vendor_id": 1234
      }
    ],
    "urls": [
      "https://specific-device.example.com"
    ]
  },
  {
    "devices": [
      {
        "vendor_id": 1234
      }
    ],
    "urls": [
      "https://all-vendor-devices.example.com"
    ]
  }
]

Mac information and settings

  • Preference Key name: SerialAllowUsbDevicesForUrls
  • Example value:
<key>SerialAllowUsbDevicesForUrls</key>
<array>
  <dict>
    <key>devices</key>
    <array>
      <dict>
        <key>product_id</key>
        <integer>5678</integer>
        <key>vendor_id</key>
        <integer>1234</integer>
      </dict>
    </array>
    <key>urls</key>
    <array>
      <string>https://specific-device.example.com</string>
    </array>
  </dict>
  <dict>
    <key>devices</key>
    <array>
      <dict>
        <key>vendor_id</key>
        <integer>1234</integer>
      </dict>
    </array>
    <key>urls</key>
    <array>
      <string>https://all-vendor-devices.example.com</string>
    </array>
  </dict>
</array>

See also