org.apache.sshd.common.util
Class SecurityUtils

java.lang.Object
  extended by org.apache.sshd.common.util.SecurityUtils

public class SecurityUtils
extends java.lang.Object

TODO Add javadoc

Author:
Apache MINA SSHD Project

Field Summary
static java.lang.String BOUNCY_CASTLE
           
 
Constructor Summary
SecurityUtils()
           
 
Method Summary
static javax.crypto.Cipher getCipher(java.lang.String transformation)
           
static javax.crypto.KeyAgreement getKeyAgreement(java.lang.String algorithm)
           
static java.security.KeyFactory getKeyFactory(java.lang.String algorithm)
           
static java.security.KeyPairGenerator getKeyPairGenerator(java.lang.String algorithm)
           
static javax.crypto.Mac getMac(java.lang.String algorithm)
           
static java.security.MessageDigest getMessageDigest(java.lang.String algorithm)
           
static java.lang.String getSecurityProvider()
           
static java.security.Signature getSignature(java.lang.String algorithm)
           
static boolean isBouncyCastleRegistered()
           
static void setRegisterBouncyCastle(boolean registerBouncyCastle)
           
static void setSecurityProvider(java.lang.String securityProvider)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

BOUNCY_CASTLE

public static final java.lang.String BOUNCY_CASTLE
See Also:
Constant Field Values
Constructor Detail

SecurityUtils

public SecurityUtils()
Method Detail

setSecurityProvider

public static void setSecurityProvider(java.lang.String securityProvider)

setRegisterBouncyCastle

public static void setRegisterBouncyCastle(boolean registerBouncyCastle)

getSecurityProvider

public static java.lang.String getSecurityProvider()

isBouncyCastleRegistered

public static boolean isBouncyCastleRegistered()

getKeyFactory

public static java.security.KeyFactory getKeyFactory(java.lang.String algorithm)
                                              throws java.security.NoSuchAlgorithmException,
                                                     java.security.NoSuchProviderException
Throws:
java.security.NoSuchAlgorithmException
java.security.NoSuchProviderException

getCipher

public static javax.crypto.Cipher getCipher(java.lang.String transformation)
                                     throws java.security.NoSuchAlgorithmException,
                                            javax.crypto.NoSuchPaddingException,
                                            java.security.NoSuchProviderException
Throws:
java.security.NoSuchAlgorithmException
javax.crypto.NoSuchPaddingException
java.security.NoSuchProviderException

getMessageDigest

public static java.security.MessageDigest getMessageDigest(java.lang.String algorithm)
                                                    throws java.security.NoSuchAlgorithmException,
                                                           java.security.NoSuchProviderException
Throws:
java.security.NoSuchAlgorithmException
java.security.NoSuchProviderException

getKeyPairGenerator

public static java.security.KeyPairGenerator getKeyPairGenerator(java.lang.String algorithm)
                                                          throws java.security.NoSuchAlgorithmException,
                                                                 java.security.NoSuchProviderException
Throws:
java.security.NoSuchAlgorithmException
java.security.NoSuchProviderException

getKeyAgreement

public static javax.crypto.KeyAgreement getKeyAgreement(java.lang.String algorithm)
                                                 throws java.security.NoSuchAlgorithmException,
                                                        java.security.NoSuchProviderException
Throws:
java.security.NoSuchAlgorithmException
java.security.NoSuchProviderException

getMac

public static javax.crypto.Mac getMac(java.lang.String algorithm)
                               throws java.security.NoSuchAlgorithmException,
                                      java.security.NoSuchProviderException
Throws:
java.security.NoSuchAlgorithmException
java.security.NoSuchProviderException

getSignature

public static java.security.Signature getSignature(java.lang.String algorithm)
                                            throws java.security.NoSuchAlgorithmException,
                                                   java.security.NoSuchProviderException
Throws:
java.security.NoSuchAlgorithmException
java.security.NoSuchProviderException


Copyright © 2008-2012 The Apache Software Foundation. All Rights Reserved.