mirror of
https://github.com/Retropex/bitcoin.git
synced 2025-05-12 19:20:42 +02:00
Merge 18490 via bugfix_symcheck_pe_case
This commit is contained in:
commit
cb2d1032bd
@ -133,7 +133,7 @@ MACHO_ALLOWED_LIBRARIES = {
|
||||
'QuartzCore', # animation
|
||||
}
|
||||
|
||||
PE_ALLOWED_LIBRARIES = {
|
||||
PE_ALLOWED_LIBRARIES = {libname.lower() for libname in (
|
||||
'ADVAPI32.dll', # security & registry
|
||||
'IPHLPAPI.DLL', # IP helper API
|
||||
'KERNEL32.dll', # win32 base APIs
|
||||
@ -154,7 +154,7 @@ PE_ALLOWED_LIBRARIES = {
|
||||
'VERSION.dll', # version checking
|
||||
'WINMM.dll', # WinMM audio API
|
||||
'WTSAPI32.dll',
|
||||
}
|
||||
)}
|
||||
|
||||
def check_version(max_versions, version, arch) -> bool:
|
||||
(lib, _, ver) = version.rpartition('_')
|
||||
@ -225,7 +225,7 @@ def check_MACHO_sdk(binary) -> bool:
|
||||
def check_PE_libraries(binary) -> bool:
|
||||
ok: bool = True
|
||||
for dylib in binary.libraries:
|
||||
if dylib not in PE_ALLOWED_LIBRARIES:
|
||||
if dylib.lower() not in PE_ALLOWED_LIBRARIES:
|
||||
print(f'{dylib} is not in ALLOWED_LIBRARIES!')
|
||||
ok = False
|
||||
return ok
|
||||
|
Loading…
Reference in New Issue
Block a user