Archived Forum Post

Index of archived forum posts

Question:

Encrypt the run time data from user

Feb 14 '14 at 17:05

Hello,

I want to Encrypt the string which user enters during the run time. I don't want to encrypt the default string as given below. Can someone help me with this?

const char * encStr; cout << "!!!!!AES Encryption & Decryption!!!!!" << endl; encStr = crypt.encryptStringENC("The quick brown fox jumps over the lazy dog."); cout << endl; cout << "ENCRYPTED message: " << endl; printf("%sn",encStr);

//  Now decrypt:
const char * decStr;
decStr = crypt.decryptStringENC(encStr);
cout << endl;
cout << "DECRYPTED message: " << endl;
printf("%s\n",decStr);