I'm encrypting some data on my application with a random salt and I found out a problem like this:
- Code: Select all Expand view
- hb_crypt("@Selva123","LVLVDTWRQHVYCDTP")
hb_decrypt(hb_crypt("@Selva123","LVLVDTWRQHVYCDTP"),"LVLVDTWRQHVYCDTP")
it encrypts the data but it was not able to decrypt using the same key...
that's how I'm generating the key:
- Code: Select all Expand view
- FOR N=1 TO 16
nChar:=HB_RandomInt( 65, 90 )
cSalt+=Chr(nChar)
NEXT N
Does anybody know what is wrong?