Function at 0x501300
Capabilities:
Encode data using xor

Disassembly:
mov eax, 0xd8
call fcn.00488be0
mov eax, dword [0x605580]
xor eax, esp
mov dword [esp + 0xd4], eax
mov eax, dword [esp + 0xdc]
mov dword [esp + 0x44], eax
mov eax, dword [esp + 0xec]
push ebx
mov ebx, dword [esp + 0xe4]
mov dword [esp + 0x1c], eax
mov eax, dword [esp + 0xf8]
push ebp
mov ebp, dword [esp + 0xf0]
mov dword [esp + 0x58], eax
mov eax, dword [esp + 0x100]
push esi
mov esi, dword [esp + 0xf0]
mov dword [esp + 0x54], eax
mov eax, dword [esp + 0x108]
shr esi, 3
mov dword [esp + 0x58], eax
mov eax, dword [esp + 0x10c]
mov dword [esp + 0x14], ebp
mov dword [esp + 0x18], eax
mov dword [esp + 0x44], 0
mov dword [esp + 0x34], 0
mov dword [esp + 0x1c], 0
mov dword [esp + 0x40], 2
cmp esi, 0x14
je 0x5013c2
cmp esi, 0x1c
je 0x5013c2
cmp esi, 0x20
je 0x5013c2
pop esi
pop ebp
xor eax, eax
pop ebx
mov ecx, dword [esp + 0xd4]
xor ecx, esp
call fcn.004883ab
add esp, 0xd8
ret
test ebp, ebp
jne 0x5013f1
cmp esi, 0x14
jne 0x5013d6
call fcn.004e2f10
mov dword [esp + 0x14], eax
jmp 0x5013fc
cmp esi, 0x1c
jne 0x5013e6
call fcn.004e2f20
mov dword [esp + 0x14], eax
jmp 0x5013fc
call fcn.004e2f30
mov dword [esp + 0x14], eax
jmp 0x5013fc
push ebp
call fcn.004beb70
add esp, 4
mov esi, eax
mov ecx, dword [esp + 0x24]
push edi
mov edi, 0x200
cmp ebx, edi
cmovae edi, ebx
add edi, 0x3f
and edi, 0xffffffc0
test ecx, ecx
je 0x501451
mov eax, dword [esp + 0x100]
cmp eax, esi
jae 0x50143c
push 0x55
push 0x5c9674
push 0x6e
push 0x7d
push 0xa
call fcn.004bdd70
add esp, 0x14
xor eax, eax
jmp 0x501af4
cmova eax, esi
push eax
push ecx
lea eax, [esp + 0xcc]
push eax
call fcn.00492730
add esp, 0xc
call fcn.004e9ca0
mov dword [esp + 0x34], eax
test eax, eax
je 0x501ad4
call fcn.004cef30
mov ebx, eax
mov dword [esp + 0x20], ebx
test ebx, ebx
je 0x501ad4
push ebx
call fcn.004cf020
push ebx
call fcn.004cede0
push ebx
mov ebp, eax
call fcn.004cede0
push ebx
mov dword [esp + 0x40], eax
call fcn.004cede0
push ebx
mov dword [esp + 0x50], eax
call fcn.004cede0
push ebx
mov dword [esp + 0x3c], eax
call fcn.004cede0
push ebx
mov dword [esp + 0x48], eax
call fcn.004cede0
push ebx
mov dword [esp + 0x70], eax
call fcn.004cede0
push ebx
mov dword [esp + 0x38], eax
call fcn.004cede0
mov ebx, eax
add esp, 0x24
mov dword [esp + 0x10], ebx
test ebx, ebx
je 0x501ad4
lea eax, [edi - 1]
push eax
mov dword [esp + 0x50], eax
call fcn.004c7580
push eax
push ebx
call fcn.004df960
add esp, 0xc
test eax, eax
je 0x501ad4
mov edi, dword [esp + 0x3c]
nop dword [eax]
push dword [esp + 0x38]
xor ebx, ebx
cmp dword [esp + 0x2c], ebx
push 0
push dword [esp + 0x24]
sete bl
call fcn.004ea690
inc dword [esp + 0x44]
add esp, 0xc
test eax, eax
je 0x501ad4
cmp dword [esp + 0x28], 0
jne 0x501549
lea eax, [esp + 0xc4]
push esi
push eax
call fcn.004cdfc0
add esp, 8
test eax, eax
jle 0x501ad4
jmp 0x501551
mov dword [esp + 0x28], 0
push esi
lea eax, [esp + 0xc8]
push eax
lea eax, [esp + 0xac]
push eax
call fcn.00492730
push esi
lea eax, [esp + 0xd4]
push eax
lea eax, [esp + 0x98]
push eax
call fcn.00492730
lea eax, [esi - 1]
add esp, 0x18
test eax, eax
js 0x50159f
nop word [eax + eax]
add byte [esp + eax + 0xa4], 1
jne 0x50159f
sub eax, 1
jns 0x501590
push 0
push dword [esp + 0x1c]
lea eax, [esp + 0x6c]
push 0
push eax
lea eax, [esp + 0xd4]
push esi
push eax
call fcn.004cc2c0
add esp, 0x18
test eax, eax
je 0x501ad4
push 0
push dword [esp + 0x1c]
lea eax, [esp + 0x8c]
push 0
push eax
lea eax, [esp + 0xb4]
push esi
push eax
call fcn.004cc2c0
add esp, 0x18
test eax, eax
je 0x501ad4
xor ecx, ecx
test esi, esi
jle 0x5016d4
cmp esi, 8
jb 0x5016c4
cmp esi, 0x40
jb 0x50168f
mov eax, esi
and eax, 0x8000003f
jns 0x501618
dec eax
or eax, 0xffffffc0
inc eax
mov edx, esi
sub edx, eax
nop dword [eax]
movups xmm0, xmmword [esp + ecx + 0x64]
movups xmm1, xmmword [esp + ecx + 0x84]
xorps xmm1, xmm0
movups xmmword [esp + ecx + 0x64], xmm1
movups xmm0, xmmword [esp + ecx + 0x74]
movups xmm1, xmmword [esp + ecx + 0x94]
xorps xmm1, xmm0
movups xmmword [esp + ecx + 0x74], xmm1
movups xmm0, xmmword [esp + ecx + 0x84]
movups xmm1, xmmword [esp + ecx + 0xa4]
xorps xmm1, xmm0
movups xmmword [esp + ecx + 0x84], xmm1
movups xmm0, xmmword [esp + ecx + 0x94]
movups xmm1, xmmword [esp + ecx + 0xb4]
xorps xmm1, xmm0
movups xmmword [esp + ecx + 0x94], xmm1
add ecx, 0x40
cmp ecx, edx
jl 0x501620
mov eax, esi
and al, 0x3f
cmp al, 8
jb 0x5016c0
mov eax, esi
and eax, 0x80000007
jns 0x50169d
dec eax
or eax, 0xfffffff8
inc eax
mov edx, esi
sub edx, eax
movq xmm0, qword [esp + ecx + 0x64]
movq xmm1, qword [esp + ecx + 0x84]
xorps xmm1, xmm0
movq qword [esp + ecx + 0x64], xmm1
add ecx, 8
cmp ecx, edx
jl 0x5016a1
cmp ecx, esi
jge 0x5016d4
mov al, byte [esp + ecx + 0x84]
xor byte [esp + ecx + 0x64], al
inc ecx
cmp ecx, esi
jl 0x5016c4
push dword [esp + 0x24]
or byte [esp + 0x68], 0x80
lea eax, [esp + 0x68]
or byte [esp + esi + 0x67], 1
push esi
push eax
call fcn.004c6b40
add esp, 0xc
test eax, eax
je 0x501ad4
push dword [esp + 0x1c]
push ebx
push dword [esp + 0x28]
push 0x40
push dword [esp + 0x34]
call fcn.004eac60
add esp, 0x14
test eax, eax
jg 0x50171e
je 0x501500
jmp 0x501ad4
mov ebx, dword [esp + 0x1c]
push 0
push 2
push ebx
call fcn.004ea690
add esp, 0xc
test eax, eax
je 0x501ad4
push 0
push 3
push ebx
call fcn.004ea690
add esp, 0xc
test eax, eax
je 0x501ad4
mov eax, 0xcccccccd
xor ecx, ecx
mul dword [esp + 0x4c]
mov dword [esp + 0x40], ecx
mov ebx, edx
shr ebx, 7
test ecx, ecx
je 0x50177b
push ecx
push 0
push dword [esp + 0x24]
call fcn.004ea690
add esp, 0xc
test eax, eax
je 0x501ad4
push 0
push edi
call fcn.004c74d0
add esp, 8
xor edi, edi
test ebx, ebx
js 0x501829
lea eax, [esi - 1]
test eax, eax
js 0x5017af
nop word [eax + eax]
add byte [esp + eax + 0xa4], 1
jne 0x5017af
sub eax, 1
jns 0x5017a0
push 0
push dword [esp + 0x1c]
lea eax, [esp + 0x6c]
push 0
push eax
lea eax, [esp + 0xb4]
push esi
push eax
call fcn.004cc2c0
add esp, 0x18
test eax, eax
je 0x501ad4
push ebp
lea eax, [esp + 0x68]
push esi
push eax
call fcn.004c6b40
add esp, 0xc
test eax, eax
je 0x501ad4
lea eax, [esi*8]
imul eax, edi
push eax
push ebp
push ebp
call fcn.004df960
add esp, 0xc
test eax, eax
je 0x501ad4
mov eax, dword [esp + 0x3c]
push ebp
push eax
push eax
call fcn.004cf110
add esp, 0xc
test eax, eax
je 0x501ad4
inc edi
cmp edi, ebx
jle 0x501790
push dword [esp + 0x4c]
mov edi, dword [esp + 0x40]
push edi
call fcn.004c7190
add esp, 8
test eax, eax
je 0x501ad4
push edi
push dword [esp + 0x30]
call fcn.004c6f30
add esp, 8
test eax, eax
je 0x501ad4
push dword [esp + 0x10]
mov eax, dword [esp + 0x30]
push eax
push eax
call fcn.004cf110
add esp, 0xc
test eax, eax
je 0x501ad4
push dword [esp + 0x24]
push ebp
call fcn.004dfad0
add esp, 8
test eax, eax
je 0x501ad4
push dword [esp + 0x20]
push ebp
push dword [esp + 0x34]
push dword [esp + 0x5c]
push 0
call fcn.004eb260
add esp, 0x14
test eax, eax
je 0x501ad4
call fcn.004c7580
push eax
push dword [esp + 0x54]
push ebp
call fcn.004cf1a0
add esp, 0xc
test eax, eax
je 0x501ad4
push ebp
push dword [esp + 0x30]
push dword [esp + 0x1c]
call fcn.004cf1a0
add esp, 0xc
test eax, eax
je 0x501ad4
push dword [esp + 0x10]
push dword [esp + 0x18]
call fcn.004c6d60
add esp, 8
test eax, eax
js 0x50190f
push dword [esp + 0x1c]
push 1
push dword [esp + 0x28]
push 0x40
push dword [esp + 0x24]
call fcn.004eac60
add esp, 0x14
test eax, eax
jg 0x501929
jne 0x501ad4
mov ecx, dword [esp + 0x40]
inc ecx
mov dword [esp + 0x40], ecx
cmp ecx, 0x1000
jl 0x501760
jmp 0x501500
mov ebx, dword [esp + 0x1c]
push 1
push 2
push ebx
call fcn.004ea690
add esp, 0xc
test eax, eax
je 0x501ad4
call fcn.004c7580
push eax
push dword [esp + 0x18]
push dword [esp + 0x18]
call fcn.004cf1a0
add esp, 0xc
test eax, eax
je 0x501ad4
mov edi, dword [esp + 0x20]
push edi
push dword [esp + 0x28]
push dword [esp + 0x18]
push 0
push ebp
call fcn.004eb260
add esp, 0x14
test eax, eax
je 0x501ad4
push 2
push dword [esp + 0x14]
call fcn.004c74d0
add esp, 8
test eax, eax
je 0x501ad4
push edi
push dword [esp + 0x18]
push dword [esp + 0x3c]
call fcn.004e9d20
add esp, 0xc
test eax, eax
je 0x501ad4
push dword [esp + 0x34]
push edi
push dword [esp + 0x1c]
push ebp
push dword [esp + 0x20]
push dword [esp + 0x44]
call fcn.004f5e20
add esp, 0x18
test eax, eax
je 0x501ad4
push dword [esp + 0x30]
call fcn.004c7130
add esp, 4
test eax, eax
je 0x501a24
call fcn.004c7580
push eax
mov eax, dword [esp + 0x14]
push eax
push eax
call fcn.004cf110
add esp, 0xc
test eax, eax
je 0x501ad4
push dword [esp + 0x34]
inc dword [esp + 0x48]
push edi
push dword [esp + 0x1c]
push ebp
push dword [esp + 0x20]
push dword [esp + 0x44]
call fcn.004f5e20
add esp, 0x18
test eax, eax
jne 0x5019d1
jmp 0x501ad4
push 1
push 3
push ebx
call fcn.004ea690
add esp, 0xc
test eax, eax
je 0x501ad4
mov dword [esp + 0x48], 1
mov ebx, dword [esp + 0x54]
push dword [ebx + 8]
call fcn.004c7040
push dword [ebx + 0xc]
call fcn.004c7040
push dword [ebx + 0x10]
call fcn.004c7040
push dword [esp + 0x20]
call fcn.004c6f90
push dword [esp + 0x34]
mov dword [ebx + 8], eax
call fcn.004c6f90
push dword [esp + 0x44]
mov dword [ebx + 0xc], eax
call fcn.004c6f90
add esp, 0x18
mov dword [ebx + 0x10], eax
cmp dword [ebx + 8], 0
je 0x501acc
cmp dword [ebx + 0xc], 0
je 0x501acc
test eax, eax
je 0x501acc
mov ecx, dword [esp + 0x58]
test ecx, ecx
je 0x501aa2
mov eax, dword [esp + 0x40]
mov dword [ecx], eax
mov ecx, dword [esp + 0x5c]
test ecx, ecx
je 0x501ab0
mov eax, dword [esp + 0x44]
mov dword [ecx], eax
mov eax, dword [esp + 0x60]
test eax, eax
je 0x501ad4
push esi
lea ecx, [esp + 0xc8]
push ecx
push eax
call fcn.00492730
add esp, 0xc
jmp 0x501ad4
mov dword [esp + 0x48], 0
mov esi, dword [esp + 0x20]
push esi
call fcn.004cece0
push esi
call fcn.004ced50
push dword [esp + 0x3c]
call fcn.004e9c50
mov eax, dword [esp + 0x54]
add esp, 0xc
mov ecx, dword [esp + 0xe4]
pop edi
pop esi
pop ebp
pop ebx
xor ecx, esp
call fcn.004883ab
add esp, 0xd8
ret