|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.rhq.enterprise.communications.util.SecurityUtil
public class SecurityUtil
Utilities to help perform security tasks.
| Method Summary | |
|---|---|
static void |
createKeyStore(String file_path,
String key_alias,
String domain_name,
String keystore_password,
String key_password,
String key_algorithm,
int validity)
Creates a keystore and places a new key in it that has the given key information. |
static boolean |
isTransportSecure(String transport)
Given a JBoss/Remoting transport name (such as "sslsocket" or "http") this will return true if that
transport is considered secure via SSL. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Method Detail |
|---|
public static boolean isTransportSecure(String transport)
true if that
transport is considered secure via SSL.
transport - the name of the transport protocol (can be the transport only or the entire locator URI)
true if the transport protocol uses SSL to secure the data, false if not
public static void createKeyStore(String file_path,
String key_alias,
String domain_name,
String keystore_password,
String key_password,
String key_algorithm,
int validity)
throws RuntimeException
If the key password is null or an empty string, it will be set to the same as the keystore
password. If the keystore password is null, an exception is thrown.
If either the keystore password or key password is not at least 6 characters long, an exception is thrown.
If validity is less than or equal to 0, it will default to 100 years.
file_path - the path of the keystore file on the file system (if this exists already, this method
does nothing)key_alias - the alias name of the key that will be generated and placed in the key storedomain_name - the domain name of the new keykeystore_password - the password of the keystore file (must not be null)key_password - the password of the key within the keystorekey_algorithm - the algorithm used to generate the new keyvalidity - the number of days the key is valid for
RuntimeException - if failed to create the keystore file
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||