[PATCH 2/2] bcrypt: Return STATUS_INVALID_PARAMETER when invalid flag passed to BCryptCreateHash.

Hans Leidekker hans at codeweavers.com
Tue Mar 5 04:07:00 CST 2019


On Tue, 2019-03-05 at 20:33 +1100, Brendan McGrath wrote:
> OK - so it should return STATUS_NOT_IMPLEMENTED when 
> BCRYPT_HASH_REUSABLE_FLAG is passed and STATUS_INVALID_PARAMETER otherwise?

Yes, though note that your test is not exhaustive, it checks just one
flag while your fix rejects all of them. There might be undocumented
flags, and there's always the possibility that new flags are added.

It's very unlikely that applications depend on the exact error code, so
it's not worth spending a lot of time getting these checks exactly
right.




More information about the wine-devel mailing list