overte-org / overte

Overte open source virtual worlds platform.
https://overte.org/
Other
128 stars 47 forks source link

Allow saving files to the host system #1051

Open Armored-Dragon opened 4 days ago

Armored-Dragon commented 4 days ago

It would be a neat addition to add support for saving files to a local directory on your computer from Overte. How I am imagining it is that you would have a data blob already, but in order to save it you would need to invoke a sort of window or file picker to direct where the file should be saved. Once you have the directory picked, Overte will place the file there without having to have the script interface handle it.

JulianGro commented 3 days ago

I believe the conses last year was that we shouldn't allow saving arbitrary files to arbitrary locations from the script engine. Maybe we could create an API that allows saving only to a pre-defined folder? Perhaps something like $XDG_DOCUMENTS_DIR/Overte/?

ksuprynowicz commented 3 days ago

Predefined directory could still be risky in some ways, coupled together with another security issue in some program, not necessarily Overte, since then a malicious executable could be placed in known location. I agree with Alezia that the best way would be save dialog to chose location for the file. Then user can just decline and report if something suspicious is happening.

Armored-Dragon commented 2 days ago

I like @ksuprynowicz idea. An API call or however it would be done would always open some kind of notice naming the file that a file had been downloaded or filepicker window askign where to save the named file. As long as there is a guaranteed user visible notice that something occurred, I don't see too many issues just due to the file saving.