[Bug 35842] New: Sentinel HASP hardlock.sys kernel driver (bundled with Kompas-3D v14) tries to access to DR7 (not handled in ntoskrnl emulate_instruction)

wine-bugs at winehq.org wine-bugs at winehq.org
Sat Mar 22 06:48:32 CDT 2014


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

            Bug ID: 35842
           Summary: Sentinel HASP hardlock.sys kernel driver (bundled with
                    Kompas-3D v14) tries to access to DR7 (not handled in
                    ntoskrnl emulate_instruction)
           Product: Wine
           Version: 1.7.15
          Hardware: x86
                OS: Linux
            Status: NEW
          Severity: normal
          Priority: P2
         Component: ntoskrnl
          Assignee: wine-bugs at winehq.org
          Reporter: focht at gmx.net

Hello folks,

found during investigation of bug 35359

The app bundles HASP/Hardlock dongle driver which crashes on startup.
Bug 30220 is a similar problem (which is about CR4 access)

--- snip ---
$ pwd
/home/focht/.wine/drive_c/Program Files/ASCON/KOMPAS-3D V14/Bin

$ wine ./KOMPAS.Exe
...
Unhandled exception: privileged instruction in 32-bit code (0x005c39b6).
Register dump:
 CS:0023 SS:002b DS:002b ES:002b FS:0063 GS:006b
 EIP:005c39b6 ESP:0053e614 EBP:0053e6b8 EFLAGS:00010206(  R- --  I   - -P- )
 EAX:00000400 EBX:7edff000 ECX:005c3a24 EDX:005c6612
 ESI:0053fb40 EDI:003d0f00
...
Backtrace:
=>0 0x005c39b6 in hardlock.sys (+0x839b6) (0x0053e6b8)
  1 0x7edfc613 load_driver+0x577()
[/home/focht/projects/wine/wine.repo/src/programs/winedevice/device.c:254] in
winedevice (0x0053e948)
  2 0x7edfc8d1 ServiceMain+0x129(argc=<couldn't compute location>,
argv=<couldn't compute location>)
[/home/focht/projects/wine/wine.repo/src/programs/winedevice/device.c:308] in
winedevice (0x0053e9b8)
  3 0x7edbc187 service_thread+0x17f(arg=<couldn't compute location>)
[/home/focht/projects/wine/wine.repo/src/dlls/advapi32/service.c:302] in
advapi32 (0x0053ea48)
  4 0x7bc86674 call_thread_func_wrapper+0xb() in ntdll (0x0053ea68)
...
0x005c39b6: movl    %eax,%dr7
Modules:
Module    Address            Debug info    Name (24 modules)
PE      540000-  5d2200    Export          hardlock.sys
...
Threads:
process  tid      prio (all id:s are in hex)
00000008 KOMPAS.Exe
    00000035    0
    00000034    0
    00000009    0
...
0000001c (D) C:\windows\system32\winedevice.exe
    00000022    0 <==
    00000021    0
    0000001d    0
...
--- snip ---

It clears DR7 with 0x400, the default after hardware reset (bit 10 is reserved,
must be set to 1).

Tidbit: The driver is heavily obfuscated (not a problem though) :-)

$ sha1sum KOMPAS-3D_V14_SP1.7z
224cac526d0a1c552962930f54d2bec879b3a1e2  KOMPAS-3D_V14_SP1.7z

$ du -sh KOMPAS-3D_V14_SP1.7z
846M    KOMPAS-3D_V14_SP1.7z

$ wine --version
wine-1.7.15

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