Function at 0x423744
Capabilities:
Write file on windows

Disassembly:
push ebp
push ebx
push edi
push esi
sub esp, 0x24
mov dword [esp + 0x1c], edx
mov ebp, ecx
mov dword [esp], 0x800
push 0x800
call sym._malloc
add esp, 4
mov edi, eax
mov byte [eax], 0
mov dword [esp + 8], eax
mov dword [esp + 4], 0
cmp byte [0x506380], 0
je 0x423284
mov dword [edi], 0x6d315b1b
mov dword [esp + 4], 4
mov byte [edi + 4], 0
mov esi, 4
jmp 0x423286
xor esi, esi
mov ebx, dword [0x50633c]
test ebx, ebx
je 0x4232e8
mov eax, esi
xor eax, 0x7ff
cmp eax, ebx
jae 0x4232cf
mov dword [esp + 0x18], ebp
lea eax, [ebx + esi]
inc eax
mov ecx, 0x800
nop dword [eax + eax]
mov ebp, ecx
add ecx, ecx
cmp eax, ebp
ja 0x4232b0
push ebp
push edi
call sym._realloc
add esp, 8
mov edi, eax
mov dword [esp + 8], eax
mov dword [esp], ebp
mov ebp, dword [esp + 0x18]
lea eax, [edi + esi]
push ebx
push 0xa
push eax
call sym._memset
add esp, 0xc
add esi, ebx
mov dword [esp + 4], esi
mov byte [edi + esi], 0
mov esi, dword [0x506340]
test esi, esi
je 0x42338c
mov eax, dword [esp]
mov ebx, dword [esp + 4]
test eax, eax
je 0x42330b
mov ecx, ebx
not ecx
add ecx, eax
cmp ecx, esi
jae 0x42333d
mov dword [esp + 0x18], ebp
cmp eax, 2
mov ecx, 0x20
cmovae ecx, eax
lea edx, [esi + ebx]
inc edx
nop
mov ebp, ecx
add ecx, ecx
cmp edx, ebp
ja 0x423320
test eax, eax
je 0x423343
push ebp
push dword [esp + 0xc]
call sym._realloc
add esp, 8
mov edi, eax
jmp 0x423368
mov edi, dword [esp + 8]
jmp 0x423373
push ebp
call sym._malloc
add esp, 4
mov edi, eax
test ebx, ebx
je 0x423365
lea eax, [ebx + 1]
push eax
push dword [esp + 0xc]
push edi
call sym._memcpy
add esp, 0xc
jmp 0x423368
mov byte [edi], 0
mov dword [esp + 8], edi
mov dword [esp], ebp
mov ebp, dword [esp + 0x18]
lea eax, [edi + ebx]
push esi
push 0x20
push eax
call sym._memset
add esp, 0xc
add ebx, esi
mov dword [esp + 4], ebx
mov byte [edi + ebx], 0
mov eax, dword [0x50633c]
mov dword [0x507638], eax
cmp byte [esp + 0x1c], 0
je 0x4233d2
mov eax, esp
push dword [0x5062d0]
push 0x4f2250
push eax
call dbg.ffStrbufAppendF
add esp, 0xc
jmp 0x4233d2
xor eax, eax
movzx ecx, byte [esp + 0x10]
mov al, cl
add ebp, eax
inc ebp
inc dword [0x507638]
mov dword [esp + 0xc], 0
jmp 0x4233fa
mov edi, dword [esp + 8]
mov dword [edi + esi], 0x20202020
mov eax, dword [esp + 4]
add eax, 4
mov dword [esp + 4], eax
add eax, dword [esp + 8]
mov byte [eax], 0
inc ebp
movzx ebx, byte [ebp]
cmp ebx, 0x1b
ja case.0x423407.1
jmp dword [ebx*4 + 0x4f2338]
mov eax, dword [esp]
mov esi, dword [esp + 4]
test eax, eax
je 0x423424
mov ecx, esi
not ecx
add ecx, eax
cmp ecx, 4
jae 0x4233dc
cmp eax, 2
mov ecx, eax
mov edx, 0x20
cmovb ecx, edx
lea edx, [esi + 5]
nop word cs:[eax + eax]
mov ebx, ecx
add ecx, ecx
cmp edx, ebx
ja 0x423440
test eax, eax
je 0x4234b3
push ebx
push dword [esp + 0xc]
call sym._realloc
add esp, 8
mov edi, eax
jmp 0x423500
cmp byte [ebp + 1], 0x5b
jne 0x42374e
mov eax, dword [esp]
mov esi, dword [esp + 4]
test eax, eax
je 0x423480
mov ecx, esi
not ecx
add ecx, eax
cmp ecx, 2
jae 0x4234ad
cmp eax, 2
mov ecx, eax
mov edx, 0x20
cmovb ecx, edx
lea edx, [esi + 3]
mov ebx, ecx
add ecx, ecx
cmp edx, ebx
ja 0x423490
test eax, eax
je 0x4234d5
push ebx
push dword [esp + 0xc]
call sym._realloc
add esp, 8
mov edi, eax
jmp 0x423510
mov edi, dword [esp + 8]
jmp 0x423517
push ebx
call sym._malloc
add esp, 4
mov edi, eax
test esi, esi
je 0x4234f7
lea eax, [esi + 1]
push eax
push dword [esp + 0xc]
push edi
call sym._memcpy
add esp, 0xc
jmp 0x423500
push ebx
call sym._malloc
add esp, 4
mov edi, eax
test esi, esi
je 0x42350c
lea eax, [esi + 1]
push eax
push dword [esp + 0xc]
push edi
call sym._memcpy
add esp, 0xc
jmp 0x423510
mov byte [edi], 0
nop word [eax + eax]
mov dword [esp + 8], edi
mov dword [esp], ebx
jmp 0x4233e0
mov byte [edi], 0
nop
mov dword [esp + 8], edi
mov dword [esp], ebx
mov word [edi + esi], 0x5b1b
mov eax, dword [esp + 4]
mov ecx, dword [esp + 8]
lea edx, [eax + 2]
mov dword [esp + 4], edx
mov byte [ecx + eax + 2], 0
lea edx, [ebp + 2]
mov dword [esp + 0x18], ebp
movsx ebx, byte [ebp + 2]
cmp ebx, 0x3b
je 0x423550
mov eax, ebx
add eax, 0xffffffd0
cmp eax, 9
ja 0x42361e
nop
mov eax, dword [esp]
mov ebp, dword [esp + 4]
test eax, eax
je 0x423562
lea ecx, [ebp + 1]
cmp eax, ecx
jne 0x4235a0
mov dword [esp + 0x10], ebx
mov ebx, edx
cmp eax, 2
mov ecx, eax
mov edx, 0x20
cmovb ecx, edx
lea edx, [ebp + 2]
nop dword [eax + eax]
mov esi, ecx
add ecx, ecx
cmp edx, esi
ja 0x423580
test eax, eax
je 0x4235b0
push esi
push dword [esp + 0xc]
call sym._realloc
add esp, 8
mov edi, eax
jmp 0x4235e0
mov edi, dword [esp + 8]
jmp 0x4235f0
push esi
call sym._malloc
add esp, 4
mov edi, eax
test ebp, ebp
je 0x4235d2
lea eax, [ebp + 1]
push eax
push dword [esp + 0xc]
push edi
call sym._memcpy
add esp, 0xc
jmp 0x4235e0
mov byte [edi], 0
nop word cs:[eax + eax]
mov edx, ebx
mov dword [esp + 8], edi
mov dword [esp], esi
lea ecx, [ebp + 1]
mov ebx, dword [esp + 0x10]
inc edx
mov dword [esp + 4], ecx
mov byte [edi + ebp], bl
mov eax, dword [esp + 4]
mov ecx, dword [esp + 8]
mov byte [ecx + eax], 0
movsx ebx, byte [edx]
cmp ebx, 0x3b
je 0x423550
mov eax, ebx
add eax, 0xffffffd0
cmp eax, 0xa
jb 0x423550
test bl, bl
js 0x42375b
mov eax, dword [esp]
mov ebp, dword [esp + 4]
test eax, eax
je 0x423638
lea ecx, [ebp + 1]
cmp eax, ecx
jne 0x42366d
mov dword [esp + 0x10], ebx
mov ebx, edx
cmp eax, 2
mov ecx, eax
mov edx, 0x20
cmovb ecx, edx
lea edx, [ebp + 2]
nop
mov esi, ecx
add ecx, ecx
cmp edx, esi
ja 0x423650
test eax, eax
je 0x423673
push esi
push dword [esp + 0xc]
call sym._realloc
add esp, 8
mov edi, eax
jmp 0x4236a0
mov edi, dword [esp + 8]
jmp 0x4236b0
push esi
call sym._malloc
add esp, 4
mov edi, eax
test ebp, ebp
je 0x423695
lea eax, [ebp + 1]
push eax
push dword [esp + 0xc]
push edi
call sym._memcpy
add esp, 0xc
jmp 0x4236a0
mov byte [edi], 0
nop dword [eax + eax]
mov edx, ebx
mov ebx, dword [esp + 0x10]
mov dword [esp + 8], edi
mov dword [esp], esi
lea ecx, [ebp + 1]
mov dword [esp + 4], ecx
mov byte [edi + ebp], bl
mov eax, dword [esp + 8]
add eax, dword [esp + 4]
mov ebp, edx
jmp 0x4233f6
cmp bl, 0x24
jne 0x4238e4
cmp byte [esp + 0x1c], 0
je 0x4238e4
movzx eax, byte [ebp + 1]
cmp eax, 0x24
je 0x4236eb
test eax, eax
jne 0x4237b8
mov eax, dword [esp]
mov esi, dword [esp + 4]
test eax, eax
je 0x423701
lea ecx, [esi + 1]
cmp eax, ecx
jne 0x423814
cmp eax, 2
mov ecx, eax
mov edx, 0x20
cmovb ecx, edx
lea edx, [esi + 2]
nop word cs:[eax + eax]
mov ebx, ecx
add ecx, ecx
cmp edx, ebx
ja 0x423720
test eax, eax
je 0x42381a
push ebx
push dword [esp + 0xc]
call sym._realloc
add esp, 8
mov edi, eax
jmp 0x423863
cmp byte [ebp + 1], 0xa
je case.0x423407.10
mov dword [esp + 0x14], 1
jmp 0x4238f6
mov ecx, dword [esp + 0x18]
not ecx
mov eax, dword [esp + 0xc]
add eax, edx
add eax, ecx
mov dword [esp + 0xc], eax
movzx eax, bl
mov ecx, eax
and ecx, 0xffffffe0
cmp ecx, 0xc0
jne 0x423787
mov dword [esp + 0x14], 2
jmp 0x4237b1
mov ecx, eax
and ecx, 0xfffffff0
mov dword [esp + 0x14], 3
cmp ecx, 0xe0
je 0x4237b1
and eax, 0xfffffff8
xor ecx, ecx
cmp eax, 0xf0
sete cl
lea eax, [ecx + ecx*2]
inc eax
mov dword [esp + 0x14], eax
mov ebp, edx
jmp 0x4238f6
movsx eax, al
mov ecx, eax
add cl, 0xc6
cmp cl, 0xf6
ja 0x42383c
mov eax, dword [esp]
mov esi, dword [esp + 4]
test eax, eax
je 0x4237db
lea ecx, [esi + 1]
cmp eax, ecx
jne 0x42388d
cmp eax, 2
mov ecx, eax
mov edx, 0x20
cmovb ecx, edx
lea edx, [esi + 2]
nop dword [eax + eax]
mov ebx, ecx
add ecx, ecx
cmp edx, ebx
ja 0x4237f0
test eax, eax
je 0x423893
push ebx
push dword [esp + 0xc]
call sym._realloc
add esp, 8
mov edi, eax
jmp 0x4238b8
mov edi, dword [esp + 8]
jmp 0x42386d
push ebx
call sym._malloc
add esp, 4
mov edi, eax
test esi, esi
je 0x423860
lea eax, [esi + 1]
push eax
push dword [esp + 0xc]
push edi
call sym._memcpy
add esp, 0xc
jmp 0x423863
lea eax, [eax + eax*2]
push dword [eax*4 + 0x506084]
push 0x4f2250
lea eax, [esp + 8]
push eax
call dbg.ffStrbufAppendF
add esp, 0xc
add ebp, 2
jmp 0x4233fa
mov byte [edi], 0
mov dword [esp + 8], edi
mov dword [esp], ebx
lea ecx, [esi + 1]
mov dword [esp + 4], ecx
mov byte [edi + esi], 0x24
mov eax, dword [esp + 4]
mov ecx, dword [esp + 8]
mov byte [ecx + eax], 0
inc dword [esp + 0xc]
add ebp, 2
jmp 0x4233fa
mov edi, dword [esp + 8]
jmp 0x4238c2
push ebx
call sym._malloc
add esp, 4
mov edi, eax
test esi, esi
je 0x4238b5
lea eax, [esi + 1]
push eax
push dword [esp + 0xc]
push edi
call sym._memcpy
add esp, 0xc
jmp 0x4238b8
mov byte [edi], 0
mov dword [esp + 8], edi
mov dword [esp], ebx
lea ecx, [esi + 1]
mov edx, dword [esp + 0xc]
inc ebp
mov dword [esp + 4], ecx
mov byte [edi + esi], 0x24
mov eax, dword [esp + 4]
mov ecx, dword [esp + 8]
mov byte [ecx + eax], 0
inc edx
mov dword [esp + 0xc], edx
movzx ebx, byte [ebp]
mov dword [esp + 0x14], 1
mov edx, ebp
test bl, bl
js 0x42376d
inc dword [esp + 0xc]
xor esi, esi
mov edx, dword [esp + 0x14]
jmp 0x423933
mov eax, edi
mov edi, dword [esp + 8]
inc ebp
mov dword [esp + 4], ecx
mov byte [edi + eax], bl
mov eax, dword [esp + 4]
mov ecx, dword [esp + 8]
mov byte [ecx + eax], 0
inc esi
cmp esi, edx
je 0x4233fa
movzx ebx, byte [ebp]
test bl, bl
je 0x4233fa
mov eax, dword [esp]
mov edi, dword [esp + 4]
test eax, eax
je 0x423951
lea ecx, [edi + 1]
cmp eax, ecx
jne 0x423910
mov dword [esp + 0x18], ebp
cmp eax, 2
mov ecx, eax
mov edx, 0x20
cmovb ecx, edx
lea edx, [edi + 2]
nop word cs:[eax + eax]
mov ebp, ecx
add ecx, ecx
cmp edx, ebp
ja 0x423970
test eax, eax
mov dword [esp + 0x10], edi
je 0x4239a0
push ebp
push dword [esp + 0xc]
call sym._realloc
add esp, 8
mov edi, eax
jmp 0x4239d0
push ebp
call sym._malloc
add esp, 4
mov ecx, edi
mov edi, eax
test ecx, ecx
je 0x4239c4
lea eax, [ecx + 1]
push eax
push dword [esp + 0xc]
push edi
call sym._memcpy
add esp, 0xc
jmp 0x4239d0
mov byte [edi], 0
nop word [eax + eax]
mov edx, dword [esp + 0x14]
mov dword [esp + 8], edi
mov dword [esp], ebp
mov eax, dword [esp + 0x10]
lea ecx, [eax + 1]
mov ebp, dword [esp + 0x18]
jmp 0x423916
mov edi, dword [0x506344]
mov eax, dword [esp]
mov esi, dword [esp + 4]
test edi, edi
je 0x423aaf
test eax, eax
mov dword [esp + 0x10], edi
je 0x423a17
mov ecx, esi
not ecx
add ecx, eax
cmp ecx, edi
jae 0x423a4d
cmp eax, 2
mov ecx, eax
mov edx, 0x20
cmovb ecx, edx
lea edx, [edi + esi]
inc edx
nop dword [eax + eax]
mov ebx, ecx
add ecx, ecx
cmp edx, ebx
ja 0x423a30
test eax, eax
je 0x423a53
push ebx
push dword [esp + 0xc]
call sym._realloc
add esp, 8
mov edi, eax
jmp 0x423a80
mov edi, dword [esp + 8]
jmp 0x423a87
push ebx
call sym._malloc
add esp, 4
mov edi, eax
test esi, esi
je 0x423a75
lea eax, [esi + 1]
push eax
push dword [esp + 0xc]
push edi
call sym._memcpy
add esp, 0xc
jmp 0x423a80
mov byte [edi], 0
nop dword [eax + eax]
mov dword [esp + 8], edi
mov dword [esp], ebx
lea eax, [edi + esi]
mov ebx, dword [esp + 0x10]
push ebx
push 0x20
push eax
call sym._memset
add esp, 0xc
add esi, ebx
mov dword [esp + 4], esi
mov byte [edi + esi], 0
movzx ebx, byte [ebp]
mov eax, dword [esp]
mov esi, dword [esp + 4]
cmp bl, 0xd
sete byte [esp + 0x10]
test eax, eax
je 0x423ac2
lea ecx, [esi + 1]
cmp eax, ecx
jne 0x423afd
cmp eax, 2
mov ecx, eax
mov edx, 0x20
cmovb ecx, edx
lea edx, [esi + 2]
nop word cs:[eax + eax]
mov ebx, ecx
add ecx, ecx
cmp edx, ebx
ja 0x423ae0
test eax, eax
je 0x423b03
push ebx
push dword [esp + 0xc]
call sym._realloc
add esp, 8
mov edi, eax
jmp 0x423b30
mov edi, dword [esp + 8]
jmp 0x423b3a
push ebx
call sym._malloc
add esp, 4
mov edi, eax
test esi, esi
je 0x423b25
lea eax, [esi + 1]
push eax
push dword [esp + 0xc]
push edi
call sym._memcpy
add esp, 0xc
jmp 0x423b30
mov byte [edi], 0
nop dword [eax + eax]
mov dword [esp + 8], edi
mov dword [esp], ebx
lea ecx, [esi + 1]
mov edx, dword [esp + 0xc]
mov dword [esp + 4], ecx
mov byte [edi + esi], 0xa
mov eax, dword [esp + 4]
mov ecx, dword [esp + 8]
mov byte [ecx + eax], 0
mov esi, dword [0x506340]
test esi, esi
je 0x423c08
mov eax, dword [esp]
mov ebx, dword [esp + 4]
test eax, eax
je 0x423b75
mov ecx, ebx
not ecx
add ecx, eax
cmp ecx, esi
jae 0x423bad
mov dword [esp + 0x18], ebp
cmp eax, 2
mov ecx, eax
mov edx, 0x20
cmovb ecx, edx
lea edx, [esi + ebx]
inc edx
nop word [eax + eax]
mov ebp, ecx
add ecx, ecx
cmp edx, ebp
ja 0x423b90
test eax, eax
je 0x423bb3
push ebp
push dword [esp + 0xc]
call sym._realloc
add esp, 8
mov edi, eax
jmp 0x423be0
mov edi, dword [esp + 8]
jmp 0x423beb
push ebp
call sym._malloc
add esp, 4
mov edi, eax
test ebx, ebx
je 0x423bd5
lea eax, [ebx + 1]
push eax
push dword [esp + 0xc]
push edi
call sym._memcpy
add esp, 0xc
jmp 0x423be0
mov byte [edi], 0
nop dword [eax + eax]
mov dword [esp + 8], edi
mov dword [esp], ebp
mov ebp, dword [esp + 0x18]
lea eax, [edi + ebx]
push esi
push 0x20
push eax
call sym._memset
add esp, 0xc
add ebx, esi
mov dword [esp + 4], ebx
mov byte [edi + ebx], 0
mov edx, dword [esp + 0xc]
cmp edx, dword [0x507634]
jbe 0x4233c0
mov dword [0x507634], edx
jmp 0x4233c0
mov eax, dword [esp]
mov edi, dword [esp + 4]
test eax, eax
je 0x423c35
mov ecx, edi
not ecx
add ecx, eax
cmp ecx, 4
jae 0x423c6d
cmp eax, 2
mov ecx, 0x20
cmovae ecx, eax
lea edx, [edi + 5]
nop word cs:[eax + eax]
mov ebx, ecx
add ecx, ecx
cmp edx, ebx
ja 0x423c50
test eax, eax
je 0x423c73
push ebx
push dword [esp + 0xc]
call sym._realloc
add esp, 8
mov esi, eax
jmp 0x423c98
mov esi, dword [esp + 8]
jmp 0x423c9f
push ebx
call sym._malloc
add esp, 4
mov esi, eax
test edi, edi
je 0x423c95
lea eax, [edi + 1]
push eax
push dword [esp + 0xc]
push esi
call sym._memcpy
add esp, 0xc
jmp 0x423c98
mov byte [esi], 0
mov dword [esp + 8], esi
mov dword [esp], ebx
mov ebx, dword [esp + 0xc]
mov dword [esi + edi], 0x6d305b1b
mov eax, dword [esp + 4]
mov ecx, dword [esp + 8]
lea edx, [eax + 4]
mov dword [esp + 4], edx
mov byte [ecx + eax + 4], 0
cmp byte [0x50634b], 0
je 0x423d2d
mov dword [0x507638], 0
mov dword [0x507634], 0
mov edi, dword [0x506344]
test edi, edi
je 0x423dad
mov eax, dword [esp]
mov ebx, dword [esp + 4]
test eax, eax
je 0x423cfe
mov ecx, ebx
not ecx
add ecx, eax
cmp ecx, edi
jae 0x423d62
cmp eax, 2
mov ecx, 0x20
cmovae ecx, eax
lea edx, [edi + ebx]
inc edx
nop dword [eax]
mov ebp, ecx
add ecx, ecx
cmp edx, ebp
ja 0x423d10
test eax, eax
je 0x423d68
push ebp
push dword [esp + 0xc]
call sym._realloc
add esp, 8
mov esi, eax
jmp 0x423d8d
mov eax, dword [0x507634]
cmp ebx, eax
cmova eax, ebx
add eax, dword [0x506340]
add eax, dword [0x506344]
mov dword [0x507634], eax
push dword [0x507638]
push str.e_1Ge__uA
lea eax, [esp + 8]
push eax
call dbg.ffStrbufAppendF
add esp, 0xc
jmp 0x423dad
mov esi, dword [esp + 8]
jmp 0x423d94
push ebp
call sym._malloc
add esp, 4
mov esi, eax
test ebx, ebx
je 0x423d8a
lea eax, [ebx + 1]
push eax
push dword [esp + 0xc]
push esi
call sym._memcpy
add esp, 0xc
jmp 0x423d8d
mov byte [esi], 0
mov dword [esp + 8], esi
mov dword [esp], ebp
lea eax, [esi + ebx]
push edi
push 0xa
push eax
call sym._memset
add esp, 0xc
add ebx, edi
mov dword [esp + 4], ebx
mov byte [esi + ebx], 0
push 1
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll__get_osfhandle]
add esp, 4
lea ecx, [esp + 0x20]
push 0
push ecx
push dword [esp + 0xc]
push dword [esp + 0x14]
push eax
call dword [sym.imp.KERNEL32.dll_WriteFile]
cmp dword [esp], 0
mov dword [esp + 4], 0
je 0x423def
mov dword [esp], 0
push dword [esp + 8]
call sym._free
add esp, 4
add esp, 0x24
pop esi
pop edi
pop ebx
pop ebp
ret