Can you send some example code?

Or as a quick test create 2 instances of your MyCrypto class in each
program and have one handle encryption and one decryption exclusively.
This is to exclude a potential of race conditions in your own code.
(And make sure MyCrypto instances don't have any shared data in the
test).

On Dec 11, 5:19 pm, Walter Villalba <[email protected]> wrote:
> *Point 2: Crypto++ linked statically, multiple encryptor/decryptor objects,
> crashes*
> In a previous implementation I did , I had the following configuration:
>
> Class MyCrypto, which is based on Crypto++.   This class has one encryptor
> and one decryptor objects ( AES, CFB ).
> Program A: one MyCrypto object.
> Program B: one MyCrypto object.
>
> Both programs run at the same time, encrypting/decrypting data sent/received
> over the Internet.   As I've mentioned before, one takes care of the audio
> and the other one takes care of some other data.  For some reason, this
> configuration made one of the programs crash.   As a workaround, I added a
> mutex to assure mutually exclusive encryption/decryption operations for both
> programs, and the problem went away.   I think the reason might be that both
> objects relied on some shared structure/data used within Crypto++, but I'm
> not sure.   Can any of you confirm this theory ?   Please let me know if you
> need more details on this, as it'd be great to get rid of the mutex code, if
> possible.
>
> I know the scenario is not the simplest one, so don't hesitate to ask for
> more details.
>
> Thanks,
> Walt.

-- 
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