You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ant.apache.org by bu...@apache.org on 2002/08/26 15:04:42 UTC
DO NOT REPLY [Bug 12038] New: -
Use of external command line compiler requires execute <> FilePermission
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=12038>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND
INSERTED IN THE BUG DATABASE.
http://nagoya.apache.org/bugzilla/show_bug.cgi?id=12038
Use of external command line compiler requires execute <<ALL FILES>> FilePermission
Summary: Use of external command line compiler requires execute
<<ALL FILES>> FilePermission
Product: Ant
Version: 1.5
Platform: All
OS/Version: All
Status: NEW
Severity: Enhancement
Priority: Other
Component: Core tasks
AssignedTo: ant-dev@jakarta.apache.org
ReportedBy: glenn@apache.org
Ant is now used by Tomcat's Jasper 2 for compiling JSP pages.
Tomcat runs with the Java SecurityManager and invokes ant
classes to compile JSP pages.
If you want to use ant with an external compiler like jikes
you have to grant the following FilePermission:
permission java.io.FilePermission "<<ALL FILES>>, "read,execute";
This is too broad a permission grant for those who use a strict
java security policy and prevents use of an external compiler
like jikes.
The following enhancement would fix the problem:
Add another property called build.compiler.path in addition to
the build.compiler property. This property would be set to
the complete path of the jikes (or other external compiler) path.
For example: -Dbuild.compiler=jikes -Dbuild.compiler.path=/usr/local/bin/jikes
Then in org.apache.tools.ant.taskdefs.compiler.Jikes.java
the following code which sets the executable would use the
property if it existed.
Commandline cmd = new Commandline();
cmd.setExecutable("jikes");
A path attribute could be added to the compiler element of javac to set
the complete full path to the jikes or other external compiler.
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>