Class OpenSSL4JProvider
java.lang.Object
java.util.Dictionary<Object,Object>
java.util.Hashtable<Object,Object>
java.util.Properties
java.security.Provider
de.sfuhrm.openssl4j.OpenSSL4JProvider
- All Implemented Interfaces:
Serializable, Cloneable, Map<Object,Object>
JCA provider directing all calls to the system native OpenSSL library.
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class Provider
Provider.Service -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final StringThe provider name as passed to JCA.private static final String[]Name pairs mapping from SSL to Java.Fields inherited from class Properties
defaults -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncreateAliases(Map<String, String> map) Creates some aliases for an input map.private static doubleGets the names and the aliases of all message digest algorithms.getOpenSSLHashnames(Set<String> availableOpenSslAlgos) Fills a map with the names of all algorithms in OpenSSL-JNA.Methods inherited from class Provider
clear, compute, computeIfAbsent, computeIfPresent, configure, elements, entrySet, forEach, get, getInfo, getName, getOrDefault, getProperty, getService, getServices, getVersion, getVersionStr, isConfigured, keys, keySet, load, merge, put, putAll, putIfAbsent, putService, remove, remove, removeService, replace, replace, replaceAll, toString, valuesMethods inherited from class Properties
clone, contains, containsKey, containsValue, equals, getProperty, hashCode, isEmpty, list, list, load, loadFromXML, propertyNames, rehash, save, setProperty, size, store, store, storeToXML, storeToXML, storeToXML, stringPropertyNames
-
Field Details
-
PROVIDER_NAME
-
openSslMessageDigestAlgorithms
-
SSL_TO_JAVA_NAMES
Name pairs mapping from SSL to Java. First one is SSL name, second one is Java name.
-
-
Constructor Details
-
OpenSSL4JProvider
public OpenSSL4JProvider()Constructor for the JCA Provider for OpenSSL JNI.- Throws:
IllegalStateException- if the native object file can't be loaded and the class can't be used.
-
-
Method Details
-
getLibraryVersion
private static double getLibraryVersion() -
getNames
-
createAliases
Creates some aliases for an input map.- Parameters:
map- a map with keys being algorithm names of the form "MessageDigest.MD5" and the keys being java class names.- Returns:
- a map mapping from algorithm name / alias to algorithm class.
-
getOpenSSLHashnames
-