Function at 0x100104d7
Capabilities:
Check if file exists
Encode data using xor

Disassembly:
push 0x90
mov eax, 0x1007376e
call fcn.1003d449
mov edi, ecx
mov dword [ebp - 0x64], edi
mov eax, dword [edi]
or eax, dword [edi + 4]
jne 0x10010518
xor ebx, ebx
push ebx
call fcn.10028ef9
mov dword [edi], eax
imul eax, dword [edi + 8], 0x3c
pop ecx
mov dword [edi + 4], edx
test eax, eax
jle 0x10010526
push eax
push ebx
call fcn.1000f0d7
cdq
add dword [edi], eax
pop ecx
adc dword [edi + 4], edx
jmp 0x10010525
xor ebx, ebx
push ebx
call fcn.10028ef9
mov dword [edi], eax
mov dword [edi + 4], edx
pop ecx
lea eax, [edi + 0xa8]
mov dword [ebp - 0x60], ebx
push eax
lea ecx, [ebp - 0x40]
mov esi, ebx
call fcn.10004850
xor ecx, ecx
mov dword [ebp - 4], ebx
inc ecx
cmp dword [ebp - 0x30], 0
je 0x10010708
cmp dword [edi + 0xc0], ebx
je 0x100105cf
xor eax, eax
mov dword [ebp - 0x14], 7
mov dword [ebp - 0x18], ebx
mov word [ebp - 0x28], ax
push ecx
lea eax, [ebp - 0x28]
mov byte [ebp - 4], cl
push eax
sub esp, 0x18
lea ecx, [ebp - 0x40]
mov eax, esp
push ecx
push eax
call fcn.1000df32
pop ecx
pop ecx
mov ecx, dword [edi + 0xc0]
push ebx
call fcn.1000f20f
cmp dword [ebp - 0x14], 8
lea eax, [ebp - 0x28]
cmovae eax, dword [ebp - 0x28]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x100105b9
lea eax, [ebp - 0x60]
push eax
sub esp, 0x18
lea eax, [ebp - 0x28]
mov ecx, esp
push eax
call fcn.10003150
call fcn.10012017
add esp, 0x1c
mov esi, eax
push ebx
push 1
lea ecx, [ebp - 0x28]
mov byte [ebp - 4], bl
call fcn.100015e0
test esi, esi
jne 0x100106ba
push 0x1869f
push 0x2710
call fcn.1000f0d7
push str._rand
mov esi, eax
call fcn.10020f60
add esp, 0xc
lea ecx, [ebp - 0x40]
push eax
push str._rand
call fcn.10005710
mov eax, esi
cdq
push edx
push eax
lea eax, [ebp - 0x58]
push eax
call fcn.1000e3dd
add esp, 0xc
push 0xffffffffffffffff
push ebx
push eax
lea ecx, [ebp - 0x40]
mov byte [ebp - 4], 2
call fcn.10005650
xor esi, esi
mov byte [ebp - 4], bl
push ebx
inc esi
lea ecx, [ebp - 0x58]
push esi
call fcn.10005480
lea ecx, [ebp - 0x9c]
call fcn.1000bbbe
cmp dword [ebp - 0x2c], 0x10
lea eax, [ebp - 0x40]
lea ecx, [ebp - 0x9c]
mov byte [ebp - 4], 3
cmovae eax, dword [ebp - 0x40]
push eax
call fcn.1000bd93
lea ecx, [ebp - 0x9c]
call fcn.1000c03c
mov ecx, eax
mov dword [ebp - 0x5c], ecx
mov eax, dword [ecx + 4]
sub eax, dword [ecx]
cmove eax, esi
mov dword [ebp - 0x60], eax
inc eax
push eax
call fcn.1000a39b
mov ecx, dword [ebp - 0x60]
mov esi, eax
inc ecx
push ecx
push ebx
push esi
call fcn.100191c0
mov eax, dword [ebp - 0x5c]
add esp, 0x10
mov edx, ebx
mov ecx, dword [eax + 4]
sub ecx, dword [eax]
je 0x100106a8
mov edi, eax
mov eax, dword [edi]
mov al, byte [edx + eax]
mov byte [edx + esi], al
inc edx
mov eax, dword [edi + 4]
sub eax, dword [edi]
cmp edx, eax
jb 0x10010693
mov edi, dword [ebp - 0x64]
lea ecx, [ebp - 0x9c]
mov byte [ebp - 4], bl
call fcn.1000bbff
test esi, esi
je 0x100106ef
push str.c335b80a32136330ebfa2439bf4cbfcb
call fcn.10020f60
cmp dword [ebp - 0x60], 0
mov edx, ebx
pop ecx
mov dword [ebp - 0x5c], eax
jbe 0x100106ef
mov edi, dword [ebp - 0x5c]
mov eax, ebx
mov cl, byte [eax + str.c335b80a32136330ebfa2439bf4cbfcb]
xor byte [edx + esi], cl
inc eax
xor ecx, ecx
cmp eax, edi
cmovge eax, ecx
inc edx
cmp edx, dword [ebp - 0x60]
jb 0x100106d5
mov edi, dword [ebp - 0x64]
push esi
mov ecx, edi
call fcn.100101ed
mov byte [edi + 0xc], al
test esi, esi
je 0x10010705
push esi
call fcn.1000a3a4
pop ecx
xor ecx, ecx
inc ecx
push ebx
push ecx
lea ecx, [ebp - 0x40]
call fcn.10005480
call fcn.1003d404
ret