Function at 0x424e70
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
and esp, 0xfffffff0
sub esp, 0x30
mov esi, esp
cmp byte [0x431090], 0
jne 0x424bdf
mov byte [0x431090], 1
mov edx, dword [0x428040]
movzx ecx, word [edx]
xor eax, eax
cmp ecx, 0x5a4d
jne 0x424af7
mov ecx, dword [edx + 0x3c]
cmp dword [edx + ecx], 0x4550
jne 0x424af7
movzx edx, word [edx + ecx + 0x18]
cmp edx, 0x10b
mov edx, dword [0x428040]
jne 0x424af7
movzx eax, word [edx + ecx + 6]
shl eax, 2
lea eax, [eax + eax*4]
add eax, 3
and eax, 0xfffffffc
call fcn.00401589
mov eax, esp
and eax, 0xfffffff0
mov esp, eax
mov dword [0x4310c8], eax
mov dword [0x4310a8], 0
mov ebx, 0x42f548
mov eax, 0x42f548
sub eax, ebx
cmp eax, 7
jle 0x424bdf
cmp eax, 0xc
jl 0x424b58
cmp dword [0x42f548], 0
jne 0x424b67
cmp dword [0x42f54c], 0
jne 0x424b67
cmp dword [0x42f550], 0
mov eax, 0x42f548
mov ebx, 0x42f554
cmovne ebx, eax
cmp dword [ebx], 0
jne 0x424b67
cmp dword [ebx + 4], 0
je 0x424be7
cmp ebx, 0x42f548
jae 0x424b9c
lea edi, [esi + 0x14]
mov eax, dword [ebx]
mov ecx, dword [ebx + 4]
add eax, dword [ecx + edx]
add ecx, edx
mov dword [esi + 0x14], eax
mov edx, edi
push 4
call 0x424cfe
mov edx, dword [0x428040]
add esp, 4
add ebx, 8
cmp ebx, 0x42f548
jb 0x424b72
mov eax, dword [0x4310a8]
test eax, eax
jle 0x424bdf
xor edi, edi
mov ebx, 8
mov ecx, dword [0x4310c8]
mov edx, dword [ecx + ebx - 8]
test edx, edx
je 0x424bd7
lea eax, [esi + 0x1c]
push eax
push edx
push dword [ecx + ebx]
push dword [ecx + ebx - 4]
call dword [sym.imp.KERNEL32.dll_VirtualProtect]
mov ecx, dword [0x4310c8]
mov eax, dword [0x4310a8]
inc edi
add ebx, 0x14
cmp edi, eax
jl 0x424bb2
lea esp, [ebp - 0xc]
pop esi
pop edi
pop ebx
pop ebp
ret
mov eax, dword [ebx + 8]
cmp eax, 1
jne 0x424cf3
add ebx, 0xc
cmp ebx, 0x42f548
jae 0x424b9c
mov eax, dword [ebx + 4]
add eax, edx
mov edi, dword [ebx]
mov ecx, dword [ebx + 8]
mov dword [esi + 0x10], edi
mov edx, dword [edi + edx]
mov dword [esi + 8], edx
cmp cl, 0x20
mov dword [esi + 0xc], ecx
movzx edx, cl
mov dword [esi + 4], eax
je 0x424c3a
cmp edx, 0x10
je 0x424c3e
cmp edx, 8
jne 0x424ce8
movzx eax, byte [eax]
lea edi, [eax - 0x100]
test al, al
jmp 0x424c4a
mov edi, dword [eax]
jmp 0x424c4d
movzx eax, word [eax]
lea edi, [eax - 0x10000]
test ax, ax
cmovns edi, eax
mov eax, dword [esi + 0x10]
add eax, dword [0x428040]
sub edi, eax
add edi, dword [esi + 8]
mov dword [esi + 0x18], edi
cmp edx, 0x1f
ja 0x424c88
xor eax, eax
dec eax
mov ecx, edx
shl eax, cl
test dl, 0x20
mov ecx, 0
cmovne eax, ecx
not eax
cmp edi, eax
jg 0x424cd6
mov ecx, edx
dec cl
xor eax, eax
dec eax
shl eax, cl
cmp edi, eax
jl 0x424cd6
mov eax, dword [esi + 0xc]
cmp al, 8
mov edi, 1
je 0x424cad
movzx eax, al
cmp eax, 0x20
je 0x424ca8
cmp eax, 0x10
jne 0x424cbc
mov edi, 2
jmp 0x424cad
mov edi, 4
mov ecx, dword [esi + 4]
lea edx, [esi + 0x18]
push edi
call 0x424cfe
add esp, 4
add ebx, 0xc
cmp ebx, 0x42f548
mov edx, dword [0x428040]
jb 0x424bfe
jmp 0x424b9c
push edi
push dword [esi + 8]
push dword [esi + 4]
push edx
push str._d_bit_pseudo_relocation_at__p_out_of_range__targeting__p__yielding_the_value__p._n
call 0x424e70
push edx
push str.__Unknown_pseudo_relocation_bit_size__d._n
call 0x424e70
push eax
push str.__Unknown_pseudo_relocation_protocol_version__d._n
call 0x424e70
push ebp
push ebx
push edi
push esi
sub esp, 0x20
mov ebp, edx
mov esi, ecx
mov eax, dword [0x4310a8]
test eax, eax
jle 0x424d3c
mov ecx, dword [0x4310c8]
add ecx, 0x10
mov edx, eax
mov edi, dword [ecx - 4]
cmp edi, esi
ja 0x424d31
mov ebx, dword [ecx]
add edi, dword [ebx + 8]
cmp edi, esi
ja 0x424e36
add ecx, 0x14
dec edx
jne 0x424d1d
mov dword [esp], ebp
jmp 0x424d41
mov dword [esp], ebp
xor eax, eax
mov ebx, dword [0x428040]
movzx ecx, word [ebx]
cmp ecx, 0x5a4d
jne 0x424d9a
mov ecx, dword [ebx + 0x3c]
cmp dword [ebx + ecx], 0x4550
jne 0x424d9a
add ebx, ecx
movzx ecx, word [ebx + 0x18]
cmp ecx, 0x10b
jne 0x424d9a
movzx ecx, word [ebx + 6]
test ecx, ecx
je 0x424d9a
mov edx, esi
sub edx, dword [0x428040]
movzx edi, word [ebx + 0x14]
lea ebp, [ebx + edi + 0x18]
mov edi, dword [ebp + 0xc]
cmp edi, edx
ja 0x424d94
mov ebx, dword [ebp + 8]
add ebx, edi
cmp ebx, edx
ja 0x424da5
add ebp, 0x28
dec ecx
jne 0x424d84
push esi
push str.Address__p_has_no_image_section
call 0x424e70
mov ecx, dword [0x4310c8]
lea ebx, [eax + eax*4]
mov dword [ecx + ebx*4 + 0x10], ebp
mov dword [ecx + ebx*4], 0
add edi, dword [0x428040]
mov dword [ecx + ebx*4 + 0xc], edi
lea eax, [esp + 4]
push 0x1c
push eax
push edi
call dword [sym.imp.KERNEL32.dll_VirtualQuery]
test eax, eax
je 0x424e49
mov eax, dword [esp + 0x18]
cmp eax, 7
jle 0x424df4
cmp eax, 8
mov ebp, dword [esp]
je 0x424e30
cmp eax, 0x40
je 0x424e30
cmp eax, 0x80
je 0x424e30
jmp 0x424e06
mov ecx, 4
cmp eax, 2
mov ebp, dword [esp]
je 0x424e0b
cmp eax, 4
je 0x424e30
mov ecx, 0x40
mov eax, dword [esp + 4]
mov edx, dword [0x4310c8]
lea edx, [edx + ebx*4]
mov dword [edx + 4], eax
mov edi, dword [esp + 0x10]
mov dword [edx + 8], edi
push edx
push ecx
push edi
push eax
call dword [sym.imp.KERNEL32.dll_VirtualProtect]
test eax, eax
je 0x424e5f
inc dword [0x4310a8]
push dword [esp + 0x34]
push ebp
push esi
call fcn.0040307b
add esp, 0x2c
pop esi
pop edi
pop ebx
pop ebp
ret
mov eax, dword [0x4310c8]
push dword [eax + ebx*4 + 0xc]
push dword [ebp + 8]
push str.__VirtualQuery_failed_for__d_bytes_at_address__p
call 0x424e70
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.__VirtualProtect_failed_with_code_0x_x
call 0x424e70
push edi
push esi
push eax
mov esi, dword [esp + 0x10]
lea eax, [esp + 0x14]
mov dword [esp], eax
mov edi, dword [sym.imp.msvcrt.dll__iob]
mov eax, dword [edi]
add eax, 0x40
push eax
push 1
push 0x1b
push str.Mingw_w64_runtime_failure:_n
call sub.msvcrt.dll_fwrite
add esp, 0x10
mov eax, dword [edi]
add eax, 0x40
push dword [esp]
push esi
push eax
call sub.msvcrt.dll_vfprintf
add esp, 0xc
call sub.msvcrt.dll_abort
push ebx
mov eax, dword [esp + 8]
mov eax, dword [eax]
mov eax, dword [eax]
lea ecx, [eax + 0x3fffff73]
cmp ecx, 9
ja case.default.0x424ec8
mov bl, 1
jmp dword [ecx*4 + 0x42f520]
xor ebx, ebx
push 0
push 8
call sub.msvcrt.dll_signal
add esp, 8
test eax, eax
je case.0x424ec8.1073741678
cmp eax, 1
jne 0x424f26
push 1
push 8
call sub.msvcrt.dll_signal
add esp, 8
xor eax, eax
dec eax
test bl, bl
jne 0x424f6b
fninit
jmp 0x424f6b
cmp eax, 0xc000001d
je case.0x424ec8.1073741674
cmp eax, 0xc0000005
jne case.0x424ec8.1073741678
push 0
push 0xb
call sub.msvcrt.dll_signal
add esp, 8
test eax, eax
je case.0x424ec8.1073741678
cmp eax, 1
jne 0x424f61
push 1
push 0xb
jmp 0x424f43
push 8
jmp 0x424f63
push 0
push 4
call sub.msvcrt.dll_signal
add esp, 8
test eax, eax
je case.0x424ec8.1073741678
cmp eax, 1
jne 0x424f5d
push 1
push 4
call sub.msvcrt.dll_signal
add esp, 8
jmp 0x424f68
mov eax, dword [0x431058]
test eax, eax
je 0x424f59
pop ebx
jmp eax
xor eax, eax
jmp 0x424f6b
push 4
jmp 0x424f63
push 0xb
call eax
add esp, 4
xor eax, eax
dec eax
pop ebx
ret 4