This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 100827 - SecurityException on running java task
Summary: SecurityException on running java task
Status: VERIFIED DUPLICATE of bug 47645
Alias: None
Product: projects
Classification: Unclassified
Component: Ant (show other bugs)
Version: 6.x
Hardware: All All
: P2 blocker (vote)
Assignee: Jesse Glick
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2007-04-12 18:04 UTC by pzajac
Modified: 2007-05-02 14:12 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
Testing web project (10.07 KB, application/octet-stream)
2007-04-12 18:05 UTC, pzajac
Details
Exception (1.93 KB, text/plain)
2007-04-12 18:06 UTC, pzajac
Details

Note You need to log in before you can comment on or make changes to this bug.
Description pzajac 2007-04-12 18:04:54 UTC
[20070411]
Open attached project ant run target:

 <target name="testRun" depends="compile" >
        <java classname="a.Main" classpath="build/web/WEB-INF/classes"/> 
 </target>

a exception was thrown

java.lang.SecurityException
        at
org.netbeans.TopSecurityManager.checkSetSecurityManager(TopSecurityManager.java:351)
        at
org.netbeans.TopSecurityManager.checkPermission(TopSecurityManager.java:315)
        at java.lang.System.setSecurityManager0(System.java:253)
        at java.lang.System.setSecurityManager(System.java:245)
        at
org.apache.tools.ant.types.Permissions.restoreSecurityManager(Permissions.java:152)
        at org.apache.tools.ant.taskdefs.ExecuteJava.run(ExecuteJava.java:227)
Comment 1 pzajac 2007-04-12 18:05:53 UTC
Created attachment 40839 [details]
Testing web project
Comment 2 pzajac 2007-04-12 18:06:39 UTC
Created attachment 40840 [details]
Exception
Comment 3 Jesse Glick 2007-04-12 18:27:30 UTC
You need to use fork=true.

*** This issue has been marked as a duplicate of 47645 ***
Comment 4 pzajac 2007-05-02 14:12:35 UTC
v