Function at 0x410281
Capabilities:
Get file version info
Identify system language via api

Disassembly:
push ebp
sub esp, 0xc8
lea ebp, [esp - 4]
mov eax, dword [0x69c24c]
xor eax, ebp
mov dword [ebp + 0xc8], eax
push 0x54
mov eax, 0x5e1088
call fcn.005bb14d
mov ebx, ecx
mov dword [ebp - 0x28], ebx
mov esi, dword [ebp + 0xd4]
lea eax, [ebp - 0x60]
push 0x5b
push 0x4c
push 0x60ca68
push eax
call fcn.00408f4f
add esp, 0x10
xor edi, edi
mov dword [ebp - 4], edi
mov dword [ebp - 0x38], edi
mov dword [ebp - 0x3c], edi
cmp dword [ebp + 0xd8], edi
jne 0x4102e6
call dword [sym.imp.KERNEL32.dll_GetUserDefaultLangID]
movzx eax, ax
mov dword [ebp - 0x40], eax
jmp 0x4102ed
mov dword [ebp - 0x40], 0x409
cmp dword [ebx], edi
je 0x4102f9
push dword [ebx]
call fcn.005c3f1c
pop ecx
push 0x134c
push edi
push ebx
mov dword [ebx], edi
call fcn.005bd7e0
add esp, 0xc
lea eax, [ebx + 4]
push 0x104
push esi
push eax
call dword [sym.imp.KERNEL32.dll_lstrcpynW]
push 0xc
lea edx, [ebx + 0x250]
mov eax, 0x60bba8
pop ecx
mov edi, edx
mov dword [ebp - 0x20], edx
rep stosd dword es:[edi], eax
lea eax, [ebp - 0x3c]
push eax
push esi
call sub.VERSION.dll_GetFileVersionInfoSizeW
mov edi, eax
test edi, edi
jne 0x410358
push eax
push eax
push eax
push eax
push esi
push 1
push 0x7c
push str.d:_sourcesmachetemachete51_3machetewinntinclude_vs2005CModuleVerInfo.h
push esi
push str.GetFileVersionInfoSize
jmp 0x410405
lea eax, [edi*2 + 0x1f]
and eax, 0xfffffff8
mov ecx, eax
mov dword [ebp - 0x2c], eax
add eax, edi
shr ecx, 1
push eax
mov dword [ebp - 0x48], ecx
mov dword [ebp - 0x30], eax
call fcn.005c3f21
pop ecx
mov ecx, eax
mov dword [ebp - 0x44], ecx
mov dword [ebx], ecx
test ecx, ecx
jne 0x4103d7
push eax
push eax
push eax
push eax
push eax
push eax
push 0x86
push str.d:_sourcesmachetemachete51_3machetewinntinclude_vs2005CModuleVerInfo.h
push eax
push str.malloc
push 0xe
lea esi, [ebx + 0x280]
push 1
push esi
call fcn.0046e15b
add esp, 0x34
test esi, esi
je 0x410756
push dword [ebp - 0x30]
lea eax, [ebx + 0x508]
push 0x60bd10
push 0xffffffffffffffff
push 0x100
push eax
call fcn.0040c5e7
add esp, 0x14
jmp 0x410756
mov eax, dword [ebp - 0x2c]
add eax, ecx
push eax
push edi
push dword [ebp - 0x3c]
mov dword [ebp - 0x34], eax
push esi
call sub.VERSION.dll_GetFileVersionInfoW
test eax, eax
jne 0x410422
push eax
push eax
push eax
push eax
push esi
push 1
push 0x94
push str.d:_sourcesmachetemachete51_3machetewinntinclude_vs2005CModuleVerInfo.h
push esi
push str.GetFileVersionInfo
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
lea eax, [ebx + 0x280]
push 1
push eax
call fcn.0046e15b
add esp, 0x34
jmp 0x410756
mov esi, dword [ebp - 0x34]
lea eax, [ebp - 0x18]
push eax
lea eax, [ebp - 0x10]
mov dword [ebx + 0x20c], esi
push eax
push 0x60c688
push esi
mov dword [ebx + 0x210], edi
call sub.VERSION.dll_VerQueryValueW
test eax, eax
je 0x410470
cmp dword [ebp - 0x10], 0
je 0x410470
mov eax, dword [ebp - 0x18]
test eax, eax
je 0x410470
push 0x34
pop ecx
cmp eax, ecx
cmova eax, ecx
push eax
push dword [ebp - 0x10]
lea eax, [ebx + 0x214]
push eax
call fcn.005bd260
add esp, 0xc
xor eax, eax
mov dword [ebx + 0x248], eax
lea eax, [ebp - 0x18]
push eax
lea eax, [ebp - 0x10]
push eax
push str.VarFileInfoTranslation
push esi
call sub.VERSION.dll_VerQueryValueW
test eax, eax
je 0x4104ac
mov ecx, dword [ebp - 0x10]
test ecx, ecx
je 0x4104ac
mov eax, dword [ebp - 0x18]
test eax, eax
je 0x4104ac
shr eax, 2
mov dword [ebx + 0x24c], ecx
mov dword [ebx + 0x248], eax
mov eax, dword [ebx + 0x248]
mov edx, 0x100
cmp eax, edx
mov ecx, edx
cmovb ecx, eax
mov dword [ebx + 0x1348], ecx
test ecx, ecx
je 0x4104e3
mov eax, ecx
shl eax, 2
push eax
push dword [ebx + 0x24c]
lea eax, [ebx + 0xf48]
push eax
call fcn.005bd260
add esp, 0xc
mov esi, dword [ebx + 0x210]
mov edi, dword [ebx + 0x20c]
shr esi, 1
add esi, 0xfffffff8
mov dword [ebp - 0x14], esi
test esi, esi
jle 0x410560
lea eax, [ebp - 0x24]
mov ecx, ebx
push eax
push edi
call fcn.00411b33
test eax, eax
je 0x410555
mov ecx, dword [ebx + 0x1348]
xor eax, eax
mov edx, eax
test ecx, ecx
jle 0x410536
lea esi, [ebx + 0xf48]
mov eax, dword [esi]
lea ebx, [ebp - 0x24]
cmp eax, dword [ebx]
je 0x410530
inc edx
add esi, 4
cmp edx, ecx
jl 0x41051f
mov ebx, dword [ebp - 0x28]
mov esi, dword [ebp - 0x14]
cmp edx, ecx
jl 0x410555
cmp ecx, 0x100
jae 0x410555
lea eax, [ecx + 1]
mov dword [ebx + 0x1348], eax
mov eax, dword [ebp - 0x24]
mov dword [ebx + ecx*4 + 0xf48], eax
add edi, 2
sub esi, 1
mov dword [ebp - 0x14], esi
jne 0x4104fb
xor edi, edi
lea eax, [ebx + 0x250]
mov edx, edi
mov dword [ebp - 0x1c], edx
or dword [ebp - 0x2c], 0xffffffff
or esi, 0xffffffff
or dword [ebp - 0x30], 0xffffffff
mov ecx, edi
mov dword [ebp - 0x28], esi
mov dword [ebp - 0x14], ecx
cmp dword [ebx + 0x1348], edi
jbe 0x410743
lea eax, [ebx + 0xf48]
mov dword [ebp - 0x24], eax
movzx eax, word [eax]
cmp eax, dword [ebp - 0x40]
jne 0x4105a2
lea edi, [ebp - 0x28]
jmp 0x4105b3
mov edx, dword [ebp - 0x1c]
lea edi, [ebp - 0x2c]
cmp eax, 0x409
lea eax, [ebp - 0x30]
cmovne edi, eax
cmp dword [edi], 0xffffffff
jne 0x410621
push edx
call fcn.004101f4
mov ecx, dword [ebp - 0x24]
push eax
movzx eax, word [ecx + 2]
push eax
movzx eax, word [ecx]
push eax
push str.StringFileInfo_04x_04x_s
push 0xffffffffffffffff
lea eax, [ebp]
push 0x64
push eax
call fcn.0040c5e7
add esp, 0x20
lea eax, [ebp - 0x18]
push eax
lea eax, [ebp - 0x10]
push eax
lea eax, [ebp]
push eax
push dword [ebp - 0x34]
call sub.VERSION.dll_VerQueryValueW
test eax, eax
je 0x410616
mov eax, dword [ebp - 0x10]
test eax, eax
je 0x410616
cmp dword [ebp - 0x18], 0
je 0x410616
xor ecx, ecx
cmp word [eax], cx
mov ecx, dword [ebp - 0x14]
je 0x410619
mov dword [edi], ecx
mov esi, dword [ebp - 0x28]
jmp 0x410619
mov ecx, dword [ebp - 0x14]
cmp esi, 0xffffffff
jne 0x410653
mov edx, dword [ebp - 0x1c]
mov eax, dword [ebp - 0x24]
inc ecx
add eax, 4
mov dword [ebp - 0x14], ecx
mov dword [ebp - 0x24], eax
cmp ecx, dword [ebx + 0x1348]
jb 0x410595
cmp esi, 0xffffffff
jne 0x410653
mov esi, dword [ebp - 0x2c]
cmp esi, 0xffffffff
jne 0x410653
mov esi, dword [ebp - 0x30]
cmp esi, 0xffffffff
je 0x41073e
push dword [ebp - 0x1c]
call fcn.004101f4
push eax
movzx eax, word [ebx + esi*4 + 0xf4a]
push eax
movzx eax, word [ebx + esi*4 + 0xf48]
push eax
push str.StringFileInfo_04x_04x_s
push 0xffffffffffffffff
lea eax, [ebp]
push 0x64
push eax
call fcn.0040c5e7
add esp, 0x20
lea eax, [ebp - 0x18]
push eax
lea eax, [ebp - 0x10]
push eax
lea eax, [ebp]
push eax
push dword [ebp - 0x34]
call sub.VERSION.dll_VerQueryValueW
test eax, eax
je 0x41073b
cmp dword [ebp - 0x10], 0
je 0x41073b
mov ecx, dword [ebp - 0x18]
test ecx, ecx
je 0x41073b
mov edx, dword [ebp - 0x38]
mov eax, dword [ebp - 0x44]
mov edi, dword [ebp - 0x48]
push 0xfffffffffffffffe
lea esi, [eax + edx*2]
mov eax, dword [ebp - 0x20]
mov dword [eax], esi
mov eax, edi
sub eax, edx
cmp ecx, eax
cmova ecx, eax
pop eax
cmp dword [ebp + 0xdc], eax
cmovb eax, dword [ebp + 0xdc]
inc eax
cmp ecx, eax
cmova ecx, eax
push ecx
push dword [ebp - 0x10]
mov dword [ebp - 0x18], ecx
push esi
call dword [sym.imp.KERNEL32.dll_lstrcpynW]
xor edx, edx
cmp dword [ebp + 0xd8], 1
jne 0x41071c
mov eax, esi
jmp 0x410717
movzx ecx, word [eax]
cmp ecx, 0x1f
jbe 0x41070e
cmp ecx, 0x7f
jne 0x410714
push 0x2e
pop ecx
mov word [eax], cx
add eax, 2
cmp word [eax], dx
jne 0x410701
lea ecx, [esi + 2]
mov ax, word [esi]
add esi, 2
cmp ax, dx
jne 0x41071f
mov eax, dword [ebp - 0x38]
sub esi, ecx
sar esi, 1
inc eax
add eax, esi
mov dword [ebp - 0x38], eax
cmp eax, edi
jae 0x410756
mov edx, dword [ebp - 0x1c]
mov eax, dword [ebp - 0x20]
xor edi, edi
inc edx
add eax, 4
mov dword [ebp - 0x1c], edx
mov dword [ebp - 0x20], eax
cmp edx, 0xc
jb 0x41056d
or dword [ebp - 4], 0xffffffff
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp + 0xc8]
xor ecx, ebp
call fcn.005bb105
lea esp, [ebp + 0xcc]
pop ebp
ret 0xc