Function at 0x1012d159
Capabilities:
Check for time delay via queryperformancecounter
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x7c
mov eax, dword [0x10285008]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
push edi
xor ebx, ebx
lea eax, [ebp - 0x18]
push eax
mov dword [ebp - 0x2c], ebx
mov dword [ebp - 0x24], ebx
mov dword [ebp - 0x5c], ebx
call dword [sym.imp.KERNEL32.dll_QueryPerformanceCounter]
mov eax, dword [0x102c7ff4]
test eax, eax
je 0x1012d1c1
cmp dword [eax + 8], 1
jne 0x1012d1c1
cmp dword [eax + 0xc], ebx
je 0x1012d1a3
cmp dword [eax + 8], 1
jne 0x1012d1c1
cmp dword [eax + 0xc], 3
jne 0x1012d1c1
mov ebx, dword [eax + 0xe40]
mov dword [ebp - 0x28], ebx
mov eax, dword [ebx]
mov esi, dword [eax + 0x24]
mov ecx, esi
call dword [0x102dc578]
mov ecx, ebx
call esi
xor ebx, ebx
jmp 0x1012d1c4
mov dword [ebp - 0x28], ebx
mov edi, dword [ebp + 0xc]
cmp dword [edi + 0x44], 0
je 0x1012d243
push ebx
push 0x80
push 3
push ebx
push 1
push 0x80000000
push dword [edi + 0x44]
call dword [0x102a9c60]
mov ebx, eax
mov dword [ebp - 0x2c], ebx
test ebx, ebx
je 0x1012d1f4
cmp ebx, 0xffffffff
jne 0x1012d243
call dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
jne 0x1012d205
mov esi, 0x80004005
jmp 0x1012d21a
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
test esi, esi
jle 0x1012d21a
movzx esi, si
or esi, 0x80070000
push ecx
push ecx
xor edx, edx
mov ecx, esi
call fcn.102107ba
push eax
mov ecx, esi
call fcn.10210755
push eax
push dword [edi + 0x44]
push 0x1007ac40
call fcn.100d3aab
add esp, 0x10
jmp 0x1012d73d
mov esi, dword [0x102c7ff0]
mov eax, dword [esi + 0x14]
shl eax, 5
push eax
call dword [sym.imp.msvcrt.dll_malloc]
mov dword [ebp - 0x24], eax
pop ecx
test eax, eax
jne 0x1012d273
push 0x1007acb0
call fcn.100d3aab
pop ecx
mov esi, 0x8007000e
jmp 0x1012d72f
mov eax, dword [ebp + 0x10]
xor edi, edi
mov edx, edi
mov dword [ebp - 0x40], edi
mov ebx, edi
mov dword [ebp - 0x48], ebx
mov ecx, dword [eax]
mov dword [ebp - 0x50], ecx
cmp dword [ebp + 0x14], edx
je 0x1012d2a0
mov ebx, dword [eax + 8]
mov dword [ebp - 0x58], ebx
mov ebx, dword [eax + 0xc]
mov dword [ebp - 0x54], ebx
lea ebx, [eax + 0x10]
mov dword [ebp - 0x48], ebx
jmp 0x1012d2af
mov edx, dword [eax + 4]
mov dword [ebp - 0x58], edx
lea edx, [eax + 8]
mov dword [ebp - 0x54], edi
mov dword [ebp - 0x40], edx
mov dword [ebp - 0x44], edi
mov dword [ebp - 0x3c], edi
mov dword [ebp - 0x1c], edi
mov dword [ebp - 0x4c], edi
test ecx, ecx
je 0x1012d72d
cmp dword [ebp + 0x14], 0
je 0x1012d2fb
push dword [ebx + 0xc]
mov ecx, esi
push dword [ebx + 8]
call fcn.100f3e62
push dword [ebx + 4]
mov ecx, esi
mov dword [ebp - 0x34], eax
push dword [ebx]
mov dword [ebp - 0x38], edx
call fcn.100f3e62
push 0
push dword [esi + 0x14]
push edx
push eax
call fcn.10238650
mov ebx, eax
mov dword [ebp - 0xc], ebx
jmp 0x1012d331
mov bl, byte [esi + 0x29]
mov eax, dword [edx + edi*8 + 4]
mov dword [ebp - 0x34], eax
test bl, bl
je 0x1012d313
mov ecx, eax
call fcn.100f3dad
mov dword [ebp - 0x34], eax
mov eax, dword [ebp - 0x40]
xor edx, edx
mov dword [ebp - 0x38], edx
mov eax, dword [eax + edi*8]
test bl, bl
je 0x1012d329
mov ecx, eax
call fcn.100f3dad
mul dword [esi + 0x14]
mov ebx, eax
mov dword [ebp - 0xc], eax
mov ecx, dword [ebp - 0x34]
push 0x20
pop edi
mov dword [ebp - 8], edx
mov edx, dword [ebp - 0x38]
mov dword [ebp - 0x20], edi
jmp 0x1012d6ea
test edx, edx
ja 0x1012d354
jb 0x1012d34f
cmp ecx, edi
jae 0x1012d354
mov edi, ecx
mov dword [ebp - 0x20], edi
call fcn.101f2c80
test eax, eax
jne 0x1012d71b
push eax
push 0x64
push dword [ebp - 0x3c]
push dword [ebp - 0x44]
call fcn.10238650
push dword [ebp - 0x54]
push dword [ebp - 0x58]
push edx
push eax
call fcn.1026acf0
cmp eax, dword [ebp - 0x1c]
jne 0x1012d4de
test edx, edx
jne 0x1012d4de
lea eax, [ebp - 0x78]
push eax
call dword [sym.imp.KERNEL32.dll_QueryPerformanceFrequency]
lea eax, [ebp - 0x68]
push eax
call dword [sym.imp.KERNEL32.dll_QueryPerformanceCounter]
mov esi, dword [ebp - 0x1c]
mov ecx, dword [ebp - 0x68]
mov eax, dword [ebp - 0x64]
push 0x64
pop edx
sub edx, esi
sub ecx, dword [ebp - 0x18]
sbb eax, dword [ebp - 0x14]
push eax
push ecx
push 0
push edx
call fcn.10238650
push dword [ebp - 0x74]
push dword [ebp - 0x78]
push edx
push eax
call fcn.1026ac40
push esi
push 0x1007ad0c
mov dword [ebp - 0x18], eax
mov dword [ebp - 0x14], edx
call fcn.100d3a67
pop ecx
pop ecx
sub esi, dword [ebp - 0x5c]
je 0x1012d49a
push 0
push esi
push dword [ebp - 0x14]
push dword [ebp - 0x18]
call fcn.1026ac40
xor esi, esi
mov dword [ebp - 0x18], eax
mov dword [ebp - 0x14], edx
cmp edx, esi
jl 0x1012d493
jg 0x1012d40f
cmp eax, 0xe10
jb 0x1012d442
push esi
push 0xe10
push edx
push eax
call fcn.1026ac40
push edx
push eax
push 0x1007ad28
call fcn.100d3a67
add esp, 0xc
push esi
push 0xe10
push dword [ebp - 0x14]
push dword [ebp - 0x18]
call fcn.1026ae00
mov dword [ebp - 0x18], eax
mov dword [ebp - 0x14], edx
cmp edx, esi
jl 0x1012d493
jg 0x1012d44d
cmp eax, 0x3c
jb 0x1012d47a
push esi
push 0x3c
push edx
push eax
call fcn.1026ac40
push edx
push eax
push 0x1007ad3c
call fcn.100d3a67
add esp, 0xc
push esi
push 0x3c
push dword [ebp - 0x14]
push dword [ebp - 0x18]
call fcn.1026ae00
mov dword [ebp - 0x18], eax
mov dword [ebp - 0x14], edx
cmp edx, esi
jl 0x1012d493
jg 0x1012d484
cmp eax, esi
jbe 0x1012d493
push edx
push eax
push 0x1007ad54
call fcn.100d3a67
add esp, 0xc
push 0x1007ad6c
jmp 0x1012d49f
push 0x100597b0
call fcn.100d3a67
mov eax, dword [ebp - 0x68]
mov dword [ebp - 0x18], eax
mov eax, dword [ebp - 0x64]
mov dword [ebp - 0x14], eax
mov eax, dword [ebp - 0x1c]
pop ecx
mov dword [ebp - 0x5c], eax
call fcn.100d2d40
mov esi, dword [ebp - 0x2c]
test esi, esi
jne 0x1012d4d8
mov eax, dword [ebp - 0x28]
test eax, eax
je 0x1012d4d0
cmp byte [eax + 0x24], 0
jne 0x1012d4d8
inc dword [ebp - 0x1c]
jmp 0x1012d57d
add dword [ebp - 0x1c], 5
jmp 0x1012d4e1
mov esi, dword [ebp - 0x2c]
test esi, esi
je 0x1012d57a
mov eax, dword [ebp - 8]
mov ebx, 0x1007ad88
push 0
mov dword [ebp - 0x6c], eax
lea eax, [ebp - 0x6c]
push eax
push dword [ebp - 0xc]
push esi
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
cmp eax, 0xffffffff
jne 0x1012d513
call dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
jne 0x1012d533
push 0
lea eax, [ebp - 0x30]
push eax
mov eax, dword [0x102c7ff0]
mov eax, dword [eax + 0x14]
imul eax, edi
push eax
push dword [ebp - 0x24]
push esi
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x1012d55f
call dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
je 0x1012d711
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
test esi, esi
jle 0x1012d698
movzx esi, si
or esi, 0x80070000
jmp 0x1012d696
mov eax, dword [0x102c7ff0]
mov eax, dword [eax + 0x14]
imul eax, edi
cmp dword [ebp - 0x30], eax
jb 0x1012d61f
xor esi, esi
jmp 0x1012d696
mov eax, dword [ebp - 0x28]
test eax, eax
je 0x1012d645
cmp byte [eax + 0x24], 0
je 0x1012d645
mov edx, dword [eax + 0x2c]
mov ecx, dword [eax + 0x28]
cmp dword [ebp - 8], edx
ja 0x1012d645
jb 0x1012d5a8
cmp ebx, ecx
jae 0x1012d645
mov eax, dword [0x102c7ff0]
mov ebx, 0x1007adb4
mov edi, dword [eax + 0x14]
mov esi, edi
imul esi, dword [ebp - 0x20]
xor eax, eax
add esi, dword [ebp - 0xc]
adc eax, dword [ebp - 8]
cmp eax, edx
jb 0x1012d5e0
ja 0x1012d5cd
cmp esi, ecx
jbe 0x1012d5e0
sub ecx, dword [ebp - 0xc]
push 0
sbb edx, dword [ebp - 8]
push edi
push edx
push ecx
call fcn.1026acf0
mov dword [ebp - 0x20], eax
imul edi, dword [ebp - 0x20]
lea eax, [ebp - 0x30]
mov esi, dword [ebp - 0x28]
push eax
mov esi, dword [esi]
push edi
push dword [ebp - 0x24]
push dword [ebp - 8]
mov ecx, dword [esi + 0x20]
push dword [ebp - 0xc]
call dword [0x102dc578]
mov ecx, dword [ebp - 0x28]
call dword [esi + 0x20]
mov esi, eax
test esi, esi
jne 0x1012d624
mov eax, dword [0x102c7ff0]
mov edi, dword [ebp - 0x20]
mov eax, dword [eax + 0x14]
imul eax, edi
cmp dword [ebp - 0x30], eax
jae 0x1012d69d
mov esi, 0x8007001e
mov ecx, esi
call fcn.10210755
push eax
push dword [ebp - 8]
push dword [ebp - 0xc]
push ebx
push 0x1007ae18
call fcn.100d3aab
add esp, 0x14
jmp 0x1012d72f
mov edi, dword [0x102c7ff4]
lea eax, [ebp - 0x30]
push eax
mov eax, dword [0x102c7ff0]
mov ebx, 0x1007ade8
push 0
mov esi, dword [edi]
mov dword [ebp - 0x20], 1
push dword [eax + 0x14]
push dword [ebp - 0x24]
mov ecx, dword [esi + 0x6c]
push dword [ebp - 8]
push dword [ebp - 0xc]
call dword [0x102dc578]
mov ecx, edi
call dword [esi + 0x6c]
mov esi, eax
test esi, esi
jne 0x1012d624
mov eax, dword [0x102c7ff0]
mov ecx, dword [ebp - 0x30]
cmp ecx, dword [eax + 0x14]
jae 0x1012d69a
mov esi, 0x8007001e
test esi, esi
jne 0x1012d624
mov edi, dword [ebp - 0x20]
mov eax, dword [0x102c7ff0]
mov eax, dword [eax + 0x14]
imul eax, edi
push eax
push dword [ebp - 0x24]
push dword [ebp + 8]
call fcn.1012a19e
mov esi, eax
test esi, esi
jne 0x1012d72f
mov esi, dword [0x102c7ff0]
mov ebx, dword [ebp - 0xc]
mov ecx, dword [ebp - 0x34]
mov edx, dword [ebp - 0x38]
mov eax, dword [esi + 0x14]
imul eax, edi
push 0
add ebx, eax
pop eax
adc dword [ebp - 8], eax
add dword [ebp - 0x44], edi
mov dword [ebp - 0xc], ebx
adc dword [ebp - 0x3c], eax
sub ecx, edi
mov dword [ebp - 0x34], ecx
sbb edx, eax
mov dword [ebp - 0x38], edx
mov eax, ecx
or eax, edx
jne 0x1012d345
mov edi, dword [ebp - 0x4c]
mov ebx, dword [ebp - 0x48]
inc edi
add ebx, 0x10
mov dword [ebp - 0x4c], edi
mov dword [ebp - 0x48], ebx
cmp edi, dword [ebp - 0x50]
jae 0x1012d72d
mov edx, dword [ebp - 0x40]
jmp 0x1012d2c3
mov esi, 0x80004005
jmp 0x1012d624
push 0x1007acf0
call fcn.100d3aab
pop ecx
mov esi, 0xd000013a
jmp 0x1012d72f
xor esi, esi
mov eax, dword [ebp - 0x2c]
test eax, eax
je 0x1012d73d
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push dword [ebp - 0x24]
call dword [sym.imp.msvcrt.dll_free]
pop ecx
mov ecx, dword [ebp - 4]
mov eax, esi
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.10236010
mov esp, ebp
pop ebp
ret 0x10