https://bugs.winehq.org/show_bug.cgi?id=44061
Bug ID: 44061 Summary: Destiny 2 crashes on launch Product: Wine Version: 2.21 Hardware: x86-64 OS: Linux Status: UNCONFIRMED Severity: normal Priority: P2 Component: -unknown Assignee: wine-bugs@winehq.org Reporter: zombieff@gmail.com Distribution: ArchLinux
Created attachment 59774 --> https://bugs.winehq.org/attachment.cgi?id=59774 Crash report shown by the app
The game "Destiny 2" crashes on launch.
It installs successfully via Blizzard client, but crashes on launch.
There's a delay between "Launching" → "Ready to Launch" (not launched) → crashed with an error.
Tested on Arch Linux.
Wine version is wine-2.21 (Staging).
Terminal output (app crash report is in the attachment):
fixme:thread:create_user_shared_data_thread Creating user shared data update thread. fixme:heap:RtlSetHeapInformation (nil) 1 (nil) 0 stub fixme:crypt:CRYPT_LoadProvider Failed to load dll L"C:\windows\system32\rsaenh.dll" fixme:seh:call_stack_handlers nested exception wine: Unhandled exception 0xc06d007e in thread 556 at address 0x7b450c67 (thread 0556), starting debugger... fixme:module:load_dll Loader redirect from L"uxtheme.dll" to L"uxtheme-gtk.dll" fixme:module:load_dll Loader redirect from L"uxtheme.dll" to L"uxtheme-gtk.dll" fixme:msg:pack_message msg 14 (WM_ERASEBKGND) not supported yet fixme:uxthemegtk:SetWindowTheme (0xf0054, (null), (null))
https://bugs.winehq.org/show_bug.cgi?id=44061
Marty Delaney martydelaney3@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |martydelaney3@gmail.com
--- Comment #1 from Marty Delaney martydelaney3@gmail.com --- I have experienced the exact same issue on launching Destiny 2 on my system. I am also running wine-2.21 (Staging)
fixme:thread:create_user_shared_data_thread Creating user shared data update thread. fixme:heap:RtlSetHeapInformation (nil) 1 (nil) 0 stub fixme:crypt:CRYPT_LoadProvider Failed to load dll L"C:\windows\system32\rsaenh.dll" fixme:seh:call_stack_handlers nested exception wine: Unhandled exception 0xc06d007e in thread ce at address 0x7b450537 (thread 00ce), starting debugger...
https://bugs.winehq.org/show_bug.cgi?id=44061
Robert Walker bob.mt.wya@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |bob.mt.wya@gmail.com
https://bugs.winehq.org/show_bug.cgi?id=44061
Kimmo Myllyvirta kimmo.myllyvirta@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |kimmo.myllyvirta@gmail.com
--- Comment #2 from Kimmo Myllyvirta kimmo.myllyvirta@gmail.com --- Created attachment 61124 --> https://bugs.winehq.org/attachment.cgi?id=61124 hacks for wine staging
Here's some notes. Bungie banned my account, apparently for trying to get this working on wine, so I can't debug this any further.
See also bug 44585, this is another app which needs ldr notifications. The staged implementation seems to work, but call_dll_entry_point is failing for multiple dlls after destiny 2 has called LdrRegisterDllNotification. This is just the peak of the iceberg; fixme:crypt:CRYPT_LoadProvider Failed to load dll L"C:\windows\system32\rsaenh.dll"
At least it is replacing the entry points. What the entry point (rsaenh) was before the ldr callback, your usual __wine_spec_dll_entry; movq %rsp,%rbp pushq %rdi pushq %rsi pushq %rbx subq $0xa0,%rsp andq $fffffff0,%rsp subq $30,%rsp cmpl $1,%edx movups %xmm6,0xffffffffffffff48(%rbp) ...
And what the entry point is after call_ldr_notifications, notify->callback(reason, &data, notify->context);
xorl %eax,%eax cmpl $1,%edx setnz %al ret inb %dx,%al movb 0x0000000048000000,%al andl $fffffff0,%esp subq $30,%rsp cmpl $1,%edx movups %xmm6,0xffffffffffffff48(%rbp) ...
So, it replaces couple of bytes from the beginning, no idea what it is trying to achieve here, but this will definitely fail. It runs further if the ldr callback is not called in MODULE_InitDLL.
Other notes, not really related to this bug: - dxgi_device_SetMaximumFrameLatency needs better stub: destiny 2 will throw you "Graphics initialization failed" -messagebox and exit, if SetMaximumFrameLatency doesn't return S_OK. - It needs kernel32 GetCurrencyFormatEx (stub) implementation. - Native (and working) .NET is needed for miniTicketDbg.exe. It seems to be a crash reporter/watchdog or similar, Destiny 2 will just exit if miniTicketDbg fails to start. - WTHelperGetProvCertFromChain crashes, it should check for for null pSgnr (or I'm just fixing symptoms here, not the cause)
Anyways, here's some hacks to get it running for those who are brave enough to debug it further (it won't go in-game yet).
https://bugs.winehq.org/show_bug.cgi?id=44061
Alistair Leslie-Hughes leslie_alistair@hotmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |GloriousEggroll@gmail.com, | |leslie_alistair@hotmail.com | |, z.figura12@gmail.com
https://bugs.winehq.org/show_bug.cgi?id=44061
tokktokk fdsfgs@krutt.org changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |fdsfgs@krutt.org
https://bugs.winehq.org/show_bug.cgi?id=44061
--- Comment #3 from GloriousEggroll@gmail.com --- Destiny 2 has a free trial currently if anyone's willing to try getting this to work :|
https://bugs.winehq.org/show_bug.cgi?id=44061
--- Comment #4 from GloriousEggroll@gmail.com --- Hi guys. I made a burner account and managed to get in game. Currently randomly crashing due to an AL audio bug I think:
AL lib: (EE) ReleaseThreadCtx: Context 0x7f5b18049e70 current for thread being destroyed, possible leak! AL lib: (EE) ReleaseThreadCtx: Context 0x7f5b18049e70 current for thread being destroyed, possible leak!
With current wine staging (3.18 currently) I only used the loader.c patch from Kimmo as everything else is already implemented.
Set wine to use win10 in winecfg,
Use this version of winetricks (sorry its an AUR PKGBUILD) to install dotnet472: https://github.com/Tk-Glitch/PKGBUILDS/tree/master/winetricks-tkg-git
and use latest DXVK
as I said, I am able to get in game but it's randomly crashing a LOT due to that AL lib error mentioned above
https://bugs.winehq.org/show_bug.cgi?id=44061
--- Comment #5 from GloriousEggroll@gmail.com --- Created attachment 62573 --> https://bugs.winehq.org/attachment.cgi?id=62573 modified kimmo patch for 3.18 staging
https://bugs.winehq.org/show_bug.cgi?id=44061
--- Comment #6 from GloriousEggroll@gmail.com --- (In reply to GloriousEggroll from comment #4)
Hi guys. I made a burner account and managed to get in game. Currently randomly crashing due to an AL audio bug I think:
AL lib: (EE) ReleaseThreadCtx: Context 0x7f5b18049e70 current for thread being destroyed, possible leak! AL lib: (EE) ReleaseThreadCtx: Context 0x7f5b18049e70 current for thread being destroyed, possible leak!
With current wine staging (3.18 currently) I only used the loader.c patch from Kimmo as everything else is already implemented.
Set wine to use win10 in winecfg,
Use this version of winetricks (sorry its an AUR PKGBUILD) to install dotnet472: https://github.com/Tk-Glitch/PKGBUILDS/tree/master/winetricks-tkg-git
and use latest DXVK
as I said, I am able to get in game but it's randomly crashing a LOT due to that AL lib error mentioned above
also Kimmo I think the reason for the ban was possibly due to modifying dxgi. D2 has a very picky anti-cheat and in particular with graphics. On windows you can't even capture the game in OBS or insert any kind of reshade or overlay or performance monitoring software.
https://bugs.winehq.org/show_bug.cgi?id=44061
--- Comment #7 from GloriousEggroll@gmail.com --- one last minor note - I did another test on a fresh prefix, turns out you dont need dotnet472 at all. you do need vcrun2017
https://bugs.winehq.org/show_bug.cgi?id=44061
--- Comment #8 from GloriousEggroll@gmail.com --- welp. sure enough. I caught the banhammer as well. Logged in today and my test account was banned.
https://bugs.winehq.org/show_bug.cgi?id=44061
mirh mirh@protonmail.ch changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |mirh@protonmail.ch
--- Comment #9 from mirh mirh@protonmail.ch --- If the game launches now, I see no reason to keep this open. They are giving it away for free for a couple of weeks, so there couldn't be a better time to check/fix this btw.
p.s. OAL errors might improve with FAudio
https://bugs.winehq.org/show_bug.cgi?id=44061
Louis Lenders xerox.xerox2000x@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |xerox.xerox2000x@gmail.com Ever confirmed|0 |1 Status|UNCONFIRMED |NEW Keywords| |patch
--- Comment #10 from Louis Lenders xerox.xerox2000x@gmail.com --- (In reply to mirh from comment #9)
If the game launches now, I see no reason to keep this open. They are giving it away for free for a couple of weeks, so there couldn't be a better time to check/fix this btw.
p.s. OAL errors might improve with FAudio
Does the game really launch? There were just 2 testreports in appdb rating garbage for this game. I think I will try myself, but the download is 80 Gb.
Anyway, confirmed by many and adding patch keyword
https://bugs.winehq.org/show_bug.cgi?id=44061
--- Comment #11 from GloriousEggroll@gmail.com --- (In reply to mirh from comment #9)
If the game launches now, I see no reason to keep this open. They are giving it away for free for a couple of weeks, so there couldn't be a better time to check/fix this btw.
p.s. OAL errors might improve with FAudio
commenting out that callback is not the correct way to resolve this. yes, it gets the game to launch, but it is not by any means a proper fix for the game. the game still crashes regardless within 1-2 minutes of play. presumably either because of audio or because of the callback problem
https://bugs.winehq.org/show_bug.cgi?id=44061
--- Comment #12 from GloriousEggroll@gmail.com --- also, DO NOT try this on any main account or paid items account, you will get banned without a doubt. If you are prepared to have your account banned by using the patch in order to debug it or fix the patch, by all means do so to help others in the future. But if you are just looking to play the game, do not attempt this.
https://bugs.winehq.org/show_bug.cgi?id=44061
blargle.ragequit@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |blargle.ragequit@gmail.com
https://bugs.winehq.org/show_bug.cgi?id=44061
pattietreutel katyaberezyaka@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |katyaberezyaka@gmail.com
https://bugs.winehq.org/show_bug.cgi?id=44061
dereklesho52@Gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |dereklesho52@Gmail.com
--- Comment #13 from dereklesho52@Gmail.com --- Created attachment 65218 --> https://bugs.winehq.org/attachment.cgi?id=65218 New Destiny 2 Log
https://bugs.winehq.org/show_bug.cgi?id=44061
--- Comment #14 from dereklesho52@Gmail.com --- I tried debugging this issue further, and it appears that a new issue has popped up.
Before the callback it passes in is called, the program fails when it tries to execute an unmapped area of memory
seh:NtRaiseException code=c0000005 flags=0 addr=0xe760ac ip=e760ac tid=0122 seh:NtRaiseException info[0]=0000000000000008 seh:NtRaiseException info[1]=0000000000e760ac seh:NtRaiseException rax=0000000000e50000 rbx=000000007bd78668 rcx=fffffffffffffffe rdx=0000000000000011 seh:NtRaiseException rsi=000000007bc20040 rdi=000000000000050a rbp=000000000052d480 rsp=000000000052d378 seh:NtRaiseException r8=0000000000000000 r9=0000000000000000 r10=0000000000e760ac r11=000000000000012c seh:NtRaiseException r12=000000007bc20000 r13=0000000000000040 r14=000000007bd75e18 r15=000000007bd79a90
In a relay log, before this occurs, it appears to allocate some memory close to where this exception occurs:
0121:0122:Call KERNEL32.VirtualAlloc(00000000,0000f3b4,00001000,00000040) ret=14028e00c 0121:0122:Ret KERNEL32.VirtualAlloc() retval=00e50000 ret=14028e00c
However, - This memory size isn't large enough to reach the point where they execute - They subsequently protect the memory as read-only before the exception happens
0121:0122:Call KERNEL32.VirtualProtect(00e50000,0000f3b4,00000020,0052d4f0) ret=14028e0af 0121:0122:Ret KERNEL32.VirtualProtect() retval=00000001 ret=14028e0af
I suspect that the execution is intended to happen within this allocation, and that the f3b4 it puts in for the size isn't correct. Although the VirtualProtect call seems to suggest otherwise.
Full log is attached
https://bugs.winehq.org/show_bug.cgi?id=44061
Zebediah Figura z.figura12@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC|z.figura12@gmail.com |
https://bugs.winehq.org/show_bug.cgi?id=44061
Ker noa blue-t@web.de changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |blue-t@web.de
--- Comment #15 from Ker noa blue-t@web.de --- This game still crashes with 5.11-staging today.
https://bugs.winehq.org/show_bug.cgi?id=44061
Anya animegirl@stronzi.org changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |animegirl@stronzi.org
https://bugs.winehq.org/show_bug.cgi?id=44061
Thomas Kowaliczek linuxdonald@posteo.de changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |linuxdonald@posteo.de
https://bugs.winehq.org/show_bug.cgi?id=44061
David Torok dt@zeroitlab.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |dt@zeroitlab.com
https://bugs.winehq.org/show_bug.cgi?id=44061
--- Comment #16 from David Torok dt@zeroitlab.com --- Created attachment 68531 --> https://bugs.winehq.org/attachment.cgi?id=68531 Proof of concept patch to get Destiny ingame
The root cause here, is that Destiny checks the TimeDateStamp field of any loaded dlls, and wants the values to be non-zero. The attached patch solves this for wine's fakedlls. Usually DXVK is a preferred part of any setup, which also has TimeDateStamp values of 0 in it's modules. For now, you may patch these manually to get ingame, otherwise an upstream solution (for the DXVK part) is being worked on.
https://bugs.winehq.org/show_bug.cgi?id=44061
Cláudio Sampaio (Patola) patola@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |patola@gmail.com
https://bugs.winehq.org/show_bug.cgi?id=44061
--- Comment #17 from Ker noa blue-t@web.de --- Created attachment 68532 --> https://bugs.winehq.org/attachment.cgi?id=68532 CrashLog with the faketime patch
With the test patch i get a different warning before the game crashes. It obviously tries to validate game files and fails doing so.
0024:fixme:crypt:CryptProtectMemory (0x3b30130000 4096 00000000): stub 0174:fixme:wintrust:CryptCATAdminAcquireContext2 000000000E13E698 (null) (null) 0000000000000000 0 stub 0174:fixme:wintrust:CryptCATAdminAcquireContext2 000000000E13E698 (null) L"SHA256" 0000000000000000 0 stub
https://bugs.winehq.org/show_bug.cgi?id=44061
--- Comment #18 from David Torok dt@zeroitlab.com --- (In reply to Ker noa from comment #17)
Created attachment 68532 [details] CrashLog with the faketime patch
With the test patch i get a different warning before the game crashes. It obviously tries to validate game files and fails doing so.
0024:fixme:crypt:CryptProtectMemory (0x3b30130000 4096 00000000): stub 0174:fixme:wintrust:CryptCATAdminAcquireContext2 000000000E13E698 (null) (null) 0000000000000000 0 stub 0174:fixme:wintrust:CryptCATAdminAcquireContext2 000000000E13E698 (null) L"SHA256" 0000000000000000 0 stub
Please post with +module,+seh,+ntdll
https://bugs.winehq.org/show_bug.cgi?id=44061
--- Comment #19 from Ker noa blue-t@web.de --- Created attachment 68533 --> https://bugs.winehq.org/attachment.cgi?id=68533 ExtendedCrashLog
https://bugs.winehq.org/show_bug.cgi?id=44061
--- Comment #20 from David Torok dt@zeroitlab.com --- (In reply to Ker noa from comment #19)
Created attachment 68533 [details] ExtendedCrashLog
Thanks. Based on that, it's not obvious to me what the issue is on your side.
I think the first indication of anything being wrong is this (line 20894):
0108:trace:seh:handle_syscall_fault code=c0000005 flags=0 addr=0x7fbee62ca7fd ip=7fbee62ca7fd tid=0108 0108:trace:seh:handle_syscall_fault info[0]=0000000000000000 0108:trace:seh:handle_syscall_fault info[1]=000000000b301003 0108:trace:seh:handle_syscall_fault rax=000000000b301003 rbx=000000000ae3d520 rcx=000000000ae3d270 rdx=000000000b30006c 0108:trace:seh:handle_syscall_fault rsi=0000000000000f98 rdi=000000000b30006c rbp=000000000ae3d4d0 rsp=000000000ae3d240 0108:trace:seh:handle_syscall_fault r8=000000000b300000 r9=0000000000001000 r10=00007fbee62ed730 r11=00000000000000f9 0108:trace:seh:handle_syscall_fault r12=000000000ae3d520 r13=000000000b300000 r14=000000000b300004 r15=0000000000000000 0108:trace:seh:handle_syscall_fault returning to handler
This exception -
0108:trace:seh:dispatch_exception code=c0000096 flags=0 addr=00000001403A13F3 ip=403a13f3 tid=0108
is intended, part of anti debug in Destiny however seems like wine has some issues unwinding it and faults later on (line 21225):
0108:trace:seh:dispatch_exception code=c0000005 flags=0 addr=0000000000000D68 ip=d68 tid=0108 0108:trace:seh:dispatch_exception info[0]=0000000000000008 0108:trace:seh:dispatch_exception info[1]=0000000000000d68 0108:trace:seh:dispatch_exception rax=00000000000000af rbx=000000007bc6c930 rcx=000000000ae3f380 rdx=000000000ae3d250 0108:trace:seh:dispatch_exception rsi=000000000ae3f5b0 rdi=00000000ffb80000 rbp=000000000ae3d250 rsp=000000000ae3dfd8 0108:trace:seh:dispatch_exception r8=000000000ae3e8e0 r9=000000000ae3e070 r10=000000000000000a r11=0000000000000000 0108:trace:seh:dispatch_exception r12=000000000ae3f380 r13=000000000ae3e070 r14=000000007bc7b5d8 r15=0000000000000001
For reference, I think I'm using a build very similar to yours, 5.20 staging with the patch I attached. Interestingly, which anti debug code path is chosen is random. Do you get the same crash if you try let's say 10 times?
https://bugs.winehq.org/show_bug.cgi?id=44061
--- Comment #21 from Ker noa blue-t@web.de --- How do you define "same crash" , which numbers and lines need to match to say 2 runs are "the same"? The game dialog after the crash says each time that game content could not be read and i should run the repair method in steam. diffing the logs shows a few blocks of messages moving around between different runs.
https://bugs.winehq.org/show_bug.cgi?id=44061
--- Comment #22 from David Torok dt@zeroitlab.com --- (In reply to Ker noa from comment #21)
How do you define "same crash" , which numbers and lines need to match to say 2 runs are "the same"? The game dialog after the crash says each time that game content could not be read and i should run the repair method in steam. diffing the logs shows a few blocks of messages moving around between different runs.
I define "the same crash" as having this line
0108:trace:seh:dispatch_exception code=c0000096 flags=0 addr=00000001403A13F3 ip=403a13f3 tid=0108
and then the exception handling spiraling out of control. (which you can see from all the repeated lines starting from there)
Do you have windows steam installed in your wine prefix? ( You may want to have that running. )
https://bugs.winehq.org/show_bug.cgi?id=44061
--- Comment #23 from Ker noa blue-t@web.de --- 4 crashs later the line was found again in the logfile, with a different tid. Steam is currently not running as i still need to solve a build issue with 32bit wine
https://bugs.winehq.org/show_bug.cgi?id=44061
Vijay Kamuju infyquest@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |infyquest@gmail.com
--- Comment #24 from Vijay Kamuju infyquest@gmail.com --- Fix is committed for generating timestamp - d5c089f5fa71e2ae568b2f1bcb9158223c552040
Please check with latest git or wait for 5.21
https://bugs.winehq.org/show_bug.cgi?id=44061
--- Comment #25 from David Torok dt@zeroitlab.com --- Alright, 2 testers have confirmed that regardless of the fact that we "fixed" the entry bug correctly, they are still getting banned within 1 days max. I'll work more on this to figure out how we get detected, but in the meantime, please only test this on accounts that you can afford to get banned on.
https://bugs.winehq.org/show_bug.cgi?id=44061
Anastasius Focht focht@gmx.net changed:
What |Removed |Added ---------------------------------------------------------------------------- Fixed by SHA1| |d5c089f5fa71e2ae568b2f1bcb9 | |158223c552040 Component|-unknown |tools CC| |focht@gmx.net Summary|Destiny 2 crashes on launch |Destiny 2 crashes on launch | |(needs non-zero | |TimeDateStamp field in PE | |file header) Keywords| |obfuscation Resolution|--- |FIXED Status|NEW |RESOLVED
--- Comment #26 from Anastasius Focht focht@gmx.net --- Hello folks,
reminder: bug reports are not meant to be meta-bugs a la "make app/game X to work". Don't recycle this ticket over and over again for entirely different issues.
Resolving fixed by commit https://source.winehq.org/git/wine.git/commitdiff/d5c089f5fa71e2ae568b2f1bcb... ("winebuild: Set PE timestamps to a hash of the file name."), part of Wine 5.21 release.
Thanks Alexandre.
You may create follow-up bugs reports for each additional issue identified.
Regards
https://bugs.winehq.org/show_bug.cgi?id=44061
Alexandre Julliard julliard@winehq.org changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|RESOLVED |CLOSED
--- Comment #27 from Alexandre Julliard julliard@winehq.org --- Closing bugs fixed in 6.0-rc1.
https://bugs.winehq.org/show_bug.cgi?id=44061
Michael Stefaniuc mstefani@winehq.org changed:
What |Removed |Added ---------------------------------------------------------------------------- Target Milestone|--- |5.0.x
https://bugs.winehq.org/show_bug.cgi?id=44061
Michael Stefaniuc mstefani@winehq.org changed:
What |Removed |Added ---------------------------------------------------------------------------- Target Milestone|5.0.x |---
--- Comment #28 from Michael Stefaniuc mstefani@winehq.org --- Removing the 5.0.x milestone from bug fixes included in 5.0.4.