Function at 0x4103e1
Capabilities:
Write file on windows

Disassembly:
mov eax, 0x4a0c1c
call fcn.00497cb0
sub esp, 0x86c
push ebx
push esi
push edi
mov edi, ecx
mov eax, dword [edi + 0x8d48]
cmp eax, 8
je 0x410414
cmp eax, 0xb
je 0x410414
cmp eax, 9
je 0x410414
cmp eax, 0xa
jne 0x410a25
xor ebx, ebx
cmp byte [edi + 0x8efa], bl
je 0x41064e
cmp byte [edi + 0x38], bl
jne 0x41046c
cmp dword [edi + 0x34], ebx
je 0x410a25
lea esi, [edi + 0x30]
call fcn.0040b377
push esi
mov ebx, edi
call fcn.0040b308
cmp dword [ebp + 8], 0
jne 0x410462
push dword [edi + 0x34]
mov ecx, dword [esi]
call fcn.00488916
cmp eax, 0xf
mov dword [ebp + 8], eax
jne 0x410462
call fcn.0040b377
jmp 0x410a25
lea esi, [edi + 0x34]
call fcn.0040b377
xor ebx, ebx
mov ecx, dword [edi + 0x30]
cmp ecx, ebx
je 0x410a25
cmp dword [ebp + 8], ebx
mov byte [edi + 0x8efa], 0
mov byte [edi + 0x38], 0
jne 0x41064e
cmp byte [0x4bb215], 0
je 0x4104cd
lea eax, [edi + 0x8438]
push eax
call fcn.00486b80
push eax
call sub.MSVCR71.dll_strcmp
test eax, eax
pop ecx
pop ecx
je 0x4104cd
push ebx
push 0x16
call fcn.00410a36
push 0xffffffffffffffff
mov ecx, 0x4af
call fcn.004075db
push eax
mov ecx, edi
call fcn.0040e512
jmp 0x410a25
mov eax, dword [edi + 0x8d48]
cmp eax, 9
jne 0x410537
cmp byte [edi + 0x8ef9], 0
lea eax, [ebp - 0x24]
je 0x4104eb
push str.ASCII
jmp 0x4104f0
push str.BINARY
push eax
call sub.MSVCR71.dll_strcpy
lea eax, [edi + 0x8e08]
cmp dword [eax + 0x18], 0x10
pop ecx
pop ecx
jb 0x410509
mov eax, dword [eax + 4]
jmp 0x41050c
add eax, 4
mov esi, eax
call fcn.0041140e
push eax
lea eax, [ebp - 0x24]
push eax
push 0xffffffffffffffff
mov ecx, 0x41f
call fcn.004075db
push eax
lea eax, [ebp - 0x878]
push eax
call dword [sym.imp.MSVCR71.dll_sprintf]
add esp, 0x10
jmp 0x41056e
cmp eax, 0xa
jne 0x410579
lea eax, [edi + 0x8e08]
cmp dword [eax + 0x18], 0x10
jb 0x41054d
mov eax, dword [eax + 4]
jmp 0x410550
add eax, 4
push eax
push 0xffffffffffffffff
mov ecx, 0x508
call fcn.004075db
push eax
lea eax, [ebp - 0x878]
push eax
call dword [sym.imp.MSVCR71.dll_sprintf]
add esp, 0xc
lea eax, [ebp - 0x878]
jmp 0x410646
cmp eax, 8
jne 0x41062c
lea eax, [edi + 0x8de4]
cmp dword [eax + 0x18], 0x10
jb 0x410593
mov eax, dword [eax + 4]
jmp 0x410596
add eax, 4
lea ecx, [ebp - 0x78]
push ecx
push eax
call dword [sym.imp.MSVCR71.dll__stati64]
test eax, eax
pop ecx
pop ecx
jne 0x4105b7
mov ebx, dword [ebp - 0x5c]
test ebx, ebx
mov esi, dword [ebp - 0x60]
jg 0x4105bb
jl 0x4105b7
test esi, esi
ja 0x4105bb
xor esi, esi
xor ebx, ebx
cmp byte [edi + 0x8ef9], 0
lea eax, [ebp - 0x24]
je 0x4105ce
push str.ASCII
jmp 0x4105d3
push str.BINARY
push eax
call sub.MSVCR71.dll_strcpy
lea eax, [edi + 0x8e08]
cmp dword [eax + 0x18], 0x10
pop ecx
pop ecx
jb 0x4105ec
mov eax, dword [eax + 4]
jmp 0x4105ef
add eax, 4
push ebx
push esi
mov esi, eax
call fcn.0041140e
push eax
lea eax, [ebp - 0x24]
push eax
push 0xffffffffffffffff
mov ecx, 0x407
call fcn.004075db
push eax
lea eax, [ebp - 0x878]
push eax
call dword [sym.imp.MSVCR71.dll_sprintf]
add esp, 0x18
lea eax, [ebp - 0x878]
push eax
mov ecx, edi
call fcn.0040e512
xor ebx, ebx
jmp 0x41064e
cmp dword [edi + 0x8e28], 4
push 0xffffffffffffffff
mov ecx, 0x504
je 0x410641
mov ecx, 0x411
call fcn.004075db
mov ecx, edi
push eax
call fcn.0040e512
cmp byte [edi + 0x8d33], 0
jne 0x41067d
mov eax, dword [edi + 0x8d48]
cmp eax, 9
je 0x41066f
cmp eax, 0xa
je 0x41066f
push dword [edi + 0x8ccc]
jmp 0x410675
push dword [edi + 0x8cc8]
mov ecx, dword [edi + 0x30]
call fcn.00484c53
mov eax, dword [0x4b9300]
mov ecx, dword [edi + 0x30]
xor esi, esi
mov dword [ebp - 0x3c], eax
mov dword [ebp - 0x38], eax
inc esi
push esi
lea eax, [ebp - 0x44]
push eax
mov dword [ebp - 0x44], ebx
mov dword [ebp - 0x40], ebx
mov dword [ebp - 0x34], ebx
mov dword [ebp - 0x30], ebx
mov dword [ebp - 0x2c], ebx
call fcn.00484b24
mov dword [edi + 0x8118], ebx
mov dword [edi + 0x811c], ebx
mov dword [edi + 0x8150], ebx
mov dword [edi + 0x814c], ebx
call dword [sym.imp.WINMM.dll_timeGetTime]
cmp dword [ebp + 8], ebx
mov dword [edi + 0x80fc], eax
jne 0x4106d8
mov eax, dword [edi + 0x30]
call fcn.0040b26c
cmp byte [edi + 0x8d1d], 0
je 0x410743
mov eax, dword [edi + 0x8d48]
cmp eax, 9
mov bl, 1
je 0x4106f3
cmp eax, 0xa
jne 0x4106f5
xor bl, bl
mov ecx, dword [edi + 0x8d24]
test ecx, ecx
je 0x410704
mov eax, dword [ecx]
push esi
call dword [eax]
push 0x54
call sub.MSVCR71.dll_void____cdecl_operator_new_unsigned_int_
pop ecx
mov dword [ebp - 0x18], eax
and dword [ebp - 4], 0
test eax, eax
je 0x41072e
push dword [edi + 0x8d20]
mov esi, eax
push 0x8000
call fcn.0046742f
xor esi, esi
inc esi
jmp 0x410730
xor eax, eax
or dword [ebp - 4], 0xffffffff
mov dword [edi + 0x8d24], eax
mov byte [edi + 0x8d1e], 0
xor ebx, ebx
cmp dword [edi + 0x8d48], 0xb
mov cl, byte [edi + 0x8d15]
push 0x16
pop eax
mov byte [ebp - 0x14], cl
jne 0x41075c
mov byte [ebp - 0x14], 1
cmp dword [ebp + 8], ebx
jne 0x410775
cmp byte [edi + 0x8d14], 0
je 0x410775
push dword [ebp - 0x14]
mov ecx, dword [edi + 0x30]
call fcn.004885ec
mov ecx, dword [edi + 0x8d48]
cmp ecx, 8
je 0x4109e2
jle 0x410a25
cmp ecx, 0xa
jle 0x4107dd
cmp ecx, 0xb
jne 0x410a25
cmp dword [ebp + 8], ebx
jne 0x4107d2
cmp byte [edi + 0x8d14], 0
je 0x4107bd
cmp eax, ebx
jne 0x410a00
mov dword [edi + 0x8d48], 0xe
jmp 0x410a25
mov dword [edi + 0x8d48], 7
push ebx
call fcn.00410d3f
jmp 0x410a25
push ebx
push 0x40c
jmp 0x410a1d
cmp dword [ebp + 8], ebx
jne 0x4109d7
cmp byte [edi + 0x8d14], 0
je 0x410814
cmp eax, ebx
jne 0x410802
mov dword [edi + 0x8d48], 0xd
jmp 0x410a25
push ebx
push 0x4d4
push esi
push edi
call fcn.0040f2cd
jmp 0x410a25
lea ebx, [edi + 0x814c]
cmp dword [ebx], 0
mov dword [edi + 0x8d48], 6
je 0x410990
call dword [sym.imp.WINMM.dll_timeGetTime]
mov ecx, eax
sub ecx, dword [edi + 0x80fc]
mov dword [edi + 0x80fc], eax
add dword [edi + 0x8104], ecx
mov byte [ebp + 0xb], 0
cmp byte [edi + 0x8d1d], 0
je 0x4108cb
mov esi, dword [edi + 0x8d24]
test esi, esi
je 0x4108cb
cmp byte [edi + 0x8d1e], 0
jne 0x410990
push 0
lea ecx, [ebp - 0x14]
push ecx
lea ecx, [ebp - 0x28]
lea eax, [edi + 0xf9]
push ecx
push eax
mov eax, dword [ebx]
call fcn.004674f3
cmp eax, 1
je 0x4109ac
mov esi, dword [ebp - 0x14]
cmp esi, 0x8000
jg 0x4109ac
cmp eax, 2
jne 0x4108a6
mov byte [ebp + 0xb], 1
jmp 0x4108b6
cmp eax, 3
mov byte [ebp + 0xb], 0
jne 0x4108b6
mov byte [edi + 0x8d1e], 1
push esi
push dword [ebp - 0x28]
lea eax, [edi + 0xf9]
push eax
call sub.MSVCR71.dll_memcpy
add esp, 0xc
mov dword [ebx], esi
mov esi, dword [ebx]
test esi, esi
je 0x410986
mov eax, esi
cdq
add dword [edi + 0x8118], eax
lea ecx, [edi + 0x8110]
adc dword [edi + 0x811c], edx
add dword [ecx], eax
mov eax, esi
adc dword [ecx + 4], edx
neg eax
cdq
push edx
push eax
mov eax, dword [edi + 0x84ac]
call fcn.0040a56c
test eax, eax
je 0x4109ba
mov esi, dword [edi + 0x84c0]
test esi, esi
je 0x410923
cmp byte [edi + 0x84c4], 0
jne 0x410923
mov bl, 1
call fcn.00456f34
push 0
lea ecx, [ebp - 0x18]
push ecx
push dword [edi + 0x814c]
lea eax, [edi + 0xf9]
push eax
push dword [edi + 0x8148]
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov esi, dword [edi + 0x84c0]
test eax, eax
setne byte [ebp - 0xd]
test esi, esi
je 0x410959
xor bl, bl
call fcn.00456f34
cmp byte [ebp - 0xd], 0
je 0x4109c3
lea ebx, [edi + 0x814c]
mov eax, dword [ebx]
cmp dword [ebp - 0x18], eax
jne 0x4109c3
mov ecx, dword [edi + 0x84bc]
test ecx, ecx
je 0x410983
push eax
lea eax, [edi + 0xf9]
push eax
call fcn.00482da7
and dword [ebx], 0
cmp byte [ebp + 0xb], 0
jne 0x41084b
mov ecx, dword [edi + 0x30]
and dword [ebx], 0
push 0
push ebx
push 0x8000
lea eax, [edi + 0xf9]
push eax
call fcn.004868c8
jmp 0x410a25
push 0
push 0x4f5
push 1
jmp 0x410809
push 0
push 0x46f
jmp 0x4109b3
mov eax, dword [edi + 0x84ac]
call fcn.0040a746
push 0
push 0x424
jmp 0x4109b3
push ebx
push 0x421
jmp 0x410808
cmp dword [ebp + 8], ebx
jne 0x410a17
cmp byte [edi + 0x8d14], 0
je 0x410a08
cmp eax, ebx
jne 0x410a00
mov dword [edi + 0x8d48], 0xc
jmp 0x410a25
push ebx
push 0x4d4
jmp 0x410a1d
mov dword [edi + 0x8d48], 5
jmp 0x4107c7
push ebx
push 0x409
mov ecx, edi
push esi
call fcn.0040fad9
mov ecx, dword [ebp - 0xc]
pop edi
pop esi
mov dword fs:[0], ecx
pop ebx
leave
ret 4