Class NativeSecurityProvider


  • public class NativeSecurityProvider
    extends java.lang.Object
    • Field Summary

      Fields 
      Modifier and Type Field Description
      static java.lang.String PROVIDER_CLASS_PROPERTY
      System property that specifies the fully-qualified class name of a Provider to load, instantiate and register in the host JVM security framework at mock initialization time.
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static void initializeNative()
      Called by the foundation library at mock initialization.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • PROVIDER_CLASS_PROPERTY

        public static final java.lang.String PROVIDER_CLASS_PROPERTY
        System property that specifies the fully-qualified class name of a Provider to load, instantiate and register in the host JVM security framework at mock initialization time.

        The class must be available on the HIL classpath and must have a public no-argument constructor. When set, the provider is appended to the list of registered providers.

        Example (Bouncy Castle):

         ej.crypto.mock.security.provider = org.bouncycastle.jce.provider.BouncyCastleProvider
         
        See Also:
        Constant Field Values
    • Method Detail

      • initializeNative

        public static void initializeNative()
                                     throws ej.sni.NativeException
        Called by the foundation library at mock initialization. If the "ej.crypto.mock.security.provider" system property is set, loads the designated Provider from the HIL classpath, instantiates it using its no-argument constructor, and appends it to the list of registered providers in the JVM security framework.
        Throws:
        ej.sni.NativeException - if the provider class cannot be found, cast, or instantiated.