LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices

Reply
 
LinkBack Search this Thread
Old 09-03-2007, 12:42 PM   #1
me4linux
Member
 
Registered: Aug 2006
Distribution: Fedora 7
Posts: 165

Rep: Reputation: 30
How to encrypt a string in Java


Hi all

I have got some code from net abt encrypting a string using jce..
but it uses Base64Encoder.... i dont have this package..?
how to get this package...?

Is there any other way to encrypt a string say
String username = new String("fedora");

i need to encrypt this String username....

Can any one Please tell me the code to do this..

THANKS IN ADVANCE
 
Old 09-03-2007, 03:30 PM   #2
jlliagre
Moderator
 
Registered: Feb 2004
Location: Outside Paris
Distribution: Solaris10, Solaris 11, Ubuntu, OEL
Posts: 9,165

Rep: Reputation: 243Reputation: 243Reputation: 243
Base64 isn't about encryption but encoding.

There is no official way to encode/decode even while there are a couple of classes in the JVM that provide this functionality.

http://bugs.sun.com/bugdatabase/view...bug_id=4235519
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
encrypt and decrypt using encrypt(char block[64], int edflag) rockwell_001 Linux - Security 3 08-30-2009 09:16 AM
Getting a class From a String in Java MRMadhav Programming 5 02-18-2006 05:50 AM
java test if string in string array is null. exodist Programming 3 02-21-2004 01:39 PM
My basic encrypt/uncrypt program... break; breaks when not supposed 2 in java Laptop2250 Programming 8 01-20-2004 09:14 PM
java + string tokenizer dave bean Programming 2 12-10-2003 03:22 PM


All times are GMT -5. The time now is 03:25 PM.

Main Menu
 
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: @linuxquestions
Open Source Consulting | Domain Registration