From d45214240a9d326147576f03171d2a84cb9e624f Mon Sep 17 00:00:00 2001 From: Hiro Date: Sun, 16 Oct 2005 13:44:43 +0000 Subject: win32: restrict launching of executable files. git-svn-id: svn://sylpheed.sraoss.jp/sylpheed/trunk@651 ee746299-78ed-0310-b773-934348b2243d --- src/mimeview.c | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) (limited to 'src/mimeview.c') diff --git a/src/mimeview.c b/src/mimeview.c index 7f67b163..44a24fb3 100644 --- a/src/mimeview.c +++ b/src/mimeview.c @@ -1122,7 +1122,6 @@ static void mimeview_view_file(const gchar *filename, MimeInfo *partinfo, #ifdef G_OS_WIN32 if (!cmdline) { DWORD dwtype; - AlertValue avalue; if (str_has_suffix_case(filename, ".exe") || str_has_suffix_case(filename, ".com") || @@ -1132,13 +1131,13 @@ static void mimeview_view_file(const gchar *filename, MimeInfo *partinfo, str_has_suffix_case(filename, ".vbs") || str_has_suffix_case(filename, ".js") || GetBinaryType(filename, &dwtype)) { - avalue = alertpanel_full + alertpanel_full (_("Opening executable file"), - _("This is an executable file. Do you really want to launch it?"), - ALERT_WARNING, G_ALERTALTERNATE, FALSE, - GTK_STOCK_YES, GTK_STOCK_NO, NULL); - if (avalue != G_ALERTDEFAULT) - return; + _("This is an executable file. Opening executable file is restricted for security.\n" + "If you want to launch it, save it to somewhere and make sure it is not an virus or something like a malicious program."), + ALERT_WARNING, G_ALERTDEFAULT, FALSE, + GTK_STOCK_OK, NULL, NULL); + return; } execute_open_file(filename, partinfo->content_type); return; -- cgit v1.2.3