Class OpenSSLCipherConfigurationParser
- java.lang.Object
-
- org.apache.tomcat.util.net.openssl.ciphers.OpenSSLCipherConfigurationParser
-
public class OpenSSLCipherConfigurationParser extends Object
Class in charge with parsing openSSL expressions to define a list of ciphers.
-
-
Constructor Summary
Constructors Constructor Description OpenSSLCipherConfigurationParser()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static List<String>
convertForJSSE(Collection<Cipher> ciphers)
static String
jsseToOpenSSL(String jsseCipherName)
Converts a JSSE cipher name to an OpenSSL cipher name.static void
main(String[] args)
static String
openSSLToJsse(String opensslCipherName)
Converts an OpenSSL cipher name to a JSSE cipher name.static LinkedHashSet<Cipher>
parse(String expression)
static List<String>
parseExpression(String expression)
Parse the specified expression according to the OpenSSL syntax and returns a list of standard JSSE cipher names.static void
usage()
-
-
-
Method Detail
-
parse
public static LinkedHashSet<Cipher> parse(String expression)
-
convertForJSSE
public static List<String> convertForJSSE(Collection<Cipher> ciphers)
-
parseExpression
public static List<String> parseExpression(String expression)
Parse the specified expression according to the OpenSSL syntax and returns a list of standard JSSE cipher names.- Parameters:
expression
- the openssl expression to define a list of cipher.- Returns:
- the corresponding list of ciphers.
-
jsseToOpenSSL
public static String jsseToOpenSSL(String jsseCipherName)
Converts a JSSE cipher name to an OpenSSL cipher name.- Parameters:
jsseCipherName
- The JSSE name for a cipher- Returns:
- The OpenSSL name for the specified JSSE cipher
-
openSSLToJsse
public static String openSSLToJsse(String opensslCipherName)
Converts an OpenSSL cipher name to a JSSE cipher name.- Parameters:
opensslCipherName
- The OpenSSL name for a cipher- Returns:
- The JSSE name for the specified OpenSSL cipher. If none is known, the IANA standard name will be returned instead
-
usage
public static void usage()
-
-