Function at 0x1001aa80
Capabilities:
Check for time delay via gettickcount
Get file size
Read file on windows
Write file on windows

Disassembly:
sub esp, 0x80
mov eax, dword [0x10125a94]
xor eax, esp
mov dword [esp + 0x7c], eax
push ebx
push ebp
mov ebp, dword [esp + 0x8c]
push esi
push edi
mov edi, dword [esp + 0x98]
shl edi, 4
add edi, dword [ebp + 0x10]
mov dword [esp + 0x20], ebp
mov dword [esp + 0x24], edi
cmp dword [edi + 4], 0
je 0x1001aeed
call dword [sym.imp.KERNEL32.dll_GetTickCount]
mov edx, dword [esp + 0x9c]
lea esi, [esp + 0x2c]
mov dword [esp + 0x28], eax
sub esi, edx
mov cl, byte [edx]
lea edx, [edx + 1]
mov byte [esi + edx - 1], cl
test cl, cl
jne 0x1001aad2
mov ecx, dword [esp + 0xa0]
lea edx, [esp + 0x4c]
sub edx, ecx
nop dword [eax]
mov al, byte [ecx]
lea ecx, [ecx + 1]
mov byte [edx + ecx - 1], al
test al, al
jne 0x1001aaf0
lea ecx, [esp + 0x2c]
lea edx, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x1001ab04
sub ecx, edx
push 0x18
mov dword [esp + ecx + 0x2d], 0x726964
call fcn.100b8158
mov ebx, eax
add esp, 4
test ebx, ebx
jne 0x1001ab41
push str.content_builder
push str.failed_to_allocate_memory_for__s
push 1
push dword [ebp + 0x18]
call fcn.100198a0
add esp, 0x10
jmp 0x1001aeed
mov esi, dword [sym.imp.KERNEL32.dll_CreateFileA]
lea eax, [esp + 0x2c]
push 0
push 0x80
push 3
push 0
push 0
push closesocket
push eax
mov dword [ebx + 8], 0
call esi
push 0
push 0x80
push 2
push 0
push 0
mov dword [ebx], eax
lea eax, [esp + 0x60]
push 0x40000000
push eax
call esi
mov ecx, dword [ebx]
mov dword [ebx + 4], eax
cmp ecx, 0xffffffff
je 0x1001ae98
cmp eax, 0xffffffff
je 0x1001ae98
push 0
push ecx
mov dword [ebx + 0x14], edi
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov ecx, eax
mov dword [esp + 0x1c], ecx
test ecx, ecx
je 0x1001ae79
cmp ecx, 0xffffffff
je 0x1001ae79
test cl, 0x1f
jne 0x1001ae79
mov eax, dword [ebx + 0x14]
mov eax, dword [eax + 4]
shl eax, 5
add eax, ecx
push eax
call fcn.100b8158
mov ecx, eax
add esp, 4
mov dword [ebx + 0xc], ecx
test ecx, ecx
jne 0x1001abf1
push str.dir_files
push str.failed_to_allocate_memory_for__s
jmp 0x1001ae83
mov esi, dword [esp + 0x1c]
mov eax, esi
shr eax, 5
push 0
mov dword [ebx + 8], eax
lea eax, [esp + 0x1c]
push eax
push esi
push ecx
push dword [ebx]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x1001ae6d
cmp dword [esp + 0x18], esi
jne 0x1001ae6d
mov eax, dword [ebx + 0x14]
mov edi, dword [ebx + 0xc]
mov dword [esp + 0x14], edi
mov eax, dword [eax + 4]
add eax, dword [ebx + 8]
shl eax, 5
push eax
call fcn.100b8158
add esp, 4
mov dword [esp + 0x1c], eax
test eax, eax
jne 0x1001ac53
push str.dir_sorter
push str.failed_to_allocate_memory_for__s
jmp 0x1001ae83
xor ebp, ebp
mov dword [esp + 0x18], 0
mov dword [esp + 0x10], ebp
cmp dword [ebx + 8], ebp
jbe 0x1001ad25
nop word [eax + eax]
mov eax, dword [ebx + 0x14]
mov esi, dword [eax + 4]
mov ecx, dword [eax]
test esi, esi
je 0x1001acb5
lea ebp, [edi + 8]
imul edi, esi, 0x108
add edi, ecx
sub edi, 0x108
dec esi
push 0x18
push ebp
push dword [edi + 0x104]
call fcn.10036d20
add esp, 0xc
test eax, eax
je 0x1001aca9
test esi, esi
jne 0x1001ac87
jmp 0x1001acad
test edi, edi
jne 0x1001ad04
mov ebp, dword [esp + 0x10]
mov edi, dword [esp + 0x14]
mov esi, dword [esp + 0x1c]
mov ecx, ebp
test ebp, ebp
je 0x1001acef
mov eax, dword [edi]
cmp eax, dword [esi]
jbe 0x1001accf
add esi, 0x20
sub ecx, 1
jne 0x1001acc1
jmp 0x1001acef
mov edx, ecx
shl edx, 5
add edx, esi
movups xmm0, xmmword [edx - 0x20]
mov eax, edx
sub edx, 0x20
movups xmmword [eax], xmm0
movups xmm0, xmmword [edx + 0x10]
movups xmmword [eax + 0x10], xmm0
sub ecx, 1
jne 0x1001acd6
movups xmm0, xmmword [edi]
inc ebp
mov dword [esp + 0x10], ebp
movups xmmword [esi], xmm0
movups xmm0, xmmword [edi + 0x10]
movups xmmword [esi + 0x10], xmm0
jmp 0x1001ad0c
mov edi, dword [esp + 0x14]
mov ebp, dword [esp + 0x10]
mov edx, dword [esp + 0x18]
add edi, 0x20
inc edx
mov dword [esp + 0x14], edi
mov dword [esp + 0x18], edx
cmp edx, dword [ebx + 8]
jb 0x1001ac70
push dword [ebx + 0xc]
call fcn.100b813d
mov eax, dword [esp + 0x20]
lea ecx, [esp + 0x30]
add esp, 4
mov dword [ebx + 0xc], eax
mov dword [ebx + 8], ebp
lea edx, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x1001ad41
mov edi, dword [esp + 0x20]
lea eax, [esp + 0x2c]
push eax
sub ecx, edx
push edi
push ebx
mov dword [esp + ecx + 0x35], 0x676d69
call fcn.1001a4c0
add esp, 0xc
test eax, eax
je 0x1001ae90
push edi
push ebx
call fcn.1001a730
add esp, 8
test eax, eax
je 0x1001ae90
lea ecx, [esp + 0x4c]
lea edx, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x1001ad86
sub ecx, edx
mov dword [esp + ecx + 0x49], 0x726964
push dword [ebx + 4]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push 0
push 0x80
push 2
push 0
push 0
push 0x40000000
lea eax, [esp + 0x64]
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov dword [ebx + 4], eax
cmp eax, 0xffffffff
jne 0x1001adcf
mov eax, str.failed_to_open_file:__s
jmp 0x1001ae4e
mov esi, dword [ebx + 8]
lea ecx, [esp + 0x20]
push 0
push ecx
shl esi, 5
push esi
push dword [ebx + 0xc]
push eax
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x1001ae49
cmp dword [esp + 0x20], esi
jne 0x1001ae49
mov eax, dword [esp + 0x24]
push ebx
mov dword [eax + 0xc], 1
call fcn.1001a480
lea esi, [esp + 0x50]
add esp, 4
lea ecx, [esi + 1]
nop dword [eax]
mov al, byte [esi]
inc esi
test al, al
jne 0x1001ae10
sub esi, ecx
call dword [sym.imp.KERNEL32.dll_GetTickCount]
sub eax, dword [esp + 0x28]
push eax
lea eax, [esp + 0x50]
push eax
lea eax, [esi - 4]
push eax
push str.built__.s.img_in__lu_ms
push 0
push dword [edi + 0x18]
call fcn.100198a0
add esp, 0x18
mov eax, 1
jmp 0x1001aeef
mov eax, str.failed_to_write_file:__s
lea ecx, [esp + 0x4c]
push ecx
push eax
mov eax, dword [edi + 0x18]
push 1
push eax
call fcn.100198a0
push ebx
call fcn.1001a480
add esp, 0x14
jmp 0x1001aeed
lea eax, [esp + 0x2c]
push eax
push str.failed_to_read_file:__s
jmp 0x1001ae83
lea eax, [esp + 0x2c]
push eax
push str.invalid_file_size:__s
push 1
push dword [ebp + 0x18]
call fcn.100198a0
add esp, 0x10
push ebx
call fcn.1001a480
jmp 0x1001aeea
test ecx, ecx
lea edx, [esp + 0x2c]
lea eax, [esp + 0x4c]
cmove eax, edx
push eax
push str.failed_to_open_file:__s
push 1
push dword [ebp + 0x18]
call fcn.100198a0
mov eax, dword [ebx]
add esp, 0x10
mov esi, dword [sym.imp.KERNEL32.dll_CloseHandle]
cmp eax, 0xffffffff
je 0x1001aec8
push eax
call esi
mov eax, dword [ebx + 4]
cmp eax, 0xffffffff
je 0x1001aed3
push eax
call esi
cmp dword [ebx + 8], 0
je 0x1001aee4
push dword [ebx + 0xc]
call fcn.100b813d
add esp, 4
push ebx
call fcn.100b813d
add esp, 4
xor eax, eax
mov ecx, dword [esp + 0x8c]
pop edi
pop esi
pop ebp
pop ebx
xor ecx, esp
call fcn.100aebeb
add esp, 0x80
ret