Need help with a rsaenh bug

Daniel Jeliński djelinski1 at
Thu Jun 27 14:43:30 CDT 2013

It is definitely valid to call CryptDecrypt multiple times with the same
key. Calls with Final = FALSE change the internal state of the key, calls
with Final = TRUE restore the initial state. Subsequent calls with Final =
TRUE should return the same result.

Your testcase fails because CryptDecrypt changes the value of dwLen, which
you do not restore before calling the function again.


2013/6/27 Qian Hong <fracting at>

> Hello,
> I was investigating Bug 33898 [1] hardly and get a partial result, I
> have a special test case demonstrate the behavior of Aliwangwang [2],
> however, I failed to expand the special case to a common test case. My
> attempting is shown in [3]. The hack in [3] works for Aliwangwang, but
> the test case in [3] doesn't fully pass on Windows as I expected [4].
> I'm not sure if there is an APP bug rather than Wine bug here, is it
> valid to call multiple CryptDecrypt with only one CryptDeriveKey
> called? If true, is it correct to assume the second CryptDecrypt call
> should behavior identical as the first one?
> If there is a Wine bug here, what is the right way to write a common
> test case for it?
> Any hints on this bug is great appreciated!
> Thanks very much!
> [1]
> [2]
> [3]
> [4]
> --
> Regards,
> Qian Hong
> -
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <>

More information about the wine-devel mailing list