Bug 235546 - ark: disable JavaScript in HTML preview
Summary: ark: disable JavaScript in HTML preview
Status: RESOLVED FIXED
Alias: None
Product: ark
Classification: Applications
Component: general (show other bugs)
Version: unspecified
Platform: Fedora RPMs Linux
: NOR wishlist
Target Milestone: ---
Assignee: Harald Hvaal
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-04-27 15:09 UTC by Tomas Hoger
Modified: 2010-04-28 00:57 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Tomas Hoger 2010-04-27 15:09:06 UTC
Version:           2.14 (using KDE 4.4.2)
OS:                Linux
Installed from:    Fedora RPMs

ark uses KHTML part to preview HTML files stored in archives.  Previewed HTML files are treated as local files and included javascripts are executed with null document.domain.  This has certain risks such as those noted in bug #235468.  While proper fix to that bug can mitigate some risks, disabling javascript in ark preview should offer a protection against future similar issues.

Steps to reproduce:
- take reproducer from bug #235468
- add it to some archive
- open it in ark, preview html file, javascript is executed
Comment 1 Raphael Kubo da Costa 2010-04-28 00:54:43 UTC
SVN commit 1119906 by rkcosta:

When opening an HTML file with KHTMLPart, disable Java, JavaScript,
plugins and external references.

This is a saner and safer default, since the archive might come from an
unknown and untrusted sender. If access to the disabled stuff is needed,
the user should simply extract the file and view it in a browser.

See also bug 235468.

BUG: 235546

 M  +1 -2      CMakeLists.txt  
 M  +14 -0     arkviewer.cpp  


WebSVN link: http://websvn.kde.org/?view=rev&revision=1119906
Comment 2 Raphael Kubo da Costa 2010-04-28 00:57:16 UTC
SVN commit 1119908 by rkcosta:

Backport r1119906.

When opening an HTML file with KHTMLPart, disable Java, JavaScript,
plugins and external references.

This is a saner and safer default, since the archive might come from an
unknown and untrusted sender. If access to the disabled stuff is needed,
the user should simply extract the file and view it in a browser.

See also bug 235468.

CCBUG: 235546


 M  +1 -2      CMakeLists.txt  
 M  +14 -0     arkviewer.cpp  


WebSVN link: http://websvn.kde.org/?view=rev&revision=1119908