How to create project RSA Cryptography with JAVA in 3 Steps: Step 1 Create User Interface

Ia Kurnia
2 min readDec 22, 2021
Photo by Markus Spiske on Unsplash

Before creating a project, what do you know about Encrypt and decrypting in a file? In brief, explanation about encrypt and decrypt we can analogy in cases
If you a send several files to someone, but only certain people which can read file your send, so that file keep the secret with encryption. And if the person wants to read a file that your send, then that person should decrypt a file with decryption.

In terms of encrypting and decrypt on a file, then needed key. Key for encrypting can be called public key and key for decrypt can be called a private key. So as not to waste time, let us do create a project about encrypt and decrypt with algorithms RSA and AES.

AES is a symmetric encryption algorithm — one key can be used to encrypt, and then decrypt the message. You need to securely share that key with the system you’re exchanging encrypted data with, otherwise other people can decrypt your data, or pretend to create encrypted data on your behalf.

RSA is an asymmetric encryption algorithm — a pair of keys is used, one you keep to yourself (private), and one you share with the rest of the world (public).

If you want more detail, you can read in this link
https://www.quora.com/How-does-RSA-and-AES-differ#:~:text=RSA%20is%20an%20asymmetric%20algorithm,parties%20share%20a%20private%20key.

#Step 1: Create Design UI

before you create a project, you must be a plan for User Interface. What kind of design can representatives about project encrypt decrypt, so that if someone uses in your application, they understand procedure or business this application or your project?

This is UI Design for encrypting decrypt with algorithm RSA

User Interface Encrypt Decrypt

First of all, you create a new project. If you use Intellij IDEA, you can follow the steps below

create a new project

Don’t forget to fill in the name of your project. If you have done, you create a new class for UI Controler, and if you have done you follow the source code below

UI Controller

Ok, that’s it for now. We can continue in the next article for process encrypt decrypt with algorithm RSA. Until next time!

--

--

Ia Kurnia

I love new technology and follow the advancements in the field. We Can Do It If We Want To Learn and Try.