Function at 0x50218c
Capabilities:
Get file version info

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
push 0xffffffffffffffff
push 0x55843c
mov eax, dword fs:[0]
push eax
sub esp, 0x128
mov eax, dword [0x5f7350]
xor eax, esp
mov dword [esp + 0x120], eax
push ebx
push esi
push edi
mov eax, dword [0x5f7350]
xor eax, esp
push eax
lea eax, [esp + 0x138]
mov dword fs:[0], eax
mov eax, dword [ebp + 8]
xor ebx, ebx
cmp dword [eax + 0x14], 8
mov dword [esp + 0x10], eax
mov dword [esp + 0x24], ecx
mov dword [esp + 0x20], ebx
jb 0x5021e5
mov eax, dword [eax]
lea ecx, [esp + 0x20]
push ecx
push eax
call dword [sym.imp.VERSION.dll_GetFileVersionInfoSizeW]
mov esi, eax
cmp esi, ebx
jne 0x50222d
xor ecx, ecx
push str.GetFileVersionInfoSize_Failed
inc ecx
call fcn.00492b4d
pop ecx
xor al, al
mov ecx, dword [esp + 0x138]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x120]
xor ecx, esp
call fcn.0051497f
mov esp, ebp
pop ebp
ret 4
lea edi, [esp + 0x2c]
call fcn.0043df0b
mov dword [esp + 0x140], ebx
mov eax, dword [esp + 0x10]
cmp dword [eax + 0x14], 8
jb 0x502249
mov eax, dword [eax]
push dword [esp + 0x2c]
push esi
push ebx
push eax
call dword [sym.imp.VERSION.dll_GetFileVersionInfoW]
test eax, eax
jne 0x502303
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov edi, eax
lea eax, [esp + 0x5c]
push eax
call fcn.004036c8
mov esi, eax
mov byte [esp + 0x140], 1
push str.GetFileVersionInfo_Failed_with_Error_code_
push esi
call fcn.00405d7d
pop ecx
pop ecx
push edi
push esi
call fcn.0041056c
lea eax, [esp + 0xf4]
push eax
mov eax, esi
call fcn.00403732
mov byte [esp + 0x140], 2
cmp dword [esp + 0x108], 8
mov eax, dword [esp + 0xf4]
jae 0x5022bd
lea eax, [esp + 0xf4]
xor ecx, ecx
push eax
inc ecx
call fcn.00492b4d
pop ecx
mov byte [esp + 0x140], 1
lea ecx, [esp + 0xf4]
call fcn.004033b1
mov byte [esp + 0x140], bl
lea eax, [esp + 0x5c]
call fcn.00402669
or dword [esp + 0x140], 0xffffffff
lea esi, [esp + 0x2c]
call fcn.0040e080
mov al, bl
jmp 0x502207
lea eax, [esp + 0x28]
push eax
lea eax, [esp + 0x18]
push eax
push 0x584ab8
push dword [esp + 0x38]
call dword [sym.imp.VERSION.dll_VerQueryValueW]
test eax, eax
je 0x50245e
mov eax, dword [esp + 0x14]
movzx ecx, word [eax + 0xe]
movzx esi, word [eax + 0xa]
movzx edi, word [eax + 8]
movzx eax, word [eax + 0xc]
mov dword [esp + 0x1c], eax
lea eax, [esp + 0x5c]
push eax
mov dword [esp + 0x1c], ecx
call fcn.004036c8
mov dword [esp + 0x10], eax
mov byte [esp + 0x140], 3
push esi
push eax
call fcn.00443514
mov esi, dword [esp + 0x10]
push 0x2e
push esi
call fcn.00411d4f
push ebx
lea eax, [esp + 0x58]
push 2
push eax
call fcn.005358de
add esp, 0x14
mov ecx, eax
call fcn.004102b4
mov esi, eax
mov eax, dword [esi]
mov eax, dword [eax + 4]
push 0x30
pop ecx
push edi
push esi
mov word [eax + esi + 0x40], cx
call fcn.00443514
push 0x2e
push esi
call fcn.00411d4f
push ebx
lea eax, [esp + 0x48]
push 2
push eax
call fcn.005358de
add esp, 0x14
mov ecx, eax
call fcn.004102b4
push 0x30
mov esi, eax
mov eax, dword [esi]
mov eax, dword [eax + 4]
pop ecx
push dword [esp + 0x18]
mov word [eax + esi + 0x40], cx
push esi
call fcn.00443514
push 0x2e
push esi
call fcn.00411d4f
push ebx
lea eax, [esp + 0x100]
push 4
push eax
call fcn.005358de
add esp, 0x14
mov ecx, eax
call fcn.004102b4
push 0x30
mov esi, eax
mov eax, dword [esi]
mov eax, dword [eax + 4]
pop ecx
push dword [esp + 0x1c]
mov word [eax + esi + 0x40], cx
push esi
call fcn.00443514
lea eax, [esp + 0x114]
push eax
mov eax, esi
call fcn.00403732
mov byte [esp + 0x140], 4
mov ecx, dword [esp + 0x24]
push 0xffffffffffffffff
push ebx
lea eax, [esp + 0x11c]
call fcn.00404082
mov byte [esp + 0x140], 3
lea ecx, [esp + 0x114]
call fcn.004033b1
mov byte [esp + 0x140], bl
lea eax, [esp + 0x5c]
call fcn.00402669
mov bl, 1
jmp 0x5022eb
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov edi, eax
lea eax, [esp + 0x5c]
push eax
call fcn.004036c8
mov esi, eax
mov byte [esp + 0x140], 5
push str.VerQueryValue_Failed_with_error_code_
push esi
call fcn.00405d7d
pop ecx
pop ecx
push edi
push esi
call fcn.0041056c
lea eax, [esp + 0xf4]
push eax
mov eax, esi
call fcn.00403732
mov byte [esp + 0x140], 6
cmp dword [esp + 0x108], 8
mov eax, dword [esp + 0xf4]
jae 0x5024bd
lea eax, [esp + 0xf4]
xor ecx, ecx
push eax
inc ecx
call fcn.00492b4d
pop ecx
mov byte [esp + 0x140], 5
jmp 0x5022cf