← Back to team overview

unity-design team mailing list archive

Re: Executable file dialog box...

 

On Tue, Sep 21, 2010 at 12:38, Luke Benstead <kazade@xxxxxxxxx> wrote:
> I'm wondering if we need this dialog at all, surely we can code in a little
> bit of logic here. How about:
>
> If the file is executable and:
>
> 1. If the file is binary and the extension not associated to a program,
> attempt to run it
> or
> 2. If the file is text and has the #! line at the top, try to run it. Add
> "Run as a Program" and "Run as a Terminal Program" to the right click menu
> or
> 3. If the file is text, open it in the default editor and add "Run as a
> Program" and "Run as a Terminal Program" to the right click menu
>
> That way double clicking a file will do what the user expects most of the
> time, and give the option of alternative behaviour if necessary.
>
> Thoughts?

This may have security implications. What if the file is a malicious
bash script? GNOME attempts to help the user avoid running malicious
code. Double clicking a text file downloaded from the internet should
not be a gamble. You double click the file to study it, and suddenly
it deletes all your files.

Instead of removing the dialog, it could be simplified: "This file you
downloaded may be a program. It could be a virus. Do you want to run
the program?", with answers "Yes", "No, open in text editor", "No,
cancel".

Maybe also add a clamav scan. Since many people have Wine installed,
it is even more important to scan untrusted executable files for
viruses.

-- 
Remco



Follow ups

References