Is the Diffie-Hellman Key exchange algorithm available in java?

Hi expert,

Is the Diffie-Hellman Key exchange algorithm available in java?  If so, can someone show me some example codes?

Thanks,
4eyes
4eyesgirlAsked:
Who is Participating?
 
CEHJCommented:
What would you use it for?
0
 
4eyesgirlAuthor Commented:
to exchange symmetric key for two party to communicate securely
0
Keep up with what's happening at Experts Exchange!

Sign up to receive Decoded, a new monthly digest with product updates, feature release info, continuing education opportunities, and more.

 
CEHJCommented:
Why not just use secure sockets - it'd be much easier?
0
 
4eyesgirlAuthor Commented:
I already write the code to use 3DES to encrypt and decrypt the code, so I think I only need to use Diffie-Hellman to generate a key set and will integrate it with the 3DES codes.  

I checked out the link below and it looks to me this is not so hard to do, am I wrong?
http://www.microsoft.com/technet/prodtechnol/windows2000serv/reskit/distrib/dsch_key_xihm.mspx?mfr=true

Just wondering if Java.secure support this algorithm and if so, how does it work.

0
 
CEHJCommented:
Key exchange algos are already an internal part of SSL so whatever way you look at it, it's going to be easier for you just to use secure sockets
0
 
4eyesgirlAuthor Commented:
Okay, I see.  

As you probably aware, I am trying to learn the security concept here.

Does the SSL implements by using the crytography algorithm such as AES, RSA, etc...And it also uses the key exchange algorithm intenrally.  

So who should use java.security.*?  I am a bit confused.  In this case, everyone should use SSL but not the java.security.* classes?
0
 
4eyesgirlAuthor Commented:
CEJH -

I guess I have to reward objects the point this time as he provides the answer that I am looking for.

But I do like the fact that you try to find me a better solution.  So I will open a new question related to SSL.

Thanks
0
 
CEHJCommented:
>>So I will open a new question related to SSL.

Well we're back to the issue we had before. It's better to reopen this question and sometimes the only way that accords with site rules. We can discuss the purposes of these libraries further
0
 
4eyesgirlAuthor Commented:
This is kind of different because it is not really the same question.  My original question is to get an example of Diffi-Hallman codes and you provide other suggestion which is unrelated to this topic.

I think it is a different scenario.
0
 
CEHJCommented:
Yes, it depends on what your objective is. If you want to transmit data to someone without a third party being able to read it then all you need is SSL
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.