Encryption and Decryption using Advapi32.dll
843811Sep 21 2009 — edited Dec 8 2009Hi,
I am new to Encryption and Decryption concepts. We have a J2C connector which connects a web application to a VB C/S application. The C/S application uses ADVAPI32.dll cryptography to encrypt the communiction between itself and the connector. The J2C connector / resource adapter needs to be deployed in Linux too so using libraries like JInovke is not a solution. The solution needs to be a pure java solution (not using JNI) which can read and write encrypted messages to the C/S application.
Here are the steps :
CryptCreateHash
cryptHashData
CryptDeriveKey
CryptEncrypt
CryptDestroyKey
CryptDestroyHash
CryptReleaseContext
You can find the documenation of the above in msdn link : http://msdn.microsoft.com/en-us/library/aa379886(VS.85).aspx
Basically I am confued about as the above steps applied in C/S end first Hashes a key and then generates a key from the Hash. Is there any available api which can do the equivalent hashing and generate a key. The communication is to and fro - both end.