Re: java.security.AccessControlException opening from an applet

Hi again John,

I have checked the program using the URL class and works fine, no secutity problems (I also worked with attribute debugLeaks commented at HTTPRandomAccessFile3.java). This is the method I have changed at N3iosp.java (from line 87):

 
//////////////////////////////////////////////////////////////////////////////////////
 // read existing file

public void open(ucar.unidata.io.RandomAccessFile raf, ucar.nc2.NetcdfFile ncfile,
                  ucar.nc2.util.CancelTask cancelTask) throws IOException {
   this.raf = raf;
   this.ncfile = ncfile;

if(!raf.getClass().getName().equals("ucar.unidata.io.http.HTTPRandomAccessFile3")){     File file = new File( raf.getLocation());     if (file.exists())       lastModified = file.lastModified(); } else {     
try{      URL url = new URL(raf.getLocation());     HttpURLConnection con = (HttpURLConnection)url.openConnection();     con.connect();   lastModified = con.getLastModified();   con.disconnect();   }   catch 
(Exception e)   {   // Do nothing   } }Regards,Santi----- Original Message -----From: "S Santos" <s.santos@xxxxxxxxx>To: "John Caron" <caron@xxxxxxxxxxxxxxxx>Cc: 
<netcdf-java@xxxxxxxxxxxxxxxx>; <support-netcdf-java@xxxxxxxxxxxxxxxx>Sent: Wednesday, April 26, 2006 1:28 PMSubject: Re: java.security.AccessControlException opening from an applet> Hi John,>>  I 
have done some tests to check if it is a problem of my server:>> 1-----> I have executed the code granting the read access and the appletshowed the same Exception:>> java.lang.NoSuchFieldError: 
debugLeaks atucar.unidata.io.http.HTTPRandomAccessFile3.<init>(HTTPRandomAccessFile3.java:91)> atucar.unidata.io.http.HTTPRandomAccessFile3.<init>(HTTPRandomAccessFile3.java:53)> at 
ucar.nc2.NetcdfFile.open(NetcdfFile.java:207)> at ucar.nc2.NetcdfFile.open(NetcdfFile.java:167)> at ucar.nc2.NetcdfFile.open(NetcdfFile.java:151)> 
atsoftiam.services.ui.dataAnalysis.util.NetCDFReader.<init>(NetCDFReader.java:42)> atsoftiam.services.ui.dataAnalysis.engine.SoftiamRepresentation.setNetCDFFile(SoftiamRepresentation.java:130)> 
atsoftiam.services.ui.dataAnalysis.tool.SoftiamAnalyzer.loadURL(SoftiamAnalyzer.java:630)> atsoftiam.services.ui.dataAnalysis.tool.SoftiamAnalyzerApplet.init(SoftiamAnalyzerApplet.java:39)> at 
sun.applet.AppletPanel.run(Unknown Source)> at java.lang.Thread.run(Unknown Source)> basic: Exception: java.lang.NoSuchFieldError: debugLeaks>> 2-------> delete the grant to read and recompile netCDF 
commenting thelines 91 and 190 at HTTPRandomAccessFile3.java. This doesn't affect to thebehaviour of the library because the protected attribute debugLeaks inRan

domAccessFile is set to false.>>                91: if (debugLeaks) openFiles.add( location);>                190: if (debugLeaks) openFiles.remove( location);>>                After executing the 
program I had a new security exception:>> java.security.AccessControlException: access denied(java.io.FilePermissionhttp:\localhost:8080\softiam-portal\users\e145\IPCC_ESM%20Magicc_SCM\magicc_out.nc 
read)> at java.security.AccessControlContext.checkPermission(Unknown Source)> at java.security.AccessController.checkPermission(Unknown Source)> at java.lang.SecurityManager.checkPermission(Unknown 
Source)> at java.lang.SecurityManager.checkRead(Unknown Source)> at java.io.File.exists(Unknown Source)> at ucar.nc2.N3iosp.open(N3iosp.java:93)> at 
ucar.nc2.NetcdfFile.<init>(NetcdfFile.java:793)> at ucar.nc2.NetcdfFile.open(NetcdfFile.java:344)> at ucar.nc2.NetcdfFile.open(NetcdfFile.java:222)> at 
ucar.nc2.NetcdfFile.open(NetcdfFile.java:167)> at ucar.nc2.NetcdfFile.open(NetcdfFile.java:151)> atsoftiam.services.ui.dataAnalysis.util.NetCDFReader.<init>(NetCDFReader.java:42)> 
atsoftiam.services.ui.dataAnalysis.engine.SoftiamRepresentation.setNetCDFFile(SoftiamRepresentation.java:130)> atsoftiam.services.ui.dataAnalysis.tool.SoftiamAnalyzer.loadURL(SoftiamAnalyzer.java:630)> 
atsoftiam.services.ui.dataAnalysis.tool.SoftiamAnalyzerApplet.init(SoftiamAnalyzerApplet.java:39)> at sun.applet.AppletPanel.run(Unknown Source)> at java.lang.Thread.run(Unknown Source)>>> 3 
----> Grant the read access again and recompile netCDF commenting thelines 91 and 190 at HTTPRandomAccessFile3.java. This doesn't affect to thebehaviour of the library because the protected attribute 
debugLeaks inRandomAccessFile is set to false.>>                91: if (debugLeaks) openFiles.add( location);>                190: if (debugLeaks) openFiles.remove( location);>>            The 
applet worked perfectly!!!>>> My conclusions:>>    - The server support Accept-Ranges header>>    - There is a bug at netcdf-2.2.14.jar library with debugLeaks protectedattribute of Rand

omAccessFile when you work with HTTPRandomAccessFile3>>    - It isn't possible to load from an applet withucar.nc2.NetcdfFile.open() using a url allowed by the sandbox. This waspossible in previous versions of netcdf. This could be caused by the usingof the class File to check the existence of the file (the 
applet see thatlike a local file and throws a security exception). If you use the class URLwhen raf is an HTTPRandomAccessFile3 to check this, probably all will workfine with applets (See lines 92 to 94 at N3iosp.java). I'll check that.>> Regards,>> Santi> ----- Original Message -----> From: 
"John Caron" <caron@xxxxxxxxxxxxxxxx>> To: "S Santos" <s.santos@xxxxxxxxx>> Cc: <netcdf-java@xxxxxxxxxxxxxxxx>; <support-netcdf-java@xxxxxxxxxxxxxxxx>> Sent: Tuesday, April 25, 2006 7:03 PM> Subject: Re: java.security.AccessControlException opening from an 
applet>>>> It appears that you want to use HTTP to access a netcdf file.>> The main thing that goes wrong here is that the HTTP server doesntsupport byte ranges.>> Look at the server headers in the response and see if "Accept Range" ispresent.>> Your URL is local, so I cant 
check for you.>>>>>> S Santos wrote:>>> Hi All,>>>>>> As you told me I have decoded the URL so know I'm accessing tohttp://localhost:8080/softiam-portal/users/e145/IPCC_ESM%20Magicc_SCM/magicc_out.nc. The security problems have been solved, but now the program isthrowing 
another exception:>>>>>> java.lang.NoSuchFieldError: debugLeaks>>> atucar.unidata.io.http.HTTPRandomAccessFile3.<init>(HTTPRandomAccessFile3.java:91) atucar.unidata.io.http.HTTPRandomAccessFile3.<init>(HTTPRandomAccessFile3.java:53) at 
ucar.nc2.NetcdfFile.open(NetcdfFile.java:207)>>> at ucar.nc2.NetcdfFile.open(NetcdfFile.java:167)>>> at ucar.nc2.NetcdfFile.open(NetcdfFile.java:151)>>> atsoftiam.services.ui.dataAnalysis.util.NetCDFReader.<init>(NetCDFReader.java:42) 
atsoftiam.services.ui.dataAnalysis.engine.SoftiamRepresentation.setNetCDFFile(SoftiamRepresentation.java:130) atsoftiam.services.ui.dataAnalysis.tool.SoftiamAnalyzer.load

URL(SoftiamAnalyzer.java:630) atsoftiam.services.ui.dataAnalysis.tool.SoftiamAnalyzerApplet.init(SoftiamAnalyzerApplet.java:39) at sun.applet.AppletPanel.run(Unknown Source)>>> at java.lang.Thread.run(Unknown Source)>>> basic: Exception: java.lang.NoSuchFieldError: 
debugLeaks>>>>>> Here is a complete list of the stack and threads stack:>>>>>>>>> basic: Registered modality listener>>> basic: Referencing classloader: sun.plugin.ClassLoaderInfo@11d3226,refcount=1>>> basic: Added progress listener: 
sun.plugin.util.GrayBoxPainter@17082d8>>> basic: Loading applet ...>>> basic: Initializing applet ...>>> basic: Starting applet ...>>> network: Connectinghttp://localhost:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/applet.GIF with 
proxy=DIRECT>>> network: Connectinghttp://localhost:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/applet.GIF with cookie"JSESSIONID=EB35CD966F830B95641DDA54D25CE7F2">>> basic: 
Loadinghttp://localhost:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/applet.GIF from cache>>> network: Connectinghttp://localhost:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/graph.GIF with proxy=DIRECT>>> network: 
Connectinghttp://localhost:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/graph.GIF with cookie"JSESSIONID=EB35CD966F830B95641DDA54D25CE7F2">>> basic: Loadinghttp://localhost:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/graph.GIF from 
cache>>> network: Connectinghttp://localhost:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/iso.GIF with proxy=DIRECT>>> network: Connectinghttp://localhost:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/iso.GIF with cookie 
"JSESSIONID=EB35CD966F830B95641DDA54D25CE7F2">>> basic: Loadinghttp://localhost:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/iso.GIF from cache>>> network: Connectinghttp://localhost:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/i

mages/color.GIF with proxy=DIRECT>>> network: Connectinghttp://localhost:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/color.GIF with cookie"JSESSIONID=EB35CD966F830B95641DDA54D25CE7F2">>> basic: 
Loadinghttp://localhost:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/color.GIF from cache>>> network: Connectinghttp://localhost:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/animation.GIF with 
proxy=DIRECT>>> network: Connectinghttp://localhost:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/animation.GIF with cookie"JSESSIONID=EB35CD966F830B95641DDA54D25CE7F2">>> basic: 
Loadinghttp://localhost:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/animation.GIF from cache>>> network: Connectinghttp://localhost:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/legend.GIF with 
proxy=DIRECT>>> network: Connectinghttp://localhost:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/legend.GIF with cookie"JSESSIONID=EB35CD966F830B95641DDA54D25CE7F2">>> basic: 
Loadinghttp://localhost:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/legend.GIF from cache>>> network: Connectinghttp://localhost:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/console.GIF with 
proxy=DIRECT>>> network: Connectinghttp://localhost:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/console.GIF with cookie"JSESSIONID=EB35CD966F830B95641DDA54D25CE7F2">>> basic: 
Loadinghttp://localhost:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/console.GIF from cache>>> network: Connectinghttp://localhost:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/table.GIF with 
proxy=DIRECT>>> network: Connectinghttp://localhost:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/table.GIF with cookie"JSESSIONID=EB35CD966F830B95641DDA54D25CE7F2">>> basic: 
Loadinghttp://localhost:8080/softiam-portal/softiam/se

rvices/ui/dataAnalysis/tool/data/images/table.GIF from cache>>> network: Connectinghttp://localhost:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/add.GIF with proxy=DIRECT>>> network: 
Connectinghttp://localhost:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/add.GIF with cookie "JSESSIONID=EB35CD966F830B95641DDA54D25CE7F2">>> basic: 
Loadinghttp://localhost:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/add.GIF from cache>>> network: Connectinghttp://localhost:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/remove.GIF with 
proxy=DIRECT>>> network: Connectinghttp://localhost:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/remove.GIF with cookie"JSESSIONID=EB35CD966F830B95641DDA54D25CE7F2">>> basic: 
Loadinghttp://localhost:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/remove.GIF from cache>>> network: Connectinghttp://localhost:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/tyndall.GIF with 
proxy=DIRECT>>> network: Connectinghttp://localhost:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/tyndall.GIF with cookie"JSESSIONID=EB35CD966F830B95641DDA54D25CE7F2">>> basic: 
Loadinghttp://localhost:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/tyndall.GIF from cache>>> network: Connecting socket://localhost:8080 with proxy=DIRECT>>> java.lang.NoSuchFieldError: debugLeaks>>> 
atucar.unidata.io.http.HTTPRandomAccessFile3.<init>(HTTPRandomAccessFile3.java:91) atucar.unidata.io.http.HTTPRandomAccessFile3.<init>(HTTPRandomAccessFile3.java:53) at ucar.nc2.NetcdfFile.open(NetcdfFile.java:207)>>> at 
ucar.nc2.NetcdfFile.open(NetcdfFile.java:167)>>> at ucar.nc2.NetcdfFile.open(NetcdfFile.java:151)>>> atsoftiam.services.ui.dataAnalysis.util.NetCDFReader.<init>(NetCDFReader.java:42) 
atsoftiam.services.ui.dataAnalysis.engine.SoftiamRepresentation.setNetCDFFile(SoftiamRepresentation.java:130) atsoftiam.services.ui.dataAnalysis.tool.Soft

iamAnalyzer.loadURL(SoftiamAnalyzer.java:630) atsoftiam.services.ui.dataAnalysis.tool.SoftiamAnalyzerApplet.init(SoftiamAnalyzerApplet.java:39) at sun.applet.AppletPanel.run(Unknown Source)>>> at java.lang.Thread.run(Unknown Source)>>> basic: Exception: java.lang.NoSuchFieldError: debugLeaks>>> Dump thread stack ...>>> ---------------------------------------------------->>> Full thread dump Java HotSpot(TM) Client VM (1.5.0_06-b05 
mixed mode):>>>>>> "Thread-46" prio=4 tid=0x027949d8 nid=0x64c in Object.wait()[0x1020f000..0x1020fc68]>>> at java.lang.Object.wait(Native Method)>>> - waiting on <0x0594eef0> (a visad.java2d.VisADCanvasJ2D)>>> at java.lang.Object.wait(Unknown Source)>>> at visad.java2d.VisADCanvasJ2D.run(VisADCanvasJ2D.java:365)>>> - locked <0x0594eef0> (a visad.java2d.VisADCanvasJ2D)>>> at 
java.lang.Thread.run(Unknown Source)>>>>>> "AWT-EventQueue-6" prio=4 tid=0x02d0b728 nid=0x7d0 in Object.wait()[0x10ecf000..0x10ecfce8]>>> at java.lang.Object.wait(Native Method)>>> at java.lang.Object.wait(Unknown Source)>>> at java.awt.EventQueue.getNextEvent(Unknown Source)>>> - locked <0x0594fa38> (a java.awt.EventQueue)>>> at java.awt.EventDispatchThread.pumpOneEventForHierarchy(Unknown 
Source)>>> at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)>>> at java.awt.EventDispatchThread.pumpEvents(Unknown Source)>>> at java.awt.EventDispatchThread.pumpEvents(Unknown Source)>>> at java.awt.EventDispatchThread.run(Unknown Source)>>>>>> "TimerQueue" daemon prio=4 tid=0x0290ab18 nid=0xc58 in Object.wait()[0x1079f000..0x1079f9e8]>>> at java.lang.Object.wait(Native 
Method)>>> - waiting on <0x0594fb40> (a javax.swing.TimerQueue)>>> at javax.swing.TimerQueue.run(Unknown Source)>>> - locked <0x0594fb40> (a javax.swing.TimerQueue)>>> at java.lang.Thread.run(Unknown Source)>>>>>> "TimerQueue" daemon prio=6 tid=0x02ad0540 nid=0x8f0 in Object.wait()[0x022af000..0x022afae8]>>> at java.lang.Object.wait(Native Method)>>> - waiting on <0x058ebcb8> 
(a javax.swing.TimerQueue)>>> at javax.swing.TimerQueue.run(Unknow

n Source)>>> - locked <0x058ebcb8> (a javax.swing.TimerQueue)>>> at java.lang.Thread.run(Unknown Source)>>>>>> "J3D-Renderer-1" prio=4 tid=0x02d14a20 nid=0xef4 in Object.wait()[0x11eef000..0x11eefbe8]>>> at java.lang.Object.wait(Native Method)>>> - waiting on <0x05809180> (a javax.media.j3d.Renderer)>>> at java.lang.Object.wait(Unknown Source)>>> at javax.media.j3d.J3dThread.runMonitor(Unknown Source)>>> - locked 
<0x05809180> (a javax.media.j3d.Renderer)>>> at javax.media.j3d.J3dThread.run(Unknown Source)>>>>>> "J3D-MasterControl-1" prio=4 tid=0x02c55710 nid=0xea4 in Object.wait()[0x11def000..0x11defc68]>>> at java.lang.Object.wait(Native Method)>>> - waiting on <0x05809310> (a javax.media.j3d.MasterControl)>>> at java.lang.Object.wait(Unknown Source)>>> at javax.media.j3d.MasterControl.runMonitor(Unknown Source)>>> - locked <0x05809310> (a 
javax.media.j3d.MasterControl)>>> at javax.media.j3d.MasterControl.doWork(Unknown Source)>>> at javax.media.j3d.MasterControlThread.run(Unknown Source)>>>>>> "J3D-TimerThread" prio=4 tid=0x02c5a0c8 nid=0xea0 in Object.wait()[0x11cef000..0x11cefce8]>>> at java.lang.Object.wait(Native Method)>>> - waiting on <0x05809548> (a javax.media.j3d.TimerThread)>>> at java.lang.Object.wait(Unknown Source)>>> at javax.media.j3d.TimerThread.runMonitor(Unknown 
Source)>>> - locked <0x05809548> (a javax.media.j3d.TimerThread)>>> at javax.media.j3d.TimerThread.run(Unknown Source)>>>>>> "J3D-RenderingAttributesStructureUpdateThread" prio=4 tid=0x02c608e8nid=0x264 in Object.wait() [0x11bef000..0x11befd68]>>> at java.lang.Object.wait(Native Method)>>> - waiting on <0x058095b8> (a javax.media.j3d.StructureUpdateThread)>>> at java.lang.Object.wait(Unknown Source)>>> at 
javax.media.j3d.J3dThread.runMonitor(Unknown Source)>>> - locked <0x058095b8> (a javax.media.j3d.StructureUpdateThread)>>> at javax.media.j3d.J3dThread.run(Unknown Source)>>>>>> "TimerQueue" daemon prio=6 tid=0x02ca09b8 nid=0x9fc in Object.wait()[0x10acf000..0x10acfce8]>>> at java.lang.Object.wait(Native Method)>>> - waiting on <0x05

7de130> (a javax.swing.TimerQueue)>>> at javax.swing.TimerQueue.run(Unknown Source)>>> - locked <0x057de130> (a javax.swing.TimerQueue)>>> at java.lang.Thread.run(Unknown Source)>>>>>> "ConsoleWriterThread" daemon prio=6 tid=0x027b1008 nid=0x898 inObject.wait() [0x0ffbf000..0x0ffbfd68]>>> at java.lang.Object.wait(Native Method)>>> - waiting 
on <0x056b7cd0> (a java.lang.Object)>>> at java.lang.Object.wait(Unknown Source)>>> atcom.sun.deploy.util.ConsoleTraceListener$ConsoleWriterThread.run(UnknownSource)>>> - locked <0x056b7cd0> (a java.lang.Object)>>>>>> "AWT-EventQueue-1" prio=6 tid=0x02705ba8 nid=0xeb8 runnable[0x1010f000..0x1010fc68]>>> at 
sun.plugin.JavaRunTime.dumpAllStacks(Native Method)>>> at sun.plugin.util.PluginConsoleController.dumpAllStacks(Unknown Source)>>> at com.sun.deploy.util.ConsoleWindow$1.actionPerformed(Unknown Source)>>> at javax.swing.JComponent$ActionStandin.actionPerformed(Unknown Source)>>> at javax.swing.SwingUtilities.notifyAction(Unknown Source)>>> at 
javax.swing.JComponent.processKeyBinding(Unknown Source)>>> at javax.swing.KeyboardManager.fireBinding(Unknown Source)>>> at javax.swing.KeyboardManager.fireKeyboardAction(Unknown Source)>>> at javax.swing.JComponent.processKeyBindingsForAllComponents(UnknownSource)>>> at javax.swing.JComponent.processKeyBindings(Unknown Source)>>> at 
javax.swing.JComponent.processKeyEvent(Unknown Source)>>> at java.awt.Component.processEvent(Unknown Source)>>> at java.awt.Container.processEvent(Unknown Source)>>> at java.awt.Component.dispatchEventImpl(Unknown Source)>>> at java.awt.Container.dispatchEventImpl(Unknown Source)>>> at java.awt.Component.dispatchEvent(Unknown Source)>>> at 
java.awt.KeyboardFocusManager.redispatchEvent(Unknown Source)>>> at java.awt.DefaultKeyboardFocusManager.dispatchKeyEvent(Unknown Source)>>> at java.awt.DefaultKeyboardFocusManager.preDispatchKeyEvent(UnknownSource)>>> at java.awt.DefaultKeyboardFocusManager.typeAheadAssertions(UnknownSource)>>> at java.awt.DefaultKeyboardFocusManager.dispatchEvent(Unknown Source)>>> at

java.awt.Component.dispatchEventImpl(Unknown Source)>>> at java.awt.Container.dispatchEventImpl(Unknown Source)>>> at java.awt.Window.dispatchEventImpl(Unknown Source)>>> at java.awt.Component.dispatchEvent(Unknown Source)>>> at java.awt.EventQueue.dispatchEvent(Unknown Source)>>> at java.awt.EventDispatchThread.pumpOneEventForHierarchy(Unknown Source)>>> at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown 
Source)>>> at java.awt.EventDispatchThread.pumpEvents(Unknown Source)>>> at java.awt.EventDispatchThread.pumpEvents(Unknown Source)>>> at java.awt.EventDispatchThread.run(Unknown Source)>>>>>> "Thread-6" prio=6 tid=0x02aa1428 nid=0xab8 runnable[0x00000000..0x0fdbf7f8]>>>>>> "AWT-EventQueue-0" prio=6 tid=0x02a8ee40 nid=0xebc in Object.wait()[0x0febf000..0x0febfd68]>>> at 
java.lang.Object.wait(Native Method)>>> at java.lang.Object.wait(Unknown Source)>>> at java.awt.EventQueue.getNextEvent(Unknown Source)>>> - locked <0x05666f10> (a java.awt.EventQueue)>>> at java.awt.EventDispatchThread.pumpOneEventForHierarchy(Unknown Source)>>> at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)>>> at java.awt.EventDispatchThread.pumpEvents(Unknown Source)>>> at 
java.awt.EventDispatchThread.pumpEvents(Unknown Source)>>> at java.awt.EventDispatchThread.run(Unknown Source)>>>>>> "traceMsgQueueThread" daemon prio=6 tid=0x02a7ee08 nid=0xc0c inObject.wait() [0x0f9ef000..0x0f9efa68]>>> at java.lang.Object.wait(Native Method)>>> - waiting on <0x056adbe0> (a java.util.ArrayList)>>> at java.lang.Object.wait(Unknown Source)>>> at 
com.sun.deploy.util.Trace$TraceMsgQueueChecker.run(Unknown Source)>>> - locked <0x056adbe0> (a java.util.ArrayList)>>> at java.lang.Thread.run(Unknown Source)>>>>>> "AWT-Windows" daemon prio=6 tid=0x02a70d00 nid=0xf78 runnable[0x0f7ef000..0x0f7efae8]>>> at sun.awt.windows.WToolkit.eventLoop(Native Method)>>> at sun.awt.windows.WToolkit.run(Unknown Source)>>> at java.lang.Thread.run(Unknown 
Source)>>>>>> "AWT-Shutdown" prio=6 tid=0x02a70958 nid=0xed8 in Object.wait()[0x0f6ef000..0

x0f6efb68]>>> at java.lang.Object.wait(Native Method)>>> - waiting on <0x05672288> (a java.lang.Object)>>> at java.lang.Object.wait(Unknown Source)>>> at sun.awt.AWTAutoShutdown.run(Unknown Source)>>> - locked <0x05672288> (a java.lang.Object)>>> at java.lang.Thread.run(Unknown Source)>>>>>> "Java2D Disposer" daemon prio=10 tid=0x02a69de0 nid=0x4e0 inObject.wait() [0x0f5ef000..0x0f5efbe8]>>> at java.lang.Object.wait(Native Method)>>> - waiting on 
<0x05672310> (a java.lang.ref.ReferenceQueue$Lock)>>> at java.lang.ref.ReferenceQueue.remove(Unknown Source)>>> - locked <0x05672310> (a java.lang.ref.ReferenceQueue$Lock)>>> at java.lang.ref.ReferenceQueue.remove(Unknown Source)>>> at sun.java2d.Disposer.run(Unknown Source)>>> at java.lang.Thread.run(Unknown Source)>>>>>> "Low Memory Detector" daemon prio=6 tid=0x029e0238 nid=0xc80 runnable[0x00000000..0x00000000]>>>>>> "CompilerThread0" daemon 
prio=10 tid=0x02002198 nid=0xb1c waiting oncondition [0x00000000..0x0f1ef6cc]>>>>>> "Signal Dispatcher" daemon prio=10 tid=0x029de548 nid=0x26c runnable[0x00000000..0x00000000]>>>>>> "Finalizer" daemon prio=8 tid=0x029d5bf8 nid=0xdc8 in Object.wait()[0x0efef000..0x0efefa68]>>> at java.lang.Object.wait(Native Method)>>> - waiting on <0x056724b8> (a java.lang.ref.ReferenceQueue$Lock)>>> at java.lang.ref.ReferenceQueue.remove(Unknown Source)>>> - locked 
<0x056724b8> (a java.lang.ref.ReferenceQueue$Lock)>>> at java.lang.ref.ReferenceQueue.remove(Unknown Source)>>> at java.lang.ref.Finalizer$FinalizerThread.run(Unknown Source)>>>>>> "Reference Handler" daemon prio=10 tid=0x029d4880 nid=0xee8 inObject.wait() [0x025ef000..0x025efae8]>>> at java.lang.Object.wait(Native Method)>>> - waiting on <0x05672538> (a java.lang.ref.Reference$Lock)>>> at java.lang.Object.wait(Unknown Source)>>> at 
java.lang.ref.Reference$ReferenceHandler.run(Unknown Source)>>> - locked <0x05672538> (a java.lang.ref.Reference$Lock)>>>>>> "main" prio=6 tid=0x028f3370 nid=0xd68 runnable [0x00000000..0x0012eaa4]>>>>>> "VM Thread" prio=10 tid=0x02914050 nid=0xf14 runna

ble>>>>>> "VM Periodic Task Thread" prio=10 tid=0x029e1390 nid=0x930 waiting oncondition>>>>>> ---------------------------------------------------->>> Done.>>>>>>>>>>>> Many thanks,>>>>>> Santi>>>>>> ----- Original Message ----- From: "John Caron" <caron@xxxxxxxxxxxxxxxx>>>> To: "Tom Whittaker" <tomw@xxxxxxxxxxxxx>>>> Cc: "S Santos" <s.santos@xxxxxxxxx>; <netcdf-java@xxxxxxxxxxxxxxxx>;<support-netcdf-java@xxxxxxxxxxxxxxxx>>>> Sent: Tuesday, April 25, 2006 3:02 PM>>> Subject: Re: java.security.AccessControlException opening from an applet>>>>>>>>>> thanks tom, i didnt see that.>>>>>>>> it appears that your software is encoding the URL, you need to decodeit (or just dont encode it) 
before passing to NetcdfFile.open().>>>>>>>>>>>>>>>>>>>> Tom Whittaker wrote:>>>>>>>>> So, John, perhaps the "real" problem is related to this "filename">>>>> from the stack trace?>>>>>>>>>>http%3A%2F%2F139.222.100.25%3A8080%2Fsoftiam-portal%2Fusers%2Fe145%2FIPCC_ESM+Magicc_SCM%2Fmagicc_out.nc>>>>>>>>>> tom>>>>>>>>>> On 4/25/06, S Santos <s.santos@xxxxxxxxx> wrote:>>>>>>>>>>> Hi All,>>>>>>>>>>>> In this example the applet was loaded from a Tomcat server atlocalhost, so>>>>>> the applet is accesing to the server it was loaded from. Anyway, Itried an>>>>>> execution from a remote computer and the problem persists. Maybe thisis 
a>>>>>> problem of the JVM (I'm using the latest one 1.5.0_06-b05) but thestrange>>>>>> point is that using netcdf 2.1.10 all works fine and using the lateststable>>>>>> version (2.2.14) the Exception is throwed.>>>>>>>>>>>> Here is the output with trace level five and a the thread stack dump>>>>>>>>>>>>>>>>>> Trace level set to 5: all ... completed.>>>>>> basic: Stopping applet ...>>>>>> basic: Removed progress listener:sun.plugin.util.GrayBoxPainter@bf7190>>>>>> basic: Finding information ...>>>>>> basic: Releasing classloader: sun.plugin.ClassLoaderInfo@7bb290,refcount=0>>>>>> basic: Caching classloader: sun.plugin.ClassLoaderInfo@7bb290>>>>>> basic: Current classloader cache size: 
1>>>>>> basic: Done ...>>>>>> b

asic: Joining applet thread ...>>>>>> basic: Destroying applet ...>>>>>> basic: Disposing applet ...>>>>>> basic: Quiting applet ...>>>>>> basic: Joined applet thread ...>>>>>> basic: Unregistered modality listener>>>>>> INFO: Tue 25-04-2006 10:24:17 < Scheduler#run: Thread "Thread-12" iswaking>>>>>> up after -1145957018322 milliseconds. Requested sleep time was: 60000>>>>>> milliseconds (1 minutes) > :OFNI>>>>>> INFO: Tue 25-04-2006 10:24:17 < Scheduler#reload: Update all>>>>>> ISchedulerManaged objects > :OFNI>>>>>> INFO: Tue 25-04-2006 10:24:17>>>>>>< 
--------------------------------------------------------------------------->>>>>>>>>>>> > :OFNI>>>>>> INFO: Tue 25-04-2006 10:24:17 < Scheduler#reload: Updating>>>>>> softiam.services.util.ConfigBean > :OFNI>>>>>> INFO: Tue 25-04-2006 10:24:17>>>>>>< --------------------------------------------------------------------------->>>>>>>>>>>> > :OFNI>>>>>> INFO: Tue 25-04-2006 10:24:17 < Scheduler#setUpdateInterval:UpdateInterval>>>>>> is being changed from 1 to 60 > :OFNI>>>>>> INFO: Tue 25-04-2006 10:24:17 < Scheduler#setUpdateInterval: Wakingup the>>>>>> Thread > :OFNI>>>>>> INFO: Tue 25-04-2006 10:24:17 < Scheduler#run: Thread 
"Thread-12" is>>>>>> sleeping for 60 minutes (at startup this will be 1 minutes untilresources>>>>>> are loaded) > :OFNI>>>>>> basic: Registered modality listener>>>>>> liveconnect: Invoking JS method: document>>>>>> liveconnect: Invoking JS method: URL>>>>>> basic: Referencing classloader: sun.plugin.ClassLoaderInfo@7bb290,>>>>>> refcount=1>>>>>> basic: Added progress listener: sun.plugin.util.GrayBoxPainter@893969>>>>>> basic: Loading applet ...>>>>>> basic: Initializing applet ...>>>>>> basic: Starting applet ...>>>>>> network: 
Connecting>>>>>>http://139.222.100.25:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/applet.GIF>>>>>> with proxy=DIRECT>>>>>> network: Connecting>>>>>>http://139.222.100.25:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/applet.GIF>>>>>> with cookie "JSESSIONID=4D2AFA25D

E6D6CEB3618E996D9227949">>>>>> basic: Loading>>>>>>http://139.222.100.25:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/applet.GIF>>>>>> from cache>>>>>> network: Connecting>>>>>>http://139.222.100.25:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/graph.GIF>>>>>> with proxy=DIRECT>>>>>> network: Connecting>>>>>>http://139.222.100.25:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/graph.GIF>>>>>> with cookie "JSESSIONID=4D2AFA25DE6D6CEB3618E996D9227949">>>>>> basic: 
Loading>>>>>>http://139.222.100.25:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/graph.GIF>>>>>> from cache>>>>>> network: Connecting>>>>>>http://139.222.100.25:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/iso.GIF>>>>>> with proxy=DIRECT>>>>>> network: Connecting>>>>>>http://139.222.100.25:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/iso.GIF>>>>>> with cookie "JSESSIONID=4D2AFA25DE6D6CEB3618E996D9227949">>>>>> basic: 
Loading>>>>>>http://139.222.100.25:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/iso.GIF>>>>>> from cache>>>>>> network: Connecting>>>>>>http://139.222.100.25:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/color.GIF>>>>>> with proxy=DIRECT>>>>>> network: Connecting>>>>>>http://139.222.100.25:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/color.GIF>>>>>> with cookie "JSESSIONID=4D2AFA25DE6D6CEB3618E996D9227949">>>>>> basic: 
Loading>>>>>>http://139.222.100.25:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/color.GIF>>>>>> from cache>>>>>> network: Connecting>>>>>>http://139.222.100.25:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/animation.GIF>>>>>> with proxy=DIRECT>>>>>> network: Connecting>>>>>>http://139.222.100.25:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/animation.GIF>>>>>> with cookie "JSESSIONID=4D2AFA25DE6D6CEB3618E996D9227949">>>>>> basic: Loading>>>

http://139.222.100.25:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/animation.GIF>>>>>> from cache>>>>>> network: Connecting>>>>>>http://139.222.100.25:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/legend.GIF>>>>>> with proxy=DIRECT>>>>>> network: Connecting>>>>>>http://139.222.100.25:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/legend.GIF>>>>>> with cookie "JSESSIONID=4D2AFA25DE6D6CEB3618E996D9227949">>>>>> basic: 
Loading>>>>>>http://139.222.100.25:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/legend.GIF>>>>>> from cache>>>>>> network: Connecting>>>>>>http://139.222.100.25:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/console.GIF>>>>>> with proxy=DIRECT>>>>>> network: Connecting>>>>>>http://139.222.100.25:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/console.GIF>>>>>> with cookie "JSESSIONID=4D2AFA25DE6D6CEB3618E996D9227949">>>>>> basic: 
Loading>>>>>>http://139.222.100.25:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/console.GIF>>>>>> from cache>>>>>> network: Connecting>>>>>>http://139.222.100.25:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/graph.GIF>>>>>> with proxy=DIRECT>>>>>> network: Connecting>>>>>>http://139.222.100.25:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/graph.GIF>>>>>> with cookie "JSESSIONID=4D2AFA25DE6D6CEB3618E996D9227949">>>>>> basic: 
Loading>>>>>>http://139.222.100.25:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/graph.GIF>>>>>> from cache>>>>>> network: Connecting>>>>>>http://139.222.100.25:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/table.GIF>>>>>> with proxy=DIRECT>>>>>> network: Connecting>>>>>>http://139.222.100.25:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/table.GIF>>>>>> with cookie "JSESSIONID=4D2AFA25DE6D6CEB3618E996D9227949">>>>>> basic: Loading>>>>>>http://139.222.100.25:8080/softiam-

portal/softiam/services/ui/dataAnalysis/tool/data/images/table.GIF>>>>>> from cache>>>>>> network: Connecting>>>>>>http://139.222.100.25:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/add.GIF>>>>>> with proxy=DIRECT>>>>>> network: Connecting>>>>>>http://139.222.100.25:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/add.GIF>>>>>> with cookie "JSESSIONID=4D2AFA25DE6D6CEB3618E996D9227949">>>>>> basic: 
Loading>>>>>>http://139.222.100.25:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/add.GIF>>>>>> from cache>>>>>> network: Connecting>>>>>>http://139.222.100.25:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/remove.GIF>>>>>> with proxy=DIRECT>>>>>> network: Connecting>>>>>>http://139.222.100.25:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/remove.GIF>>>>>> with cookie "JSESSIONID=4D2AFA25DE6D6CEB3618E996D9227949">>>>>> basic: 
Loading>>>>>>http://139.222.100.25:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/remove.GIF>>>>>> from cache>>>>>> network: Connecting>>>>>>http://139.222.100.25:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/tyndall.GIF>>>>>> with proxy=DIRECT>>>>>> network: Connecting>>>>>>http://139.222.100.25:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/tyndall.GIF>>>>>> with cookie "JSESSIONID=4D2AFA25DE6D6CEB3618E996D9227949">>>>>> basic: 
Loading>>>>>>http://139.222.100.25:8080/softiam-portal/softiam/services/ui/dataAnalysis/tool/data/images/tyndall.GIF>>>>>> from cache>>>>>> java.security.AccessControlException: access denied(java.io.FilePermission>>>>>>http%3A%2F%2F139.222.100.25%3A8080%2Fsoftiam-portal%2Fusers%2Fe145%2FIPCC_ESM+Magicc_SCM%2Fmagicc_out.nc>>>>>> read)>>>>>> at java.security.AccessControlContext.checkPermission(Unknown Source)>>>>>> at java.security.AccessController.checkPermission(Unknown Source)>>>>>> at java.lang.SecurityManager.checkPermission(Unknown Source)>>>>>> at 
java.lang.SecurityManager.checkRead(

Unknown Source)>>>>>> at java.io.RandomAccessFile.<init>(Unknown Source)>>>>>> at java.io.RandomAccessFile.<init>(Unknown Source)>>>>>> at ucar.unidata.io.RandomAccessFile.<init>(RandomAccessFile.java:134)>>>>>> at ucar.nc2.NetcdfFile.open(NetcdfFile.java:217)>>>>>> at ucar.nc2.NetcdfFile.open(NetcdfFile.java:167)>>>>>> at ucar.nc2.NetcdfFile.open(NetcdfFile.java:151)>>>>>> at>>>>>>softiam.services.ui.dataAnalysis.util.NetCDFReader.<init>(NetCDFReader.java:42)>>>>>> at>>>>>>softiam.services.ui.dataAnalysis.engine.SoftiamRepresentation.setNetCDFFile(SoftiamRepresentation.java:130)>>>>>> 
at>>>>>>softiam.services.ui.dataAnalysis.tool.SoftiamAnalyzer.loadURL(SoftiamAnalyzer.java:630)>>>>>> at>>>>>>softiam.services.ui.dataAnalysis.tool.SoftiamAnalyzerApplet.init(SoftiamAnalyzerApplet.java:38)>>>>>> at sun.applet.AppletPanel.run(Unknown Source)>>>>>> at java.lang.Thread.run(Unknown Source)>>>>>> Dump thread stack ...>>>>>> ---------------------------------------------------->>>>>> Full thread dump Java HotSpot(TM) Client VM (1.5.0_06-b05 mixedmode):>>>>>>>>>>>> "Thread-18" prio=4 tid=0x103c2058 nid=0x9a8 in Object.wait()>>>>>> [0x1090f000..0x1090fd68]>>>>>> at java.lang.Object.wait(Native 
Method)>>>>>> - waiting on <0x05c6deb8> (a visad.java2d.VisADCanvasJ2D)>>>>>> at java.lang.Object.wait(Unknown Source)>>>>>> at visad.java2d.VisADCanvasJ2D.run(VisADCanvasJ2D.java:365)>>>>>> - locked <0x05c6deb8> (a visad.java2d.VisADCanvasJ2D)>>>>>> at java.lang.Thread.run(Unknown Source)>>>>>>>>>>>> "AWT-EventQueue-3" prio=4 tid=0x103f2830 nid=0x888 in Object.wait()>>>>>> [0x1aa6f000..0x1aa6f9e8]>>>>>> at java.lang.Object.wait(Native Method)>>>>>> - waiting on <0x05c51640> (a java.awt.EventQueue)>>>>>> at java.lang.Object.wait(Unknown Source)>>>>>> at java.awt.EventQueue.getNextEvent(Unknown 
Source)>>>>>> - locked <0x05c51640> (a java.awt.EventQueue)>>>>>> at java.awt.EventDispatchThread.pumpOneEventForHierarchy(UnknownSource)>>>>>> at java.awt.EventDispatchThread.pumpEventsForHierarchy(UnknownSource)>>>>>> at java.awt.EventDispatc

hThread.pumpEvents(Unknown Source)>>>>>> at java.awt.EventDispatchThread.pumpEvents(Unknown Source)>>>>>> at java.awt.EventDispatchThread.run(Unknown Source)>>>>>>>>>>>> "TimerQueue" daemon prio=4 tid=0x104aa780 nid=0x958 in Object.wait()>>>>>> [0x10c1f000..0x10c1fae8]>>>>>> at java.lang.Object.wait(Native Method)>>>>>> - waiting on <0x05c51738> (a javax.swing.TimerQueue)>>>>>> at javax.swing.TimerQueue.run(Unknown Source)>>>>>> - locked <0x05c51738> (a javax.swing.TimerQueue)>>>>>> at java.lang.Thread.run(Unknown Source)>>>>>>>>>>>> "thread>>>>>>applet-softiam.services.ui.dataAnalysis.tool.SoftiamAnalyzerApplet.class">>>>>> prio=4 tid=0x103f1168 nid=0x40c in 
Object.wait()[0x1a76f000..0x1a76fbe8]>>>>>> at java.lang.Object.wait(Native Method)>>>>>> - waiting on <0x05c51938> (a sun.plugin.AppletViewer)>>>>>> at java.lang.Object.wait(Unknown Source)>>>>>> at sun.applet.AppletPanel.getNextEvent(Unknown Source)>>>>>> - locked <0x05c51938> (a sun.plugin.AppletViewer)>>>>>> at sun.applet.AppletPanel.run(Unknown Source)>>>>>> at java.lang.Thread.run(Unknown Source)>>>>>>>>>>>> "TimerQueue" daemon prio=6 tid=0x1049eb40 nid=0xfd8 in Object.wait()>>>>>> [0x10a0f000..0x10a0fa68]>>>>>> at java.lang.Object.wait(Native Method)>>>>>> - waiting on <0x05c2ca38> (a javax.swing.TimerQueue)>>>>>> at javax.swing.TimerQueue.run(Unknown 
Source)>>>>>> - locked <0x05c2ca38> (a javax.swing.TimerQueue)>>>>>> at java.lang.Thread.run(Unknown Source)>>>>>>>>>>>> "ConsoleWriterThread" daemon prio=6 tid=0x105077f0 nid=0x438 in>>>>>> Object.wait() [0x1080f000..0x1080fae8]>>>>>> at java.lang.Object.wait(Native Method)>>>>>> - waiting on <0x058228f8> (a java.lang.Object)>>>>>> at java.lang.Object.wait(Unknown Source)>>>>>> atcom.sun.deploy.util.ConsoleTraceListener$ConsoleWriterThread.run(Unknown>>>>>> Source)>>>>>> - locked <0x058228f8> (a java.lang.Object)>>>>>>>>>>>> "AWT-EventQueue-1" prio=6 tid=0x103c2ab0 nid=0xe78 runnable>>>>>> [0x02e2f000..0x02e2fb68]>>>>>> at 
sun.plugin.JavaRunTime.dumpAllStacks(Native Method)>>>>>> at sun.plugin.util.Plu

ginConsoleController.dumpAllStacks(UnknownSource)>>>>>> at com.sun.deploy.util.ConsoleWindow$1.actionPerformed(UnknownSource)>>>>>> at javax.swing.JComponent$ActionStandin.actionPerformed(UnknownSource)>>>>>> at javax.swing.SwingUtilities.notifyAction(Unknown Source)>>>>>> at javax.swing.JComponent.processKeyBinding(Unknown Source)>>>>>> at javax.swing.KeyboardManager.fireBinding(Unknown Source)>>>>>> at javax.swing.KeyboardManager.fireKeyboardAction(Unknown Source)>>>>>> at javax.swing.JComponent.processKeyBindingsForAllComponents(Unknown>>>>>> Source)>>>>>> at javax.swing.JComponent.processKeyBindings(Unknown Source)>>>>>> at javax.swing.JComponent.processKeyEvent(Unknown Source)>>>>>> at java.awt.Component.processEvent(Unknown Source)>>>>>> at java.awt.Container.processEvent(Unknown Source)>>>>>> at java.awt.Component.dispatchEventImpl(Unknown Source)>>>>>> at java.awt.Container.dispatchEventImpl(Unknown Source)>>>>>> at java.awt.Component.dispatchEvent(Unknown Source)>>>>>> at java.awt.KeyboardFocusManager.redispatchEvent(Unknown Source)>>>>>> at java.awt.DefaultKeyboardFocusManager.dispatchKeyEvent(UnknownSource)>>>>>> at java.awt.DefaultKeyboardFocusManager.preDispatchKeyEvent(UnknownSource)>>>>>> at java.awt.DefaultKeyboardFocusManager.typeAheadAssertions(UnknownSource)>>>>>> at java.awt.DefaultKeyboardFocusManager.dispatchEvent(Unknown Source)>>>>>> at java.awt.Component.dispatchEventImpl(Unknown Source)>>>>>> at java.awt.Container.dispatchEventImpl(Unknown Source)>>>>>> at java.awt.Window.dispatchEventImpl(Unknown Source)>>>>>> at java.awt.Component.dispatchEvent(Unknown Source)>>>>>> at java.awt.EventQueue.dispatchEvent(Unknown Source)>>>>>> at java.awt.EventDispatchThread.pumpOneEventForHierarchy(UnknownSource)>>>>>> at java.awt.EventDispatchThread.pumpEventsForHierarchy(UnknownSource)>>>>>> at java.awt.EventDispatchThread.pumpEvents(Unknown Source)>>>>>> at java.awt.EventDispatchThread.pumpEvents(Unknown Source)>>>>>> at java.awt.EventDispatchThread.run(Unknown Source)>>>>>>>>>>>> "Thread-13" prio=6
tid=0x10462600 nid=0xfbc runnable>>>>>> [0x00000000..0x1010f71c]>>>>>>>>>>>> "J3D-Renderer-1" prio=4 tid=0x104feb80 nid=0x73c in Object.wait()>>>>>> [0x1a05f000..0x1a05fd68]>>>>>> at java.lang.Object.wait(Native Method)>>>>>> - waiting on <0x058a0000> (a javax.media.j3d.Renderer)>>>>>> at java.lang.Object.wait(Unknown Source)>>>>>> at javax.media.j3d.J3dThread.runMonitor(J3dThread.java:275)>>>>>> - locked <0x058a0000> (a javax.media.j3d.Renderer)>>>>>> at javax.media.j3d.J3dThread.run(J3dThread.java:251)>>>>>>>>>>>> "J3D-MasterControl-1" prio=4 tid=0x104b6850 nid=0xb70 inObject.wait()>>>>>> 
[0x19f5f000..0x19f5f9e8]>>>>>> at java.lang.Object.wait(Native Method)>>>>>> - waiting on <0x058a0190> (a javax.media.j3d.MasterControl)>>>>>> at java.lang.Object.wait(Unknown Source)>>>>>> at javax.media.j3d.MasterControl.runMonitor(MasterControl.java:3619)>>>>>> - locked <0x058a0190> (a javax.media.j3d.MasterControl)>>>>>> at javax.media.j3d.MasterControl.doWork(MasterControl.java:3081)>>>>>> atjavax.media.j3d.MasterControlThread.run(MasterControlThread.java:48)>>>>>>>>>>>> "J3D-NotificationThread" prio=4 tid=0x104b66c8 nid=0x6ec inObject.wait()>>>>>> [0x19e5f000..0x19e5fa68]>>>>>> at java.lang.Object.wait(Native Method)>>>>>> - waiting on 
<0x058a02b8> (a javax.media.j3d.NotificationThread)>>>>>> at java.lang.Object.wait(Unknown Source)>>>>>> at>>>>>>javax.media.j3d.NotificationThread.runMonitor(NotificationThread.java:97)>>>>>> - locked <0x058a02b8> (a javax.media.j3d.NotificationThread)>>>>>> at javax.media.j3d.NotificationThread.run(NotificationThread.java:83)>>>>>>>>>>>> "J3D-TimerThread" prio=4 tid=0x10502310 nid=0x16c in Object.wait()>>>>>> [0x19d5f000..0x19d5fae8]>>>>>> at java.lang.Object.wait(Native Method)>>>>>> - waiting on <0x058a0320> (a javax.media.j3d.TimerThread)>>>>>> at java.lang.Object.wait(Unknown Source)>>>>>> at 
javax.media.j3d.TimerThread.runMonitor(TimerThread.java:126)>>>>>> - locked <0x058a0320> (a javax.media.j3d.TimerThread)>>>>>> at javax.media.j3d.TimerThread.run(TimerThread.java:89)>>>>>>>>>>>

"J3D-RenderingAttributesStructureUpdateThread" prio=4 tid=0x104f9e10>>>>>> nid=0x8e4 in Object.wait() [0x19c5f000..0x19c5fb68]>>>>>> at java.lang.Object.wait(Native Method)>>>>>> - waiting on <0x058a0390> (a javax.media.j3d.StructureUpdateThread)>>>>>> at java.lang.Object.wait(Unknown Source)>>>>>> at javax.media.j3d.J3dThread.runMonitor(J3dThread.java:264)>>>>>> - locked <0x058a0390> (a javax.media.j3d.StructureUpdateThread)>>>>>> at javax.media.j3d.J3dThread.run(J3dThread.java:248)>>>>>>>>>>>> "AWT-EventQueue-0" prio=6 tid=0x0f8a7070 nid=0x5d4 in Object.wait()>>>>>> 
[0x1020f000..0x1020fb68]>>>>>> at java.lang.Object.wait(Native Method)>>>>>> - waiting on <0x057c3fb0> (a java.awt.EventQueue)>>>>>> at java.lang.Object.wait(Unknown Source)>>>>>> at java.awt.EventQueue.getNextEvent(Unknown Source)>>>>>> - locked <0x057c3fb0> (a java.awt.EventQueue)>>>>>> at java.awt.EventDispatchThread.pumpOneEventForHierarchy(UnknownSource)>>>>>> at java.awt.EventDispatchThread.pumpEventsForHierarchy(UnknownSource)>>>>>> at java.awt.EventDispatchThread.pumpEvents(Unknown Source)>>>>>> at java.awt.EventDispatchThread.pumpEvents(Unknown Source)>>>>>> at java.awt.EventDispatchThread.run(Unknown 
Source)>>>>>>>>>>>> "traceMsgQueueThread" daemon prio=6 tid=0x0f898468 nid=0xf38 in>>>>>> Object.wait() [0x0ff5f000..0x0ff5fc68]>>>>>> at java.lang.Object.wait(Native Method)>>>>>> - waiting on <0x05810398> (a java.util.ArrayList)>>>>>> at java.lang.Object.wait(Unknown Source)>>>>>> at com.sun.deploy.util.Trace$TraceMsgQueueChecker.run(Unknown Source)>>>>>> - locked <0x05810398> (a java.util.ArrayList)>>>>>> at java.lang.Thread.run(Unknown Source)>>>>>>>>>>>> "AWT-Windows" daemon prio=6 tid=0x0f887c98 nid=0x7c4 runnable>>>>>> 
[0x0fd4f000..0x0fd4fce8]>>>>>> at java.awt.EventQueue.wakeup(Unknown Source)>>>>>> at sun.reflect.GeneratedMethodAccessor1.invoke(Unknown Source)>>>>>> at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)>>>>>> at java.lang.reflect.Method.invoke(Unknown Source)>>>>>> at sun.awt.SunToolkit.wakeupEventQueue

(Unknown Source)>>>>>> at sun.awt.PostEventQueue.postEvent(Unknown Source)>>>>>> at sun.awt.SunToolkit.postEvent(Unknown Source)>>>>>> at sun.awt.windows.WComponentPeer.postEvent(Unknown Source)>>>>>> at sun.awt.windows.WToolkit.eventLoop(Native Method)>>>>>> at sun.awt.windows.WToolkit.run(Unknown Source)>>>>>> at java.lang.Thread.run(Unknown Source)>>>>>>>>>>>> "AWT-Shutdown" prio=6 tid=0x0f887860 nid=0x548 in Object.wait()>>>>>> [0x0fc4f000..0x0fc4fd68]>>>>>> at java.lang.Object.wait(Native Method)>>>>>> - waiting on <0x057d3db8> (a java.lang.Object)>>>>>> at java.lang.Object.wait(Unknown Source)>>>>>> at sun.awt.AWTAutoShutdown.run(Unknown Source)>>>>>> - locked 
<0x057d3db8> (a java.lang.Object)>>>>>> at java.lang.Thread.run(Unknown Source)>>>>>>>>>>>> "Java2D Disposer" daemon prio=10 tid=0x0f880970 nid=0xed0 inObject.wait()>>>>>> [0x0fb4f000..0x0fb4f9e8]>>>>>> at java.lang.Object.wait(Native Method)>>>>>> - waiting on <0x057d3e40> (a java.lang.ref.ReferenceQueue$Lock)>>>>>> at java.lang.ref.ReferenceQueue.remove(Unknown Source)>>>>>> - locked <0x057d3e40> (a java.lang.ref.ReferenceQueue$Lock)>>>>>> at java.lang.ref.ReferenceQueue.remove(Unknown Source)>>>>>> at sun.java2d.Disposer.run(Unknown Source)>>>>>> at java.lang.Thread.run(Unknown Source)>>>>>>>>>>>> "Low Memory Detector" daemon prio=6 tid=0x02d04898 nid=0xedc 
runnable>>>>>> [0x00000000..0x00000000]>>>>>>>>>>>> "CompilerThread0" daemon prio=10 tid=0x02d03598 nid=0x9e0 waiting on>>>>>> condition [0x00000000..0x0f60f84c]>>>>>>>>>>>> "Signal Dispatcher" daemon prio=10 tid=0x02d027e8 nid=0x644 runnable>>>>>> [0x00000000..0x00000000]>>>>>>>>>>>> "Finalizer" daemon prio=8 tid=0x02cf98c0 nid=0xa18 in Object.wait()>>>>>> [0x0f40f000..0x0f40fc68]>>>>>> at java.lang.Object.wait(Native Method)>>>>>> - waiting on <0x057d3fe8> (a java.lang.ref.ReferenceQueue$Lock)>>>>>> at java.lang.ref.ReferenceQueue.remove(Unknown Source)>>>>>> - locked <0x057d3fe8> (a java.lang.ref.ReferenceQueue$Lock)>>>>>> at 
java.lang.ref.ReferenceQueue.remove(Unknown Source)>>>>>> at java.

lang.ref.Finalizer$FinalizerThread.run(Unknown Source)>>>>>>>>>>>> "Reference Handler" daemon prio=10 tid=0x02cf8428 nid=0x100 inObject.wait()>>>>>> [0x0f30f000..0x0f30fce8]>>>>>> at java.lang.Object.wait(Native Method)>>>>>> - waiting on <0x057d4068> (a java.lang.ref.Reference$Lock)>>>>>> at java.lang.Object.wait(Unknown Source)>>>>>> at java.lang.ref.Reference$ReferenceHandler.run(Unknown Source)>>>>>> - locked <0x057d4068> (a java.lang.ref.Reference$Lock)>>>>>>>>>>>> "main" prio=6 tid=0x02c36938 nid=0xbd0 runnable[0x00000000..0x02f2e920]>>>>>>>>>>>> "VM Thread" prio=10 tid=0x02cf4288 nid=0xa38 runnable>>>>>>>>>>>> "VM Periodic Task Thread" prio=10 tid=0x02d05a78 nid=0xf7c waiting on>>>>>> condition>>>>>>>>>>>> ---------------------------------------------------->>>>>> Done.>>>>>>>>>>>>>>>>>> ----- 
Original Message ----->>>>>> From: "John Caron" <caron@xxxxxxxxxxxxxxxx>>>>>>> To: "S Santos" <s.santos@xxxxxxxxx>>>>>>> Cc: <netcdf-java@xxxxxxxxxxxxxxxx>;<support-netcdf-java@xxxxxxxxxxxxxxxx>>>>>>> Sent: Monday, April 24, 2006 6:25 PM>>>>>> Subject: Re: java.security.AccessControlException opening from anapplet>>>>>>>>>>>>>>>>>>>>>>>>> It would be useful to see the complete stack trace. It looks likeyou are>>>>>>> trying to read a local file?? As Tom said, applets dont have thatright.>>>>>>>>>>>>>> Tom Whittaker wrote:>>>>>>>>>>>>>>> Santi:>>>>>>>>>>>>>>>> In general, applets are not permitted to communicate with a hostother>>>>>>>> than the one they were loaded from.  In previous JVMs, this rulewhen>>>>>>>> using a local URL was relaxed.  In later versions of Java it ismore>>>>>>>> strictly 
enforced (as it always has been for loading applets from>>>>>>>> remote hosts).>>>>>>>>>>>>>>>> You might (I havent tried it) be able to use the>>>>>>>> AccessController.doPrivileged() method to enable this -- I justdon't>>>>>>>> know if it would pop-up a user dialog for each I/O though.  Somemore>>>>>>>> info at:>>>>>>>> <http://www.raditha.com/java/sandbox/unsigned.php>>>>>>>>>>>>>>>>> Regards,>>>>>>>>>>>>>>>> tom>>>>>>>>>>

On 4/24/06, S Santos <s.santos@xxxxxxxxx> wrote:>>>>>>>>>>>>>>>>>>>>>>>>> Hello,>>>>>>>>>>>>>>>>>> I'm developing a tool to display netCDF files. The program has two>>>>>>>>> versions,>>>>>>>>> a desktop one and an applet version. When I load from a URL usingthe>>>>>>>>> applet>>>>>>>>> version java throws this exception:>>>>>>>>>>>>>>>>>> java.security.AccessControlException: access denied>>>>>>>>> (java.io.FilePermission>>>>>>>>>http%3A%2F%2Flocalhost%3A8080%2Fsoftiam-portal%2Fusers%2Fe145%2FIPCC_ESM+Magicc_SCM%2Fmagicc_out.nc>>>>>>>>> read)>>>>>>>>> at>>>>>>>>> java.security.AccessControlContext.checkPermission(Unknown>>>>>>>>> Source)>>>>>>>>> at java.security.AccessController.checkPermission(Unknown>>>>>>>>> 
Source)>>>>>>>>> at java.lang.SecurityManager.checkPermission(Unknown>>>>>>>>> Source)>>>>>>>>> at java.lang.SecurityManager.checkRead(Unknown Source)>>>>>>>>> at java.io.RandomAccessFile.<init>(Unknown Source)>>>>>>>>> at java.io.RandomAccessFile.<init>(Unknown Source)>>>>>>>>> at>>>>>>>>> ucar.unidata.io.RandomAccessFile.<init>(RandomAccessFile.java:134)>>>>>>>>> at ucar.nc2.NetcdfFile.open(NetcdfFile.java:217)>>>>>>>>> at ucar.nc2.NetcdfFile.open(NetcdfFile.java:167)>>>>>>>>> at ucar.nc2.NetcdfFile.open(NetcdfFile.java:151)>>>>>>>>> at>>>>>>>>>softiam.services.ui.dataAnalysis.util.NetCDFReader.<init>(NetCDFReader.java:42)>>>>>>>>> at>>>>>>>>>softiam.services.ui.dataAnalysis.engine.SoftiamRepresentation.setNetCDFFile(SoftiamRepresentation.java:130)>>>>>>>>> 
at>>>>>>>>>softiam.services.ui.dataAnalysis.tool.SoftiamAnalyzer.loadURL(SoftiamAnalyzer.java:630)>>>>>>>>> at>>>>>>>>>softiam.services.ui.dataAnalysis.tool.SoftiamAnalyzerApplet.init(SoftiamAnalyzerApplet.java:38)>>>>>>>>> at sun.applet.AppletPanel.run(Unknown Source)>>>>>>>>> at java.lang.Thread.run(Unknown Source)>>>>>>>>>>>>>>>>>> The system uses netCDF 2.2.14 version with slf4j-simple.jar and>>>>>>>>> log4j-1.2.13.jar for Http connections. In a previous version usingnetCDF>>>>>>>>> 2.1.10 this problem didn't happen. Is there any solutio

n to thisproblem>>>>>>>>> without having to change java security policy files?>>>>>>>>>>>>>>>>>> Regards,>>>>>>>>>>>>>>>>>> Santi>>>>>>>>>>>>>>>>>>>>>>>>>>> Santiago de la Nava Santos>>>>>>>>> Software Engineer>>>>>>>>> Tyndall Centre>>>>>>>>> Zuckermann Institute>>>>>>>>> University of East Anglia>>>>>>>>> Norwich NR4 7TJ>>>>>>>>>>>>>>>>>> Telephone 01603 591377>>>>>>>>> Fax 01603 593901>>>>>>>>> E-mail s.santos@xxxxxxxxx>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> -->>>>>>>> Tom Whittaker>>>>>>>> University of Wisconsin-Madison>>>>>>>> SSEC/CIMSS>>>>>>>> 1225 W. Dayton Street>>>>>>>> Madison, WI  53706  USA>>>>>>>> ph: 
608-262-2759>>>>>>>>>>>>>>>>===============================================================================>>>>>>>> To unsubscribe netcdf-java, visit:>>>>>>>> http://www.unidata.ucar.edu/mailing-list-delete-form.html>>>>>>>>===============================================================================>>>>>>>>>>>>>>>>>>>>>===============================================================================>>>>>>> To unsubscribe netcdf-java, visit:>>>>>>> http://www.unidata.ucar.edu/mailing-list-delete-form.html>>>>>>>===============================================================================>>>>>>>>>>>>>>>>>>>>>>>>>>===============================================================================>>>>>> To unsubscribe netcdf-java, visit:>>>>>> http://www.unidata.ucar.edu/mailing-list-delete-form.html>>>>>>===============================================================================>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> -->>>>> Tom 
Whittaker>>>>> University of Wisconsin-Madison>>>>> SSEC/CIMSS>>>>> 1225 W. Dayton Street>>>>> Madison, WI  53706  USA>>>>> ph: 608-262-2759>>>>>>>>>>>>>>=============================================================================== To unsubscribe netcdf-java, visit:>>> http://www.unidata.ucar.edu/mailing-list-delete-form.html>>>===============================================================================>>>>======================================================================

========>> To unsubscribe netcdf-java, visit:>> 
http://www.unidata.ucar.edu/mailing-list-delete-form.html>>===============================================================================>>>>>>===============================================================================>
 To unsubscribe netcdf-java, visit:> 
http://www.unidata.ucar.edu/mailing-list-delete-form.html>===============================================================================>>

==============================================================================
To unsubscribe netcdf-java, visit:
http://www.unidata.ucar.edu/mailing-list-delete-form.html
==============================================================================


  • 2006 messages navigation, sorted by:
    1. Thread
    2. Subject
    3. Author
    4. Date
    5. ↑ Table Of Contents
  • Search the netcdf-java archives: