• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

MD5 encryption and decryption

 
venugopal velvadapu
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
i am using JavaTM Cryptography Extension 1.2.2

i am unable to generate key for HmacMD5

my code is :

key = KeyGenerator.getInstance("HmacMD5").generateKey();


error is :

Exception in thread "main" java.security.NoSuchAlgorithmException: Cannot find any provider supporting HmacMD5
at javax.crypto.Cipher.getInstance(DashoA6275)
at Sample.DataEncrypter.setUp(DataEncrypter.java:30)
at Sample.DataEncrypter.main(DataEncrypter.java:5


help me please ..............
 
Lasse Koskela
author
Sheriff
Posts: 11962
5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Apparently you don't have such an implementation available in your classpath.

Try this tip from the Java Developer's Almanac to print out all message digest algorithms available in your classpath. If you need some specific algorithm that's missing, try and see if BouncyCastle has it.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic