Module III : Encryption and Decryption Java Programming with Jasypt

Firstly, i want to Encrypt and Decrypt a text with java liblary Jasypt. You can see a documentation and download liblary in

I have a java project with Jasypt liblary and you can download here : DOWNLOAD

If you have a java project above, you can follow this step :

1. Open project “javaphp” with Netbeans editor.







You can see that Jasypt liblary already exist in a project. If liblary’s not working, you can remove that liblary and add again with other jasypt liblary.

Aftert that. you can open Main Class file “” right now.


Script description :

Line 5 & 6 : include class BasicTextEncryptor and class BasicPasswordEcryptor, so it can be used to make object of class.

Line 19 : define String variable with a sentence to be encrypted.

Line 21 : Create an object from class BasicTextEncryptor(), object name is “obyek_enkripsi”.

Line 23 : set password with setPassword method from class, that password’s required to encrypt and decrypt text.

Line 24 : get encrypt text and store in “tampungan” variable that define in line 20.

Line 26 : print encypt data

Line 28 : get decrypt text from ecrypted text in line 24, and sore in “hasil” variable.

Line 29 : print decyrpt data

Try with Run this program.!!



About blackphp

All about programming php, ajax, jquery, mysql, etc, tips n trick. Now, i'm concern in php programming with codeigniter framework n also training my design skill with photoshop or corel... wish me luck! ('o')

Posted on December 8, 2012, in Java Programming, Materi Kuliah and tagged , , , , , , , , , . Bookmark the permalink. 3 Comments.

  1. your file in ziddu not found

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: