Package org.conscrypt

Class CryptoUpcalls


  • final class CryptoUpcalls
    extends java.lang.Object
    Provides a place where NativeCrypto can call back up to do Java language calls to work on delegated key types from native code. Delegated keys are usually backed by hardware so we don't have access directly to the private key material. If it were a key where we can get to the private key, we would not ever call into this class.
    • Field Summary

      Fields 
      Modifier and Type Field Description
      private static java.util.logging.Logger logger  
    • Constructor Summary

      Constructors 
      Modifier Constructor Description
      private CryptoUpcalls()  
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      (package private) static byte[] ecSignDigestWithPrivateKey​(java.security.PrivateKey javaKey, byte[] message)  
      private static java.util.ArrayList<java.security.Provider> getExternalProviders​(java.lang.String algorithm)
      Finds providers that are not us that provide the requested algorithms.
      (package private) static byte[] rsaDecryptWithPrivateKey​(java.security.PrivateKey javaKey, int openSSLPadding, byte[] input)  
      private static byte[] rsaOpWithPrivateKey​(java.security.PrivateKey javaKey, int openSSLPadding, int cipherMode, byte[] input)  
      (package private) static byte[] rsaSignDigestWithPrivateKey​(java.security.PrivateKey javaKey, int openSSLPadding, byte[] message)  
      private static byte[] signDigestWithPrivateKey​(java.security.PrivateKey javaKey, byte[] message, java.lang.String algorithm)  
      • Methods inherited from class java.lang.Object

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

      • logger

        private static final java.util.logging.Logger logger
    • Constructor Detail

      • CryptoUpcalls

        private CryptoUpcalls()
    • Method Detail

      • getExternalProviders

        private static java.util.ArrayList<java.security.Provider> getExternalProviders​(java.lang.String algorithm)
        Finds providers that are not us that provide the requested algorithms.
      • ecSignDigestWithPrivateKey

        static byte[] ecSignDigestWithPrivateKey​(java.security.PrivateKey javaKey,
                                                 byte[] message)
      • signDigestWithPrivateKey

        private static byte[] signDigestWithPrivateKey​(java.security.PrivateKey javaKey,
                                                       byte[] message,
                                                       java.lang.String algorithm)
      • rsaSignDigestWithPrivateKey

        static byte[] rsaSignDigestWithPrivateKey​(java.security.PrivateKey javaKey,
                                                  int openSSLPadding,
                                                  byte[] message)
      • rsaDecryptWithPrivateKey

        static byte[] rsaDecryptWithPrivateKey​(java.security.PrivateKey javaKey,
                                               int openSSLPadding,
                                               byte[] input)
      • rsaOpWithPrivateKey

        private static byte[] rsaOpWithPrivateKey​(java.security.PrivateKey javaKey,
                                                  int openSSLPadding,
                                                  int cipherMode,
                                                  byte[] input)