Class OpenSslJna

java.lang.Object
org.apache.commons.crypto.jna.OpenSslJna

public final class OpenSslJna extends Object
Provides access to package protected class objects and a main(String[]) method that prints version information.
  • Field Details

  • Constructor Details

    • OpenSslJna

      public OpenSslJna()
  • Method Details

    • debug

      static void debug(Object format, Object... args)
      Logs debug messages.
      Parameters:
      format - See String.format(String, Object...).
      args - See String.format(String, Object...).
    • getCipherClass

      public static Class<? extends CryptoCipher> getCipherClass()
      Returns:
      The cipher class of JNA implementation
    • getRandomClass

      public static Class<? extends CryptoRandom> getRandomClass()
      Returns:
      The random class of JNA implementation
    • info

      private static void info(String format, Object... args)
      Logs info-level messages.
      Parameters:
      format - See String.format(String, Object...).
      args - See String.format(String, Object...).
    • initialisationError

      public static Throwable initialisationError()
      Returns:
      the error of JNA
    • isEnabled

      public static boolean isEnabled()
      Returns:
      true if JNA native loads successfully
    • main

      public static void main(String[] args) throws Throwable
      Throws:
      Throwable
    • OpenSSLVersion

      static String OpenSSLVersion(int type)
      Retrieves version/build information about OpenSSL library.
      Parameters:
      type - type can be OPENSSL_VERSION, OPENSSL_CFLAGS, OPENSSL_BUILT_ON...
      Returns:
      A pointer to a constant string describing the version of the OpenSSL library or giving information about the library build.