Uses of Class
org.codehaus.commons.compiler.sandbox.SandboxPolicy
Packages that use SandboxPolicy
Package
Description
This package declares interfaces for the implementation of an
IExpressionEvaluator, an IScriptEvaluator, an
IClassBodyEvaluator and an ISimpleCompiler.An implementation of the
org.codehaus.commons.compiler API that uses the "JAVAC" Java compiler that is
part of the "Java Development Kit" (JDK).Restricts the APIs that compiled, untrusted code may use, by verifying the generated bytecode against an allowlist
before it is loaded (
SandboxPolicy), and limits the CPU time and the
memory that the code consumes (SandboxExecutor).The core of the Janino Java compiler.
-
Uses of SandboxPolicy in org.codehaus.commons.compiler
Fields in org.codehaus.commons.compiler declared as SandboxPolicyModifier and TypeFieldDescriptionprotected SandboxPolicyAbstractJavaSourceClassLoader.sandboxPolicyMethods in org.codehaus.commons.compiler with parameters of type SandboxPolicyModifier and TypeMethodDescriptionfinal voidAbstractJavaSourceClassLoader.setSandboxPolicy(SandboxPolicy policy) Restricts the APIs that the loaded classes may use.default voidICookable.setSandboxPolicy(SandboxPolicy policy) Restricts the APIs that the cooked code may use. -
Uses of SandboxPolicy in org.codehaus.commons.compiler.jdk
Methods in org.codehaus.commons.compiler.jdk with parameters of type SandboxPolicyModifier and TypeMethodDescriptionvoidClassBodyEvaluator.setSandboxPolicy(SandboxPolicy policy) voidExpressionEvaluator.setSandboxPolicy(SandboxPolicy policy) voidScriptEvaluator.setSandboxPolicy(SandboxPolicy policy) voidSimpleCompiler.setSandboxPolicy(SandboxPolicy policy) -
Uses of SandboxPolicy in org.codehaus.commons.compiler.sandbox
Fields in org.codehaus.commons.compiler.sandbox declared as SandboxPolicyModifier and TypeFieldDescriptionstatic final SandboxPolicySandboxPolicy.COLLECTIONSThe core collections ofjava.util: the collection interfaces and their common implementations,Collections,ArraysandOptional.static final SandboxPolicySandboxPolicy.FUNCTIONALThe functional interfaces ofjava.util.function(Function,Predicate,Supplier, ...); sandboxed code may also implement them.static final SandboxPolicySandboxPolicy.JAVA_LANG_BASICBasic functionality ofjava.lang:Object(withoutwait()andnotify()),Class.getName()andgetSimpleName(),String,StringBuilder,Math, the wrapper types,Enum, the common exceptions, andjava.util.Objects.static final SandboxPolicySandboxPolicy.JAVA_TIMEThe date and time API ofjava.time, including theformatandtemporalpackages and the ISO calendar system of thechronopackage.static final SandboxPolicySandboxPolicy.MATHjava.math:BigInteger,BigDecimal,MathContextandRoundingMode.static final SandboxPolicySandboxPolicy.REGEXjava.util.regex:Pattern,Matcher,MatchResultandPatternSyntaxException.static final SandboxPolicySandboxPolicy.STREAMSThe sequential streams ofjava.util.stream(Stream,IntStream,LongStream,DoubleStream,Collectors, ...) and the summary statistics ofjava.util; includesSandboxPolicy.FUNCTIONAL.static final SandboxPolicySandboxPolicy.TEXTThe number, date and message formats ofjava.text(NumberFormat,DecimalFormat,SimpleDateFormat,MessageFormat, ...), plusCollatorandNormalizer.static final SandboxPolicySandboxPolicy.UTILITIESUtility classes ofjava.util:Random,SplittableRandom,ThreadLocalRandom,UUID,StringJoiner,StringTokenizer,BitSet,Base64,Locale,Date,Calendar,GregorianCalendar,TimeZone, andFormatter(without the constructors that open files).Methods in org.codehaus.commons.compiler.sandbox that return SandboxPolicyMethods in org.codehaus.commons.compiler.sandbox with parameters of type SandboxPolicyModifier and TypeMethodDescriptionSandboxPolicy.Builder.include(SandboxPolicy policy) Adds all rules of the given policy, e.g. ofSandboxPolicy.JAVA_LANG_BASIC, and requires an executor if the policy does.Constructors in org.codehaus.commons.compiler.sandbox with parameters of type SandboxPolicy -
Uses of SandboxPolicy in org.codehaus.janino
Methods in org.codehaus.janino with parameters of type SandboxPolicyModifier and TypeMethodDescriptionvoidClassBodyEvaluator.setSandboxPolicy(SandboxPolicy policy) voidExpressionEvaluator.setSandboxPolicy(SandboxPolicy policy) voidScriptEvaluator.setSandboxPolicy(SandboxPolicy policy) voidSimpleCompiler.setSandboxPolicy(SandboxPolicy policy)