[RFC][icedtea-web] Add ability to check for use of jnlp_href outside of PluginBridge
Deepak Bhole
dbhole at redhat.com
Tue Feb 21 11:18:03 PST 2012
* Danesh Dadachanji <ddadacha at redhat.com> [2012-02-02 12:29]:
> Hi,
>
> Attached is the patch that will be needed to check for whether or
> not jnlp_href is used. Applets using jnlp_href that have multiple
> signed jars will need to be checked that there is one common signer.
> Hence we need to know if jnlp_href was used!
>
> Okay for HEAD and 1.2?
>
> ChangeLog:
>
> +2012-02-02 Danesh Dadachanji <ddadacha at redhat.com>
> +
> + Add ability to check for jnlp_href use outside of PluginBridge.
> + * netx/net/sourceforge/jnlp/PluginBridge.java
> + (PluginBridge): New boolean useJNLPHref is set if jnlp_href is used.
> + (useJNLPHref): New getter method, returns boolean useJNLPHref.
> +
>
Looks good. Okay for both.
Cheers,
Deepak
>
> Regards,
> Danesh
> diff --git a/netx/net/sourceforge/jnlp/PluginBridge.java b/netx/net/sourceforge/jnlp/PluginBridge.java
> --- a/netx/net/sourceforge/jnlp/PluginBridge.java
> +++ b/netx/net/sourceforge/jnlp/PluginBridge.java
> @@ -44,6 +44,7 @@ public class PluginBridge extends JNLPFi
> private boolean usePack;
> private boolean useVersion;
> private boolean codeBaseLookup;
> + private boolean useJNLPHref;
>
> public PluginBridge(URL codebase, URL documentBase, String jar, String main,
> int width, int height, Hashtable<String, String> atts,
> @@ -56,6 +57,7 @@ public class PluginBridge extends JNLPFi
> this.atts = atts;
>
> if (atts.containsKey("jnlp_href")) {
> + useJNLPHref = true;
> try {
> URL jnlp = new URL(codeBase.toExternalForm() + atts.get("jnlp_href"));
> JNLPFile jnlpFile = new JNLPFile(jnlp, null, false, JNLPRuntime.getDefaultUpdatePolicy(), this.codeBase);
> @@ -80,6 +82,7 @@ public class PluginBridge extends JNLPFi
> } else {
> // Should we populate this list with applet attribute tags?
> info = new ArrayList<InformationDesc>();
> + useJNLPHref = false;
> }
>
> // also, see if cache_archive is specified
> @@ -172,6 +175,10 @@ public class PluginBridge extends JNLPFi
> return codeBaseLookup;
> }
>
> + public boolean useJNLPHref() {
> + return useJNLPHref;
> + }
> +
> /**
> * {@inheritdoc }
> */
More information about the distro-pkg-dev
mailing list