Enum Class SecurityProfile
- All Implemented Interfaces:
Serializable
,Comparable<SecurityProfile>
,Constable
The security profile to be used is set at the launch of PlantUML and cannot
be changed by users. The security profile defines what an instance of
PlantUML is allowed to do:
- access some local file
- connection to some remote URL
- print some technical information to the users.
The security profile is defined:
- either by an environment variable
- or an option at command line
There is also a default value, which is LEGACY in this current implementation.
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>>
-
Enum Constant Summary
Enum ConstantsEnum ConstantDescriptionThis mode is designed for PlantUML running in a web server.This mode reproduce old PlantUML version behaviour.Running in SANDBOX mode is completely secure.Running in UNSECURE mode means that PlantUML can access to any local file and can connect to any URL. -
Method Summary
Modifier and TypeMethodDescriptionboolean
long
Retrieve the timeout for URL.A Human understandable description.static SecurityProfile
Returns the enum constant of this class with the specified name.static SecurityProfile[]
values()
Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
SANDBOX
Running in SANDBOX mode is completely secure. No local file can be read (except dot executable) No remote URL access can be used No technical information are print to users.This mode is defined for test and debug, since it's not very useful for users. However, you can use it if you need to.
-
ALLOWLIST
-
INTERNET
This mode is designed for PlantUML running in a web server. -
LEGACY
This mode reproduce old PlantUML version behaviour.Right now, this is the default Security Profile but this will be removed from future version because it is now full secure, especially on Internet server.
-
UNSECURE
Running in UNSECURE mode means that PlantUML can access to any local file and can connect to any URL.Some technical information (file path, Java version) are also printed in some error messages. This is not an issue if you are running PlantUML locally. But you should not use this mode if PlantUML is running on some server, especially if the server is accessible from Internet.
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException
- if this enum class has no constant with the specified nameNullPointerException
- if the argument is null
-
longDescription
A Human understandable description. -
getTimeout
public long getTimeout()Retrieve the timeout for URL. -
canWeReadThisEnvironmentVariable
-