[Bug 9685] Punkbuster removes me from game for UNKNOWN WINDOWS API FUNCTION [131124]

wine-bugs at winehq.org wine-bugs at winehq.org
Thu Oct 25 15:52:51 CDT 2007


http://bugs.winehq.org/show_bug.cgi?id=9685





--- Comment #84 from Anastasius Focht <focht at gmx.net>  2007-10-25 15:52:50 ---
Hello,

--- quote ---
Is it impossible to implement those api functions or is it illegal?
--- quote ---

There are quite a number of dlls functions that need their API entry signatures
to be matched to windows ones.
Currently the following dlls are checked: user32, ntdll, kernel32, psapi,
iphlpapi, d3d9, opengl32, ddraw.
For each dll, a selected number of API entries [known for being hooked] are
fingerprinted.
In worst case this means you have to duplicate API entry code for 30+ API
functions.
Technically you can fake API entry opcodes by placing __asm__ wrappers around
all checked API functions and then call real ones later.
This would interfere with wine's tracing and relay functionality (you can't
have both).
Additionally not all API entry code can be matched because some windows code is
special requiring additional [internal] windows structures/data layouts in
place.

(1) You would have to gather a list of all API signatures being checked (can be
very time consuming - although possible).
(2) disassemble all checked API entry code for specific windows version and
make __asm__ wrappers for it's wine counterparts (at least 20-30 opcode bytes
deep).
(3) extensive testing for any side-effects on other apps
(4) profit! (joke) :-)

Well ... at least (2) is not compatible with wine policy ;-)

--- quote ---
We know that we can't use the linux client because native Windows games like
BF2
doesn't have one.
--- quote ---

Yes, for games that don't have native linux client the thunking approach won't
work.

--- quote ---
Under (imitated) Win 98 the Windows clients work, but do they
work if they are included within Win XP games? If they do, why don't pretend to
be Win 98, but give XP functionality?
--- quote ---

Games that require Windows NT/2K/XP will simply refuse to start if you fake OS
version info to Win9X.
You would have to lie to PunkBuster about windows version (imposting Win9X) but
tell all other game code "we're running NT/2K/XP".
Technically possible (by walking callstacks) but such functionality is very 
specific/intrusive/hackish for the sole purpose of running PunkBuster.
Simply spoken: such code would _never_ make it into official wine tree.

As shown in comment #82 there is no insurance that all API entry checks are
disabled in Win9X config (differs between game/client versions).

Regards


-- 
Configure bugmail: http://bugs.winehq.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are watching all bug changes.



More information about the wine-bugs mailing list