Package uk.ac.starlink.topcat
Enum Class Safety
- All Implemented Interfaces:
Serializable
,Comparable<Safety>
,Constable
Characterises a security risk.
There are currently two values, SAFE and UNSAFE.
A value of SAFE indicates that the action so characterised is known to be harmless. This applies to actions that can only affect the internal state of the application. Actions that might be the target of an injection attack should be marked UNSAFE.
Potentially unsafe capabilities, which should be marked UNSAFE, include:
- invocation of activation-type JEL functions (those from uk.ac.starlink.topcat.func.*, though not those from uk.ac.starlink.ttools.func.*)
- unrestricted execution of System (shell) commands
- acquiring input streams from
DataSource.makeDataSource(java.lang.String)
(these may include shell execution; note that table load typically calls this method) - sending a SAMP message of unknown semantics (except one marked as mostly-harmless)
- Since:
- 13 Jul 2018
- Author:
- Mark Taylor
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>>
-
Enum Constant Summary
Enum Constants -
Method Summary
-
Enum Constant Details
-
SAFE
Poses no security risk. -
UNSAFE
Poses a potential security risk.
-
-
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
-