Function at 0x10055ed8
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x348
push ebx
mov ebx, dword [ebp + 0x14]
push esi
cmp ebx, 3
push edi
mov esi, ecx
je 0x10055f0a
cmp ebx, 2
je 0x10055fb2
cmp ebx, 1
je 0x10055fb2
mov eax, 0x10000
jmp 0x10056258
mov eax, dword [esi + 4]
mov edi, dword [ebp + 8]
cmp edi, eax
je 0x10055f59
cmp eax, 0xffffffff
je 0x10055f21
push dword [esi]
call fcn.100556f0
pop ecx
mov eax, dword [esi]
or dword [esi + 4], 0xffffffff
cmp edi, dword [eax + 4]
jge 0x10055f00
cmp edi, dword [eax + 0x10]
jge 0x10055f38
push eax
call fcn.100550ad
pop ecx
mov eax, dword [esi]
cmp dword [eax + 0x10], edi
jge 0x10055f47
push eax
call fcn.100550eb
jmp 0x10055f37
push dword [esi + 0x138]
push dword [esi]
call fcn.10055379
pop ecx
mov dword [esi + 4], edi
pop ecx
lea eax, [ebp + 0xb]
push eax
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push dword [esi]
call fcn.100554d9
mov edi, eax
add esp, 0x10
test edi, edi
jg 0x10055f7f
push dword [esi]
call fcn.100556f0
or dword [esi + 4], 0xffffffff
pop ecx
cmp byte [ebp + 0xb], 0
je 0x10055f8c
xor eax, eax
jmp 0x10056258
test edi, edi
jle 0x10055f9a
mov eax, 0x600
jmp 0x10056258
xor eax, eax
cmp edi, 0xffffff96
setne al
dec eax
and eax, 0xfb001000
add eax, 0x5000000
jmp 0x10056258
cmp dword [esi + 4], 0xffffffff
je 0x10055fc0
push dword [esi]
call fcn.100556f0
pop ecx
mov eax, dword [esi]
mov edi, dword [ebp + 8]
or dword [esi + 4], 0xffffffff
cmp edi, dword [eax + 4]
jge 0x10055f00
cmp edi, dword [eax + 0x10]
jge 0x10055fde
push eax
call fcn.100550ad
pop ecx
mov eax, dword [esi]
cmp dword [eax + 0x10], edi
jge 0x10055fed
push eax
call fcn.100550eb
jmp 0x10055fdd
lea eax, [ebp - 0x244]
mov ecx, esi
push eax
push edi
call fcn.1005580c
mov eax, dword [ebp - 0x13c]
shr eax, 4
test al, 1
je 0x10056042
cmp ebx, 1
je 0x10055f85
mov ecx, dword [ebp + 0xc]
mov al, byte [ecx]
cmp al, 0x2f
je 0x10056029
cmp al, 0x5c
je 0x10056029
test al, al
je 0x1005602e
cmp byte [ecx + 1], 0x3a
jne 0x1005602e
push ecx
push 0
jmp 0x10056036
add esi, 0x140
push ecx
push esi
call fcn.10055da6
pop ecx
pop ecx
jmp 0x10055f85
and byte [ebp - 0x348], 0
cmp ebx, 1
jne 0x10056056
mov eax, dword [ebp + 0xc]
jmp 0x100560fe
mov edi, dword [ebp + 0xc]
mov ebx, edi
mov ecx, edi
mov al, byte [edi]
test al, al
je 0x10056074
cmp al, 0x2f
je 0x1005606b
cmp al, 0x5c
jne 0x1005606e
lea ebx, [ecx + 1]
mov al, byte [ecx + 1]
inc ecx
jmp 0x1005605f
push 0x104
lea eax, [ebp - 0x118]
push edi
push eax
call fcn.100557f7
add esp, 0xc
cmp ebx, edi
jne 0x10056114
and byte [ebp - 0x118], 0
lea eax, [ebp - 0x118]
push ebx
lea edi, [esi + 0x140]
push eax
lea eax, [ebp - 0x14]
push edi
push eax
call fcn.1004562a
pop ecx
mov ecx, eax
call fcn.10001b9f
push eax
lea eax, [ebp - 0x348]
push eax
call fcn.1005fc76
add esp, 0x14
lea ecx, [ebp - 0x14]
call fcn.10001b7f
lea eax, [ebp - 0x118]
push eax
push edi
call fcn.10055da6
pop ecx
xor eax, eax
pop ecx
push eax
push dword [ebp - 0x13c]
push 2
push eax
push eax
lea eax, [ebp - 0x348]
push 0x40000000
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
cmp eax, 0xffffffff
mov dword [ebp + 0x10], eax
jne 0x1005618b
mov eax, 0x200
jmp 0x10056258
mov eax, ebx
sub eax, edi
and byte [ebp + eax - 0x118], 0
cmp byte [ebp - 0x118], 0x2f
je 0x1005614c
cmp byte [ebp - 0x118], 0x5c
je 0x1005614c
cmp byte [ebp - 0x118], 0
je 0x10056098
cmp byte [ebp - 0x117], 0x3a
jne 0x10056098
lea eax, [ebp - 0x118]
push ebx
push eax
lea eax, [ebp - 0x14]
push eax
call fcn.10045524
pop ecx
mov ecx, eax
call fcn.10001b9f
push eax
lea eax, [ebp - 0x348]
push eax
call fcn.1005fc76
add esp, 0x10
lea ecx, [ebp - 0x14]
call fcn.10001b7f
lea eax, [ebp - 0x118]
push eax
push 0
jmp 0x100560d8
push dword [esi + 0x138]
push dword [esi]
call fcn.10055379
cmp dword [esi + 0x13c], 0
pop ecx
pop ecx
mov ebx, 0x4000
jne 0x100561b5
push ebx
call fcn.100789de
pop ecx
mov dword [esi + 0x13c], eax
and dword [ebp + 8], 0
lea eax, [ebp + 0xf]
push eax
push ebx
push dword [esi + 0x13c]
push dword [esi]
call fcn.100554d9
mov edi, eax
add esp, 0x10
cmp edi, 0xffffff96
je 0x10056201
test edi, edi
jl 0x10056213
jle 0x100561f5
lea eax, [ebp - 4]
push 0
push eax
push edi
push dword [esi + 0x13c]
push dword [ebp + 0x10]
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x1005620a
cmp byte [ebp + 0xf], 0
jne 0x1005621a
test edi, edi
je 0x10056213
jmp 0x100561b9
mov dword [ebp + 8], 0x1000
jmp 0x1005621a
mov dword [ebp + 8], 0x400
jmp 0x1005621a
mov dword [ebp + 8], 0x5000000
push dword [esi]
call fcn.100556f0
cmp dword [ebp + 8], 0
pop ecx
jne 0x10056246
lea eax, [ebp - 0x128]
push eax
lea eax, [ebp - 0x138]
push eax
lea eax, [ebp - 0x130]
push eax
push dword [ebp + 0x10]
call dword [sym.imp.KERNEL32.dll_SetFileTime]
cmp dword [ebp + 0x14], 1
je 0x10056255
push dword [ebp + 0x10]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [ebp + 8]
pop edi
pop esi
pop ebx
leave
ret 0x10