Bug 260778 - [GTK] XDG extended attributes spec support
Summary: [GTK] XDG extended attributes spec support
Status: NEW
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebKitGTK (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Nobody
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2023-08-27 13:32 PDT by Avid Seeker
Modified: 2023-09-23 09:56 PDT (History)
5 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Avid Seeker 2023-08-27 13:32:20 PDT
XDG Extended Attributes guidelines include metadata about files that is supported on the file system level. Many programs attach this metadata to downloaded or produced files, and it would seem a useful feature to attach some metadata to downloaded files.

Steps to reproduce:
Download a webpage on xattr-supported file system.

Actual results:
user.xdg.origin and user.xdg.referrer extended attributes are not set.

Expected results:
Set user.xdg.origin and user.xdg.referrer as per Freedesktop standard: https://www.freedesktop.org/wiki/CommonExtendedAttributes/
Comment 1 Michael Catanzaro 2023-08-28 07:42:21 PDT
Moving from https://gitlab.gnome.org/GNOME/epiphany/-/issues/2165, as I mentioned there, the standard has no mention of user.xdg.referrer. It would be of questionable utility anyway: what would you ever want to use that for? 

We could set user.xdg.origin.url though.
Comment 2 Michael Catanzaro 2023-08-28 07:43:14 PDT
I'd like to ensure that at least Firefox or Chrome already does this, though, because users might be very surprised if we add extra metadata to downloaded files that other web browsers do not add.
Comment 3 Alexey Proskuryakov 2023-08-28 10:46:59 PDT
I'm guessing that the point of referrer is probably that it's what the user thinks of as where they've downloaded from. The trust comes from the referring HTML page, not from where the file is served from.

There is limited visibility for the user into the actual download URL, especially if there are redirects happening.
Comment 4 Radar WebKit Bug Importer 2023-09-03 13:33:13 PDT
<rdar://problem/114906279>
Comment 5 Michael Catanzaro 2023-09-05 06:31:40 PDT
Discussion thread here, including some negative feedback from the nautilus developers: https://discourse.gnome.org/t/feat-xdg-extended-attribute-spec-support/16892