Java Security Key
Java examples for Security:Key
Click the following links for the tutorial for Security and Key.
Generating a Symmetric Key
Generating a Secret Key Using the Diffie-Hellman Key Agreement Algorithm
Generating a Message Authentication Code (MAC) Key
Listing the Aliases in a Key Store
Retrieving a Key Pair from a Key Store
Getting the Bytes of a Generated Symmetric Key
Listing All Available Symmetric Key Generators
Listing All Available Message Authentication Code (MAC) Key Generators
Generating a Parameter Set for the Diffie-Hellman Key Agreement Algorithm
Converting a KeyStroke to a String
Creating a KeyStroke and Binding It to an Action
create Key Factory by algorithm
Decrypts a string using the passed key.
Encrypts a string using the passed key.
decrypt By Private Key
decrypt By Public Key
decrypt File By Public Key
encrypt By Private Key
encrypt By Public Key
encrypt File By Private Key
encrypt File To Base By Private Key
get Key Store
get Private Key from file
get Public Key from file
sign data by key
sign File by key
Gets an RSAPublicKey from the provided PEM encoding.
get KeyStore from file and password
get Private Key from key store path and password
get Public Key from path
According publickey algorithm to do encode for data.
Get the publickey from given cert file, the certificate Path stands for cert file, should under src source folder.
trust Manager For Key Store
load KeyStore from File
sign password by key
Build secret key.
Given the name of a TLS/SSL cipher suite, return an int representing it effective stream cipher key strength.
Generates a random secret key.
generates a key pair (private key, public key).
takes bytes of PrivateKey saved in database and converts back to PrivateKey.
Decrypt a byte array given the same secret key spec used to encrypt the message
Encrypt a byte array given the secret key spec
create PBE Key
encode ECB As Hex String
encode ECB As Base String
Returns whether the Diffie-Hellman public key is valid or not.
Returns the key size of the given key object in bits.
from PKCS8 to RSAPrivateKey
load Key Store
This creates and initializes an SSLContext, using the keystore and trust store from the given streams.