You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@jspwiki.apache.org by "Jürgen Weber (JIRA)" <ji...@apache.org> on 2010/01/18 14:25:54 UTC

[jira] Commented: (JSPWIKI-628) Load Plugin resources from classpath

    [ https://issues.apache.org/jira/browse/JSPWIKI-628?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12801780#action_12801780 ] 

Jürgen Weber commented on JSPWIKI-628:
--------------------------------------

> Allowing a plugin to load (and possible execute) arbitrary Java classes would be very unwise.

This is already the case. A plugin currently runs in the JSPWiki VM and can execute any Java code. The wiki admin allows this implicitly by installing the plugin.

But my request is different. Please do read my original comment. I want to make files in plugin.jars downloadable to the browser. 

The plugin would finally generate a link like

/wiki/classpath/org.apache.wiki.MyApplet.class

If the file is a class, it is executed as servlet in the browser, and not in the server.
Indeed, one could download all files reachable by the server classpath. So what? There are no secrets in it, only what is in the JSPWiki download. And second, which file is downloadable from the classpath, is decided in the plugin source code and not in the plugin-usage. And plugin source code has all rights, anyway, so you have to trust the plugin author.



> Load Plugin resources from classpath
> ------------------------------------
>
>                 Key: JSPWIKI-628
>                 URL: https://issues.apache.org/jira/browse/JSPWIKI-628
>             Project: JSPWiki
>          Issue Type: Improvement
>    Affects Versions: 2.8.3
>            Reporter: Jürgen Weber
>
> Some plugins require the browser to load files. E.g. the FreeMindPlugin needs the browser to load the applet's classes, or another plugin might need some flash code.
> Currently the solution is to attach these files to a page which has the sole purpose of having the attachment. This is kind of awkward.
> JSPWiki should have a mechanism (in JSPFilter?) which would load the file from the classpath. So for FreeMind the FreeMindPlugin.jar would additionally contain freemindbrowser.jar. The plugin would generate some markup that would make the Filter recognize that the parameter is to be loaded from classpath, e.g. <wiki:IncludeResource freemindbrowser.jar>
> I guess this could be done with a PageFilter, too, but the idea is to make installing plugins easier and having to add a filters.xml would be counterproductive, so the mechanism should go into core.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.