Hi Wei,

When I did not set the key/iv, I caught the exception "unencrypted
authenticated data cannot be input after encrypted data".

Jeff

EAX< AES >::Encryption enc;
//enc.SetKeyWithIV( key, sizeof(key), iv, sizeof(iv) );

AuthenticatedEncryptionFilter aef( enc,
    new StringSink( ciphertext )
); // AuthenticatedEncryptionFilter

aef.Put( (const byte*)plaintext.data(), plaintext.size() );
aef.MessageEnd();

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the "Crypto++ Users" 
Google Group.
To unsubscribe, send an email to [email protected].
More information about Crypto++ and this group is available at 
http://www.cryptopp.com.
-~----------~----~----~----~------~----~------~--~---

Reply via email to