You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@pivot.apache.org by seth rosen <se...@gmail.com> on 2010/07/28 16:56:13 UTC
Problem deploying pivot applet
I developed a simple pivot app in eclipse. It works perfectly when run as an
applet from within eclipse but when deploying it in an html page I get the
following error:
access denied (java.io.FilePermission <FilePath> read)
My applet code is:
<applet code="org.apache.pivot.wtk.BrowserApplicationContext$HostApplet"
> archive="lib/pivot-core-1.5.jar,lib/pivot-wtk-1.5.jar,lib/pivot-wtk-terra-1.5.jar,lib/pivot-tutorials-1.5.jar"
width="460" height="480">
<param name="application_class_name" value="ClassName">
</applet>
Thanks for the help
Seth
Re: Problem deploying pivot applet
Posted by Greg Brown <gk...@mac.com>.
You need to sign any JARs whose code path may request access to a privileged operation. The easiest thing is to simply sign all JARs used by your app.
G
On Jul 29, 2010, at 11:51 AM, seth rosen wrote:
> Thank You Greg ad Ken,
>
> I thought this might be the problem but I was under the impression that it was the Pivot HostApplet jar that needed to be signed.
>
> Do I need to sign the pivot jars (lib/pivot-core-1.5.jar,lib/pivot-wtk-1.5.jar,lib/pivot-wtk-terra-1.5.jar,lib/pivot-tutorials-1.5.jar)?
>
> Do I need to add my class, that is passed as a parameter to the pivot HostApplet, to a signed jar?
>
> Thanks for the help
> Seth
>
>
> On Thu, Jul 29, 2010 at 8:32 AM, Greg Brown <gk...@mac.com> wrote:
> You can also use Ant for this:
>
> http://ant.apache.org/manual/Tasks/signjar.html
>
> In fact, this is how we sign the demo and tutorial JARs.
>
> G
>
> On Jul 28, 2010, at 9:11 PM, kenjiang@sz.murata.com.cn wrote:
>
> > Hi Rosen,
> >
> > You need sign you JAR for the FilePermission if you want deploy it by
> > applet.
> >
> > Below tool is provide by JDK.you can find it in %java_home/bin
> > KEYTOOL
> > Jarsigner
> >
> >
> > Best regards,
> > Ken Jiang
> >
> > *******************************************
> > Murata Electronics Trading (Shenzhen) Co.,Ltd
> > Tel:86-755-82847251
> > E-mail:kenjiang@sz.murata.com.cn
> > *******************************************
> >
> >
> >
> > From: seth rosen <se...@gmail.com>
> >
> > To: user <us...@pivot.apache.org>
> >
> > Date: 07/28/2010 22:57
> >
> > Subject: Problem deploying pivot applet
> >
> >
> >
> >
> >
> >
> > I developed a simple pivot app in eclipse. It works perfectly when run as
> > an applet from within eclipse but when deploying it in an html page I get
> > the following error:
> >
> > access denied (java.io.FilePermission <FilePath> read)
> >
> > My applet code is:
> >
> > <applet
> > code="org.apache.pivot.wtk.BrowserApplicationContext$HostApplet"
> >
> > archive="lib/pivot-core-1.5.jar,lib/pivot-wtk-1.5.jar,lib/pivot-wtk-terra-1.5.jar,lib/pivot-tutorials-1.5.jar"
> > width="460" height="480">
> > <param name="application_class_name" value="ClassName">
> > </applet>
> >
> > Thanks for the help
> > Seth
> >
>
>
Re: Problem deploying pivot applet
Posted by seth rosen <se...@gmail.com>.
Thank You Greg ad Ken,
I thought this might be the problem but I was under the impression that it
was the Pivot HostApplet jar that needed to be signed.
Do I need to sign the pivot jars (
lib/pivot-core-1.5.jar,lib/pivot-wtk-1.5.jar,lib/pivot-wtk-terra-1.5.jar,lib/pivot-tutorials-1.5.jar
)?
Do I need to add my class, that is passed as a parameter to the pivot
HostApplet, to a signed jar?
Thanks for the help
Seth
On Thu, Jul 29, 2010 at 8:32 AM, Greg Brown <gk...@mac.com> wrote:
> You can also use Ant for this:
>
> http://ant.apache.org/manual/Tasks/signjar.html
>
> In fact, this is how we sign the demo and tutorial JARs.
>
> G
>
> On Jul 28, 2010, at 9:11 PM, kenjiang@sz.murata.com.cn wrote:
>
> > Hi Rosen,
> >
> > You need sign you JAR for the FilePermission if you want deploy it by
> > applet.
> >
> > Below tool is provide by JDK.you can find it in %java_home/bin
> > KEYTOOL
> > Jarsigner
> >
> >
> > Best regards,
> > Ken Jiang
> >
> > *******************************************
> > Murata Electronics Trading (Shenzhen) Co.,Ltd
> > Tel:86-755-82847251
> > E-mail:kenjiang@sz.murata.com.cn <E-...@sz.murata.com.cn>
> > *******************************************
> >
> >
> >
> > From: seth rosen <se...@gmail.com>
> >
> > To: user <us...@pivot.apache.org>
> >
> > Date: 07/28/2010 22:57
> >
> > Subject: Problem deploying pivot applet
> >
> >
> >
> >
> >
> >
> > I developed a simple pivot app in eclipse. It works perfectly when run as
> > an applet from within eclipse but when deploying it in an html page I get
> > the following error:
> >
> > access denied (java.io.FilePermission <FilePath> read)
> >
> > My applet code is:
> >
> > <applet
> > code="org.apache.pivot.wtk.BrowserApplicationContext$HostApplet"
> >
> >
> archive="lib/pivot-core-1.5.jar,lib/pivot-wtk-1.5.jar,lib/pivot-wtk-terra-1.5.jar,lib/pivot-tutorials-1.5.jar"
> > width="460" height="480">
> > <param name="application_class_name" value="ClassName">
> > </applet>
> >
> > Thanks for the help
> > Seth
> >
>
>
Re: Problem deploying pivot applet
Posted by Greg Brown <gk...@mac.com>.
You can also use Ant for this:
http://ant.apache.org/manual/Tasks/signjar.html
In fact, this is how we sign the demo and tutorial JARs.
G
On Jul 28, 2010, at 9:11 PM, kenjiang@sz.murata.com.cn wrote:
> Hi Rosen,
>
> You need sign you JAR for the FilePermission if you want deploy it by
> applet.
>
> Below tool is provide by JDK.you can find it in %java_home/bin
> KEYTOOL
> Jarsigner
>
>
> Best regards,
> Ken Jiang
>
> *******************************************
> Murata Electronics Trading (Shenzhen) Co.,Ltd
> Tel:86-755-82847251
> E-mail:kenjiang@sz.murata.com.cn
> *******************************************
>
>
>
> From: seth rosen <se...@gmail.com>
>
> To: user <us...@pivot.apache.org>
>
> Date: 07/28/2010 22:57
>
> Subject: Problem deploying pivot applet
>
>
>
>
>
>
> I developed a simple pivot app in eclipse. It works perfectly when run as
> an applet from within eclipse but when deploying it in an html page I get
> the following error:
>
> access denied (java.io.FilePermission <FilePath> read)
>
> My applet code is:
>
> <applet
> code="org.apache.pivot.wtk.BrowserApplicationContext$HostApplet"
>
> archive="lib/pivot-core-1.5.jar,lib/pivot-wtk-1.5.jar,lib/pivot-wtk-terra-1.5.jar,lib/pivot-tutorials-1.5.jar"
> width="460" height="480">
> <param name="application_class_name" value="ClassName">
> </applet>
>
> Thanks for the help
> Seth
>
Re: Problem deploying pivot applet
Posted by ke...@sz.murata.com.cn.
Hi Rosen,
You need sign you JAR for the FilePermission if you want deploy it by
applet.
Below tool is provide by JDK.you can find it in %java_home/bin
KEYTOOL
Jarsigner
Best regards,
Ken Jiang
*******************************************
Murata Electronics Trading (Shenzhen) Co.,Ltd
Tel:86-755-82847251
E-mail:kenjiang@sz.murata.com.cn
*******************************************
From: seth rosen <se...@gmail.com>
To: user <us...@pivot.apache.org>
Date: 07/28/2010 22:57
Subject: Problem deploying pivot applet
I developed a simple pivot app in eclipse. It works perfectly when run as
an applet from within eclipse but when deploying it in an html page I get
the following error:
access denied (java.io.FilePermission <FilePath> read)
My applet code is:
<applet
code="org.apache.pivot.wtk.BrowserApplicationContext$HostApplet"
archive="lib/pivot-core-1.5.jar,lib/pivot-wtk-1.5.jar,lib/pivot-wtk-terra-1.5.jar,lib/pivot-tutorials-1.5.jar"
width="460" height="480">
<param name="application_class_name" value="ClassName">
</applet>
Thanks for the help
Seth