[Bug 21201] HotWheels Stunt Track Driver 2: CD-Check fails, and Esc causes crash (CDROM drive letter derived from installer working path, written to 'CDDATADIR' registry key)

wine-bugs at winehq.org wine-bugs at winehq.org
Sun Nov 8 16:49:19 CST 2015


https://bugs.winehq.org/show_bug.cgi?id=21201

Anastasius Focht <focht at gmx.net> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|obfuscation                 |
             Status|UNCONFIRMED                 |RESOLVED
                 CC|                            |focht at gmx.net
         Resolution|---                         |INVALID
            Summary|HotWheels Stunt Track       |HotWheels Stunt Track
                   |Driver 2: CD-Check fails,   |Driver 2: CD-Check fails,
                   |and Esc causes page fault.  |and Esc causes crash (CDROM
                   |                            |drive letter derived from
                   |                            |installer working path,
                   |                            |written to 'CDDATADIR'
                   |                            |registry key)

--- Comment #6 from Anastasius Focht <focht at gmx.net> ---
Hello folks,

confirming.

Thanks to people still seeding old stuff I found a distributed backup for
testing.

It's essentially the same (stupid) issue as I analysed in
https://bugs.winehq.org/show_bug.cgi?id=13754#c4

The game itself has no copy-protection - not even a simple CD check.

--- snip ---
-=[ ProtectionID v0.6.6.7 DECEMBER]=-
(c) 2003-2015 CDKiLLER & TippeX
Build 24/12/14-22:48:13
Ready...
Scanning -> C:\Program Files\Mattel Interactive\Hot Wheels\Stunt Track Driver
2\stunt2.exe
File Type : 32-Bit Exe (Subsystem : Win GUI / 2), Size : 950272 (0E8000h)
Byte(s)
Compilation TimeStamp : 0x399455C4 -> Fri 11th Aug 2000 19:36:36 (GMT)
[TimeStamp] 0x399455C4 -> Fri 11th Aug 2000 19:36:36 (GMT) | PE Header | - |
Offset: 0x00000100 | VA: 0x00400100 | -
[File Heuristics] -> Flag #1 : 00000000000000000000000000000000 (0x00000000)
[Entrypoint Section Entropy] : 6.52 (section #0) ".text   " | Size : 0x6FAF1
(457457) byte(s)
[DllCharacteristics] -> Flag : (0x0000) -> NONE
[SectionCount] 5 (0x5) | ImageSize 0x54A9000 (88772608) byte(s)
[VersionInfo] Company Name : Mattel. Inc.
[VersionInfo] Product Name : Stunt Track Driver 2
[VersionInfo] Product Version : 1.0
[VersionInfo] File Description : Stunt Track Driver 2. Get 'N' Dirty(TM)
[VersionInfo] File Version : 1.0
[VersionInfo] Original FileName : stunt2.exe
[VersionInfo] Internal Name : Stunt Track Driver 2
[VersionInfo] Legal Trademarks : Hot Wheels® is a registered trademark of
Mattel. Inc.
[VersionInfo] Legal Copyrights : Copyright © 2000
[CompilerDetect] -> Intel(R) C/C++ Compiler
[!] File appears to have no protection or is using an unknown protection
- Scan Took : 0.504 Second(s) [0000001F8h (504) tick(s)] [499 of 573 scan(s)
done]
--- snip ---

The game installer writes a registry key 'CDDATADIR' which is derived from the
working directory where the installer executable was started from.

This is usually a path containing "Z:\\" because most people don't bother to
use 'wine <mapped-cdrom-drive>:\\setup.exe' (including me).

The game reads the registry key 'CDDATADIR' and tries to access data files.
Well, you get the idea ;-)

Export of relevant part of registry with broken path:

--- snip ---
[HKEY_LOCAL_MACHINE\Software\Mattel\Stunt Track Driver 2\1.0]
"CDDATADIR"="Z:\\setup\\hot2000\\"
"InstallPath"="C:\\Program Files\\Mattel Interactive\\Hot Wheels\\Stunt Track
Driver 2\\"
--- snip ---

Trace log with broken path:

--- snip ---
$ pwd
/home/focht/.wine/drive_c/Program Files/Mattel Interactive/Hot Wheels/Stunt
Track Driver 2

$ WINEDEBUG=+tid,+seh,+relay wine ./stunt2.exe >>log.txt 2&>1
...
0028:Call KERNEL32.SetCurrentDirectoryA(0033fbd4 "C:\\Program Files\\Mattel
Interactive\\Hot Wheels\\Stunt Track Driver 2\\data/intro") ret=004a8411
0028:Ret  KERNEL32.SetCurrentDirectoryA() retval=00000001 ret=004a8411
0028:Call KERNEL32.CreateFileA(058a0ee0
"intro.plz",80000000,00000003,0033fa58,00000003,00000080,00000000) ret=004b6c3a
0028:Ret  KERNEL32.CreateFileA() retval=ffffffff ret=004b6c3a
0028:Call KERNEL32.GetLastError() ret=004b6c58
0028:Ret  KERNEL32.GetLastError() retval=00000002 ret=004b6c58
0028:Call advapi32.RegOpenKeyExA(80000002,0033f9b4 "SOFTWARE\\Mattel\\Stunt
Track Driver 2\\1.0",00000000,00020019,0033fab4) ret=004593c5
0028:Ret  advapi32.RegOpenKeyExA() retval=00000000 ret=004593c5
0028:Call advapi32.RegQueryValueExA(00000240,0589c9c0
"CDDATADIR",00000000,0033fabc,00554f20,0033fab8) ret=00459419
0028:Ret  advapi32.RegQueryValueExA() retval=00000000 ret=00459419
0028:Call KERNEL32.GetCurrentDirectoryA(00000104,0033f9ac) ret=004b9a5e
0028:Ret  KERNEL32.GetCurrentDirectoryA() retval=0000004e ret=004b9a5e
0028:Call KERNEL32.CreateFileA(0033fadc
"Z:\\setup\\hot2000\\\\data\\intro\\intro.plz",80000000,00000003,0033fa58,00000003,00000080,00000000)
ret=004b6c3a
0028:Ret  KERNEL32.CreateFileA() retval=ffffffff ret=004b6c3a 
...
--- snip ---

You either fix the registry key manually or run the installer with real CDROM
driver letter path.

Test:

* (auto)mounted the CD/ISO to 'e:'
* cd to mount point
* ran 'wine e:\\setup.exe' 

-> path was properly written to registry:

--- snip ---
...
0028:Call advapi32.RegOpenKeyExA(80000002,0033f974 "SOFTWARE\\Mattel\\Stunt
Track Driver 2\\1.0",00000000,00020019,0033fa74) ret=004593c5
0028:Ret  advapi32.RegOpenKeyExA() retval=00000000 ret=004593c5
0028:Call advapi32.RegQueryValueExA(0000009c,0589c9c0
"CDDATADIR",00000000,0033fa7c,00554f20,0033fa78) ret=00459419
0028:Ret  advapi32.RegQueryValueExA() retval=00000000 ret=00459419
0028:Call KERNEL32.GetCurrentDirectoryA(00000104,0033f96c) ret=004b9a5e
0028:Ret  KERNEL32.GetCurrentDirectoryA() retval=0000004e ret=004b9a5e
0028:Call KERNEL32.CreateFileA(0033fa9c
"e:\\setup\\hot2000\\\\data\\intro\\logos.plz",80000000,00000003,0033fa18,00000003,00000080,00000000)
ret=004b6c3a
0028:Ret  KERNEL32.CreateFileA() retval=00000240 ret=004b6c3a
0028:Call KERNEL32.GetFileType(00000240) ret=004b6c47
0028:Ret  KERNEL32.GetFileType() retval=00000001 ret=004b6c47 
...
--- snip ---

Runs fine here with default 'Windows XP' setting.

Resolving 'INVALID' since this not a Wine bug.

$ wine --version
wine-1.7.54-179-ga0d0d0d

Regards

-- 
Do not reply to this email, post in Bugzilla using the
above URL to reply.
You are receiving this mail because:
You are watching all bug changes.


More information about the wine-bugs mailing list