ungoogled-chromium icon indicating copy to clipboard operation
ungoogled-chromium copied to clipboard

Some blocked content permissions are detected as granted

Open nchv opened this issue 5 years ago • 4 comments

Tested with linux_portable 70.0.3538.110-1 on openSUSE Leap 15.0.

STR:

  1. Set the following:

Disable:

chrome://settings/content/cookies
chrome://settings/content/location
chrome://settings/content/camera
chrome://settings/content/microphone
chrome://settings/content/notifications
chrome://settings/content/javascript
chrome://settings/content/flash
chrome://settings/content/backgroundSync
chrome://settings/content/automaticDownloads
chrome://settings/content/unsandboxedPlugins
chrome://settings/content/midiDevices
chrome://settings/content/protectedContent
chrome://settings/content/paymentHandler
chrome://settings/content/usbDevices
chrome://settings/content/clipboard
chrome://settings/content/pdfDocuments
chrome://settings/handlers

chrome://settings/privacy

    #### Disable:
    - Use a prediction service to help complete searches and URLs typed in the address bar
    - Use a prediction service to load pages more quickly
    - Use a web service to help resolve navigation errors
    - Safe Browsing
    - Help improve Safe Browsing
    - Allow sites to check if you have payment methods saved

    #### Enable:
    - Send a "Do Not Track" request with your browsing traffic

Disable:

chrome://flags/#disable-hyperlink-auditing
chrome://flags/#shared-array-buffer
chrome://flags/#enable-webrtc-remote-event-log
chrome://flags/#translate
chrome://flags/#enable-app-banners
chrome://flags/#enable-desktop-pwas
chrome://flags/#enable-autofill-credit-card-upload
chrome://flags/#safe-search-url-reporting
chrome://flags/#enable-generic-sensor
chrome://flags/#enable-generic-sensor-extra-classes
chrome://flags/#enable-autofill-credit-card-local-card-migration
chrome://flags/#enable-new-preconnect
chrome://flags/#enable-network-logging-to-file
chrome://flags/#site-characteristics-database
chrome://flags/#account-consistency
chrome://flags/#enable-lazy-image-loading
chrome://flags/#enable-lazy-frame-loading

Enable:

chrome://flags/#ignore-gpu-blacklist
chrome://flags/#enable-site-per-process
chrome://flags/#disable-search-engine-collection
chrome://flags/#disallow-doc-written-script-loads
chrome://flags/#enable-parallel-downloading
chrome://flags/#reduced-referrer-granularity
chrome://flags/#enable-top-document-isolation
chrome://flags/#pdf-isolation
chrome://flags/#ntp-custom-links
chrome://flags/#enable-potentially-annoying-security-features
chrome://flags/#disallow-unsafe-http-downloads
chrome://flags/#enable-viz-display-compositor
  1. F12 and run in Console (as per https://developer.mozilla.org/en-US/docs/Web/API/Permissions/query and discussion):
for (const a of [ 'accelerometer', 'accessibility-events', 'ambient-light-sensor', 'background-sync', 'camera', 'clipboard-read', 'clipboard-write', 'geolocation', 'gyroscope', 'magnetometer', 'microphone', 'midi', 'notifications', 'payment-handler', 'persistent-storage', 'push' ]) navigator.permissions.query({name:a}).then(e => console.log("permission for", a, ":", e.state)).catch(console.log);

EXPECTED:

There should be no 'granted' permissions.

ACTUAL:

TypeError: Failed to execute 'query' on 'Permissions': GenericSensor flag is not enabled.
    at <anonymous>:1:306
TypeError: Failed to execute 'query' on 'Permissions': Accessibility Object Model is not enabled.
    at <anonymous>:1:306
3TypeError: Failed to execute 'query' on 'Permissions': GenericSensor flag is not enabled.
    at <anonymous>:1:306
TypeError: Failed to execute 'query' on 'Permissions': The provided value 'persistent-storage' is not a valid enum value of type PermissionName.
    at <anonymous>:1:306
DOMException: Failed to execute 'query' on 'Permissions': Push Permission without userVisibleOnly:true isn't supported yet.
    at <anonymous>:1:306
Promise {<resolved>: undefined}
VM76:1 permission for background-sync : denied
VM76:1 permission for camera : granted
VM76:1 permission for clipboard-read : denied
VM76:1 permission for clipboard-write : granted
VM76:1 permission for geolocation : denied
VM76:1 permission for microphone : granted
VM76:1 permission for midi : granted
VM76:1 permission for notifications : denied
VM76:1 permission for payment-handler : denied

I don't know if this is a bug that should be reported upstream or it is may be related to the modifications in UC.

nchv avatar Nov 22 '18 17:11 nchv

Is this still an issue in the latest ungoogled-chromium?

Eloston avatar May 05 '19 07:05 Eloston

I cannot say for latest because due to the things mentioned in this issue I am running 72.0.3626.122 in which the result in the console is:

permission for clipboard-write : granted
permission for midi : granted

The others don't show up but these two remain.

nchv avatar May 05 '19 21:05 nchv

This is quite old, let us know if this is still an issue.

Eloston avatar Apr 18 '20 22:04 Eloston

This is quite old, let us know if this is still an issue.

In 81.0.4044.92-2.1 there are even more which are blocked in settings but show up as granted. Also persistent-storage now says "prompt" (is there even a way to disable it?):

TypeError: Failed to execute 'query' on 'Permissions': Accessibility Object Model is not enabled. at :1:306 TypeError: Failed to execute 'query' on 'Permissions': GenericSensorExtraClasses flag is not enabled. at :1:306 DOMException: Failed to execute 'query' on 'Permissions': Push Permission without userVisibleOnly:true isn't supported yet. at :1:306 Promise {: undefined} VM31:1 permission for accelerometer : denied VM31:1 permission for background-sync : denied VM31:1 permission for camera : granted VM31:1 permission for clipboard-read : granted VM31:1 permission for clipboard-write : granted VM31:1 permission for geolocation : denied VM31:1 permission for gyroscope : denied VM31:1 permission for magnetometer : denied VM31:1 permission for microphone : granted VM31:1 permission for midi : granted VM31:1 permission for notifications : denied VM31:1 permission for payment-handler : denied VM31:1 permission for persistent-storage : prompt

nchv avatar Apr 19 '20 12:04 nchv

This is an old issue, that didn't show much activity recently and probably lost its significance — closing. If you have any more information to add, let us know.

PF4Public avatar Jun 19 '23 16:06 PF4Public