WineHQ
Bug Tracking Database – Bug 34921

 Bugzilla

 

Last modified: 2016-12-05 20:18:04 UTC  

Multiple games and applications need bcrypt.dll.BCryptGenRandom (Need for Speed: The Run, Battlefield 3)

Bug 34921 - Multiple games and applications need bcrypt.dll.BCryptGenRandom (Need for Speed: The Run, Battlefield 3)
Multiple games and applications need bcrypt.dll.BCryptGenRandom (Need for Spe...
Status: CLOSED FIXED
AppDB: Show Apps affected by this bug
Product: Wine
Classification: Unclassified
Component: bcrypt
1.7.6
x86 Linux
: P2 normal
: ---
Assigned To: Bruno Jesus
: patch
Depends on:
Blocks:
  Show dependency tree
 
Reported: 2013-11-15 09:01 UTC by Andrey Gusev
Modified: 2016-12-05 20:18 UTC (History)
3 users (show)

See Also:
Regression SHA1:
Fixed by SHA1: a7578c7ae7ef1aa7bc2e8d0846a0bfc60bc664a2
Distribution: ---
Staged patchset:


Attachments
log (3.96 KB, text/plain)
2013-11-15 09:01 UTC, Andrey Gusev
Details
bad implementation (1.02 KB, patch)
2013-11-15 09:39 UTC, Bruno Jesus
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Andrey Gusev 2013-11-15 09:01:27 UTC
Created attachment 46535 [details]
log

Crashes at start.
Comment 1 Bruno Jesus 2013-11-15 09:39:02 UTC
Created attachment 46536 [details]
bad implementation

I needed this function for other program, I ended up writing a very simple implementation that at least helped me. I could not find it so I rewrote it, it was not tested.
Comment 2 Nikolay Sivov 2013-11-15 12:45:07 UTC
It'd be interesting to see +relay with this implementation to get some info on function arguments.
Comment 3 Andrey Gusev 2013-11-15 13:28:50 UTC
(In reply to comment #1)
> Created attachment 46536 [details]
> bad implementation
> 
> I needed this function for other program, I ended up writing a very simple
> implementation that at least helped me. I could not find it so I rewrote it, it
> was not tested.

Bruno, I confirm that your patch fixes the problem. After that way goes to bug 24517.
Comment 4 Nikolay Sivov 2013-11-15 14:13:35 UTC
Andrey, could you please attach +relay log with this patch?
Comment 5 Bruno Jesus 2013-11-15 15:46:02 UTC
(In reply to comment #2)
> It'd be interesting to see +relay with this implementation to get some info on
> function arguments.

I think it was called with a NULL algorithm and with dwFlags & BCRYPT_USE_SYSTEM_PREFERRED_RNG.

Because otherwise it would have needed to call BCryptOpenAlgorithmProvider which is also not implemented.

This guessing is based on information from http://msdn.microsoft.com/en-us/library/Windows/desktop/aa375458%28v=vs.85%29.aspx
Comment 6 Andrey Gusev 2013-11-15 16:13:22 UTC
(In reply to comment #4)
> Andrey, could you please attach +relay log with this patch?

Can send to you directly, because of archive size is 1.1 Mb.
Comment 7 Henri Verbeet 2013-11-18 10:58:44 UTC
As an aside, did we ever look into using Nettle or perhaps gcrypt for implementing things like e.g. rsaenh and bcrypt?
Comment 8 Linards 2013-12-26 07:40:06 UTC
Same function is needed by Battlefield 3.
Comment 9 Anastasius Focht 2013-12-26 08:02:07 UTC
Hello folks,

--- quote ---
Same function is needed by Battlefield 3.
--- quote ---

refining summary and confirming.

Regards
Comment 10 Linards 2013-12-26 09:10:18 UTC
(In reply to comment #5)
> (In reply to comment #2)
> > It'd be interesting to see +relay with this implementation to get some info on
> > function arguments.
> 
> I think it was called with a NULL algorithm and with dwFlags &
> BCRYPT_USE_SYSTEM_PREFERRED_RNG.
> 
> Because otherwise it would have needed to call BCryptOpenAlgorithmProvider
> which is also not implemented.
> 
> This guessing is based on information from
> http://msdn.microsoft.com/en-us/library/Windows/desktop/aa375458%28v=vs.
> 85%29.aspx

Simply put Wine do not conbtaint at least minimum support for Windows Vista amd later introduced infrastructure: "Microsoft Windows Cryptographic Primitives Library" . WOuld this be a superset of Crypt32.dll ( Cryptographic Services )?
Comment 11 Andrey Gusev 2014-01-04 15:17:28 UTC
Should help http://source.winehq.org/patches/data/101409
Comment 13 Andrey Gusev 2014-02-07 17:59:27 UTC
Tested with 1.7.12 and it's fixed. As I said before the next stop is bug 24517.
Comment 14 Alexandre Julliard 2014-02-20 12:37:49 UTC
Closing bugs fixed in 1.7.13.


Privacy Policy
If you have a privacy inquiry regarding this site, please write to [email protected]

Hosted By CodeWeavers