Allow untested Desktop versions with compatibility warnings
This commit is contained in:
1 parent
d2b621bce7
commit
ab69f287b6
16 files changed
+1571
-1495
No files matched your search
@@ -1,4 +1,4 @@
|
||||
"""Standalone fixed arithmetic and capability tests in the supported WhatsApp WebView.
|
||||
"""Standalone fixed arithmetic and capability tests in the WhatsApp WebView.
|
||||
|
||||
Windows x64 and 64-bit Python; standard library only. The bundled native DLL is
|
||||
hash-verified and cached in the workspace. Capability tests use fixed queries,
|
||||
@@ -21,7 +21,7 @@ import uuid
|
||||
import sys
|
||||
|
||||
from .common import BASE, verified_helper
|
||||
from .desktop import visible_ui_threads, detect_desktop_pid, check_core_build, SUPPORTED_BUILD, CORE_SHA256
|
||||
from .desktop import visible_ui_threads, detect_desktop_pid, TESTED_BUILD
|
||||
WAKE = 0x8000 + 0x498
|
||||
PROTOCOL = 0x4d415432
|
||||
# SHA-256 of assets/math_probe.dll.
|
||||
@@ -360,7 +360,7 @@ def run_math(pid=None, suite='math', _operation=None):
|
||||
'suite': suite, 'frida_used': False,
|
||||
'startup_acknowledged': False, 'javascript_executed': False,
|
||||
'cleanup': {'acknowledged': False, 'hook_removed': False},
|
||||
'supported_build': SUPPORTED_BUILD}
|
||||
'tested_build': TESTED_BUILD}
|
||||
kernel = user = None
|
||||
module = hook = mapping = view = process = None
|
||||
packet = None
|
||||
@@ -371,7 +371,9 @@ def run_math(pid=None, suite='math', _operation=None):
|
||||
raise ValueError('Unknown suite; choose math, capabilities, all, message-json or contacts')
|
||||
if os.name != 'nt' or ctypes.sizeof(ctypes.c_void_p) != 8:
|
||||
raise ValueError('Windows and 64-bit Python are required')
|
||||
selected = detect_desktop_pid(pid)
|
||||
compatibility = {}
|
||||
selected = detect_desktop_pid(pid, compatibility=compatibility)
|
||||
report['compatibility'] = compatibility
|
||||
thread = next(iter(visible_ui_threads(selected)))
|
||||
report.update(pid=selected, ui_thread_id=thread, pid_auto_detected=pid is None)
|
||||
kernel, user = windows_api()
|
||||
@@ -573,7 +575,7 @@ def main(argv=None):
|
||||
parser = argparse.ArgumentParser(description=__doc__)
|
||||
parser.add_argument('--suite', choices=('math', 'capabilities', 'all', 'message-json', 'contacts', 'history-read'), default='math',
|
||||
help='Fixed tests (default: math); message-json prints meow matches, contacts prints a five-contact sample')
|
||||
parser.add_argument('--pid', type=int, help='Optional supported Desktop host PID')
|
||||
parser.add_argument('--pid', type=int, help='Optional Desktop host PID')
|
||||
parser.add_argument('--output', type=Path)
|
||||
args = parser.parse_args(argv)
|
||||
if args.output is None:
|
||||
|
||||
Reference in new issue
Block a user