#1726 closed enhancement (fixed)
intercept xdg-open and forward it to the client
Reported by: | Antoine Martin | Owned by: | J. Max Mena |
---|---|---|---|
Priority: | major | Milestone: | 2.3 |
Component: | core | Version: | 2.2.x |
Keywords: | Cc: |
Description
This could be enabled by default when we add at least a dialog showing that the file is ready to be opened (see #1375) since we don't want open-silently by default. (for security reasons)
- forwarding of files can re-use the "send-file" protocol: wiki/FileTransfers
- for urls we will need a new protocol message
Maybe each one could be enabled independently?
Attachments (1)
Change History (6)
comment:1 Changed 3 years ago by
Status: | new → assigned |
---|
comment:2 Changed 3 years ago by
Owner: | changed from Antoine Martin to J. Max Mena |
---|---|
Status: | assigned → new |
Done in:
- r17740: add prompt for accepting file-transfer/file-open (#1375)
- r17742: packaging of xdg-open override script
- r17743: support url-open with prompt
- r17744 + r17745: enable
forward-xdg-open
by default - r17752: also redirect
gnome-open
andgvfs-open
Things that could be done to improve this:
- improve the popup dialog: #1375
- requires a unix-domain socket that does not require authentication, and we pass the socket path using an env var which is a bit iffy
forward-xdg-open
could supporturl
,paths
as options to only forward the type specified and let the other one through - meh
Notes:
- this only works from an environment we setup (we modify
$PATH
), so commands started with--start=xterm
(or--start-child
and friends), but not withDISPLAY=:N xterm
- some applications will bypass xdg-open, maybe we need to override
xdg-mime
for those? (PITA as this points to a desktop file..) - see Where does firefox get the “default” applications for opening files from? (esp comments:gnome-open
,gvfs-open
,gio open
- some kind of sick joke?) - more improvements recorded in ticket:1375#comment:7
How to test:
- start server with
forward-xdg-open=no
thenxdg-open
works normally (not overriden with our custom script)
From here on, with forward-xdg-open=yes
(which is the default):
- in an xterm, run
xdg-open https://xpra.org/
, this should popup the dialog asking the client if it accepts to open this URL - change the client's command line: set
--open-url
tono
oryes
, and check again - for file-transfers, test with
xdg-open /path/to/some/file.png
, again, the dialog should come up - and again, change
--file-transfer
tono
oryes
and check again (default value isask
)
@maxmylyn: just a FYI.
comment:5 Changed 6 weeks ago by
this ticket has been moved to: https://github.com/Xpra-org/xpra/issues/1726
Note: See
TracTickets for help on using
tickets.
Basic support added in r17726.
Will end up sending the file to the client and ask it to open it. (which is not allowed by default)