Posts

Showing posts from April, 2017

Let's Create an Encryption Software

Image
Hi, Everyone! This tutorial is to demonstrate how to encrypt and decrypt in Java using the Java Cryptography Extension (JCE). Symmetric key and asymmetric key are the two basic types of cryptographic systems. They are also called as “secret key” and “public key” cryptography. One of the success factors to Java is attributed to the strong security it provides to the platform and applications.In this tutorial, we will see a simple example on using the “secret key” cryptography with JCE. Symmetric Key Cryptography Symmetric (secret) key uses the same key for encryption and decryption. The main challenge with this type of cryptography is the exchange of the secret key between the two parties sender and receiver. In the following example, we will use the encryption and decryption algorithm available as part of the JCE SunJCE provider. AES Symmetric Key Encryption   In Java 8 we have got new classes in java.util package for Base64 encoding and decoding. It is important to...