Probably the WebLogic classloader does not grant permissions to classes it loads; it will need to, in order for the script to do much (access files etc.). In this case it looks like the Ant code which grants permissions to dynamically loaded tasks (and so on) matching what Ant has (which is generally needed if Ant is run inside some container), is itself not permitted by the WebLogic classloader for some reason--perhaps it grants some but not all permissions.
Try putting Ant in the server's startup classpath, if you have no control over the special classloader--this should (hopefully) force it to be loaded by the application classloader which should have the right permissions. Or patch AntClassLoader, commenting out the static initializer which defines defineClassProtectionDomain; this might help, or it might not. -Jesse "Goli, Srikanth" wrote: > I am getting the following AccessControlException exception when I call ant > in my application. I am using Ant1.3 and Weblogic 5.1 Server. All my jars > are in weblogic.class.path. I guess all the classes are loaded by Weblogic's > ServerClassLoader. Interestingly Ant is still creating the jar after this > exception and deploying. > > java.io.IOException: java.security.AccessControlException: access denied > (java.l > ang.RuntimePermission getProtectionDomain) > at > org.apache.tools.ant.AntClassLoader.getClassFromStream(AntClassLoader > .java:439) -- Jesse Glick <mailto:[EMAIL PROTECTED]> NetBeans, Open APIs <http://www.netbeans.org/> tel (+4202) 3300-9161 Sun Micro x49161 Praha CR
