Enum SystemCommandRestrictions

    • Enum Constant Detail

      • PREVENT_COMMAND_CHAINING

        public static final SystemCommandRestrictions PREVENT_COMMAND_CHAINING
        Prevent multiple commands from being executed in a single call.
      • PREVENT_COMMON_EXPLOIT_EXECUTABLES

        public static final SystemCommandRestrictions PREVENT_COMMON_EXPLOIT_EXECUTABLES
        Prevent commands commonly used in exploitation from being executed in a call (e.g., wget, netcat)
      • PREVENT_ARGUMENTS_TARGETING_SENSITIVE_FILES

        public static final SystemCommandRestrictions PREVENT_ARGUMENTS_TARGETING_SENSITIVE_FILES
        Prevent commands from passing arguments that seem to be sensitive files (e.g., /etc/shadow)
    • Method Detail

      • values

        public static SystemCommandRestrictions[] values()
        Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:
        for (SystemCommandRestrictions c : SystemCommandRestrictions.values())
            System.out.println(c);
        
        Returns:
        an array containing the constants of this enum type, in the order they are declared
      • valueOf

        public static SystemCommandRestrictions valueOf​(String name)
        Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (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 type has no constant with the specified name
        NullPointerException - if the argument is null