Function at 0x10003680
Capabilities:
Read file on windows
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x28
push ebx
push esi
push edi
call dword [sym.imp.KERNEL32.dll_GetCurrentProcessId]
cmp eax, dword [0x100611dc]
jne 0x10003797
cmp byte [0x100611b5], 0
je 0x10003797
cmp dword [ebp + 0x14], 0
mov dword [ebp - 0xc], 0
je 0x100036cf
mov eax, 0x10061998
mov ecx, 0x100612f0
mov dword [ebp - 8], eax
mov ebx, 0x100619a4
mov eax, dword [ebp + 0x18]
mov dword [ebp - 0xc], eax
jmp 0x100036e1
mov eax, 0x10061990
mov ecx, 0x100611e8
mov ebx, 0x100619a0
mov dword [ebp - 8], eax
mov eax, dword [ebx]
xorps xmm0, xmm0
mov dword [ebp - 0x10], ebx
mov dword [ebp - 0x14], ecx
movlpd qword [ebp - 0x28], xmm0
movlpd qword [ebp - 0x20], xmm0
test eax, eax
jne 0x10003764
cmp byte [0x100614ff], al
jne 0x10003764
lea edx, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x10003705
sub ecx, edx
je 0x10003758
push edi
add edi, edx
sbb edi, eax
mov edi, 0x3695f65a
mov edi, 0xf7cc247d
pop edi
mov esi, dword [ebp - 0x14]
lea eax, [ebp + 0x18]
mov word [ebp + 0x18], 0x61
push eax
push esi
mov dword [ebp - 4], 0x622b72
call fcn.100318c8
mov ebx, dword [ebp - 0x10]
push ebx
mov dword [ebx], eax
call fcn.1000bcd0
lea eax, [ebp - 4]
push eax
push esi
call fcn.100318c8
add esp, 0x14
mov dword [ebx], eax
test eax, eax
jne 0x10003764
or eax, 0xffffffff
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x14
push 2
push 0
push eax
call fcn.10031f97
add esp, 0xc
test eax, eax
jne 0x10003797
lea eax, [ebp - 0x20]
push eax
push dword [ebx]
call fcn.1003156e
add esp, 8
test eax, eax
je 0x100037a2
push ebx
add ebx, esp
add ebx, edx
xor ebx, eax
add ebx, esi
mov ebx, 0xbc5e02a7
nop
pop ebx
xor eax, eax
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x14
mov eax, dword [ebp - 0x20]
or eax, dword [ebp - 0x1c]
mov edi, dword [ebp - 8]
jne 0x10003808
push 0
push 0
push dword [ebx]
mov dword [edi], 0
mov dword [edi + 4], 0
call fcn.10031f97
add esp, 0xc
mov esi, 0x1518a
nop dword [eax]
push dword [ebx]
lea eax, [ebp - 0x28]
push 1
push 8
push eax
call fcn.1003285a
add esp, 0x10
sub esi, 1
jne 0x100037d0
push 2
push 0
push dword [ebx]
call fcn.10031f97
add esp, 0xc
test eax, eax
je 0x100038ab
xor eax, eax
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x14
mov ecx, dword [edi]
mov eax, ecx
mov edx, dword [edi + 4]
or eax, edx
jne 0x10003889
push eax
push eax
push dword [ebx]
call fcn.10031f97
add esp, 0xc
test eax, eax
jne 0x10003797
lea esi, [eax + 1]
nop word [eax + eax]
push dword [ebx]
lea eax, [ebp - 0x28]
push 1
push 8
push eax
call fcn.10031b20
mov eax, dword [ebp - 0x28]
add esp, 0x10
or eax, dword [ebp - 0x24]
je 0x10003855
inc esi
cmp esi, 0x1518b
jl 0x10003830
jmp 0x10003862
lea eax, [esi*8 - 8]
cdq
mov dword [edi], eax
mov dword [edi + 4], edx
cmp esi, 0x1518a
jle 0x100037e7
push eax
mov eax, 0x54361a00
add eax, edx
xor eax, edx
add eax, edx
sub eax, ebx
nop
pop eax
xor eax, eax
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x14
cmp byte [0x100611b6], 0
jne 0x100038a0
test edx, edx
jg 0x100038ab
jl 0x100038a0
cmp ecx, 0x22b
jae 0x100038ab
add ecx, 8
mov dword [edi], ecx
adc edx, 0
mov dword [edi + 4], edx
push 0
call fcn.10030dff
push dword [ebx]
mov dword [ebp - 0x18], eax
lea eax, [ebp - 0x18]
push 1
push 4
push eax
call fcn.1003285a
push dword [ebx]
push 0x1e
push 1
push 0x10061864
call fcn.1003285a
add esp, 0x24
cmp dword [ebp + 0x14], 0
jne 0x100038ec
lea eax, [ebp - 0xc]
push eax
mov eax, dword [ebp + 8]
push dword [eax]
call dword [sym.imp.OLEAUT32.dll_SafeArrayUnaccessData]
push dword [ebx]
push dword [ebp + 0xc]
push 1
push dword [ebp - 0xc]
call fcn.1003285a
lea eax, [ebp - 0x20]
push eax
push dword [ebx]
call fcn.1003156e
push edi
push dword [ebx]
call fcn.10031c51
push dword [ebx]
add dword [ebp - 0x20], 1
lea eax, [ebp - 0x20]
push 1
adc dword [ebp - 0x1c], 0
push 8
push eax
call fcn.1003285a
push 0
push dword [ebx]
call fcn.1000bd60
add esp, 0x38
push ebp
sbb ebp, esi
sbb ebp, eax
sub ebp, ebx
or ebp, ebp
pop ebp
cmp byte [0x100611bc], 0
je 0x1000395f
mov eax, dword [ebp - 8]
cmp dword [eax + 4], 0
jl 0x1000395f
jg 0x10003957
cmp dword [eax], 0x320
jbe 0x1000395f
mov ecx, dword [ebp - 0x10]
mov eax, dword [ebp - 0xc]
mov dword [ecx], eax
cmp dword [ebp + 0x14], 0
jne 0x10003970
mov eax, dword [ebp + 8]
push dword [eax]
call dword [sym.imp.OLEAUT32.dll_SafeArrayGetElement]
pop edi
pop esi
mov eax, 1
pop ebx
mov esp, ebp
pop ebp
ret 0x14