public class Util extends Object
| Constructor and Description |
|---|
Util() |
| Modifier and Type | Method and Description |
|---|---|
static boolean |
isFIPS()
Check for FIPS (vault can't be used with FIPS).
|
static boolean |
isPasswordCommand(char[] passwordCmd)
Checks whether password can be loaded by
loadPassword(String). |
static boolean |
isPasswordCommand(String passwordCmd)
Checks whether password can be loaded by
loadPassword(String). |
static char[] |
loadPassword(String passwordCmd)
Execute a password load command to obtain the char[] contents of a
password.
|
public static char[] loadPassword(String passwordCmd) throws Exception
passwordCmd - - A command to execute to obtain the plaintext
password. The format is one of:
'{EXT}...' where the '...' is the exact command
'{EXTC[:expiration_in_millis]}...' where the '...' is the exact command
line that will be passed to the Runtime.exec(String) method to execute a
platform command. The first line of the command output is used as the
password.
EXTC variant will cache the passwords for expiration_in_millis milliseconds.
Default cache expiration is 0 = infinity.
'{CMD}...' or '{CMDC[:expiration_in_millis]}...' for a general command to execute. The general
command is a string delimited by ',' where the first part is the actual
command and further parts represents its parameters. The comma can be
backslashed in order to keep it as a part of the parameter.Exceptionpublic static boolean isPasswordCommand(String passwordCmd)
loadPassword(String).passwordCmd - a potential password commandloadPassword(String), false otherwise.public static boolean isPasswordCommand(char[] passwordCmd)
loadPassword(String).passwordCmd - a potential password commandloadPassword(String), false otherwise.public static boolean isFIPS()
Copyright © 2021. All rights reserved.