Hi Guys....I am facing decrypting a binary file which is encrypted
843811Dec 12 2008 — edited Dec 27 2008I am facing decrypting a binary file which is encrypted in C++ code. They use FULL RSA Service provider
wiht MD5 , TripleDES algorithms....i did the same in java to decrypt the file..but i am getting padding exception
javax.crypto.BadPaddingException: Given final block not properly padded
I am new to this group and topic...Anyhelp is greately appreciated..
C++ windows inbuilt methods for your idea to know what they use..
--------------------------------------------------------------------------------
CryptAcquireContext (&hProv, NULL, NULL, PROV_RSA_FULL, CRYPT_NEWKEYSET)
CryptGenKey (hProv, CALG_3DES, CRYPT_EXPORTABLE, &hKey))
CryptGetUserKey (hProv, AT_KEYEXCHANGE, &hXchgKey))
CryptGenKey(hProv,AT_KEYEXCHANGE,NULL,&hXchgKey))
CryptExportKey (hKey, hXchgKey, SIMPLEBLOB, 0, pbKeyBlob, &dwKeyBlobLen))
CryptEncrypt(hKey, 0, endOfData, 0, pData, dataLength, *bufSize))
please tell me how to implemnet the same in java...
Thanks in advance,
MSM
Edited by: MuppidiJava on Dec 13, 2008 2:56 AM