Function at 0x100465a6
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x28
push ebx
push esi
push edi
mov edi, dword [ebp + 8]
mov eax, dword [edi + 0x38]
mov ecx, dword [eax + 0x2c314]
mov esi, dword [eax + 0x2c310]
mov ebx, dword [eax + 0x2c30c]
mov dword [ebp + 8], ecx
mov ecx, dword [edi + 0x18]
mov dword [ebp - 4], ecx
add ecx, eax
movzx edx, byte [ecx + 1]
movzx ecx, byte [ecx]
shl ecx, 5
xor edx, ecx
mov dword [ebp - 0xc], eax
mov dword [ebp - 8], esi
mov dword [ebp - 0x14], edx
jmp 0x10046c79
mov edx, dword [edi + 0x1c]
sub edx, ecx
cmp edx, 3
jle 0x1004667a
movzx ecx, byte [eax + ecx + 2]
mov edx, dword [ebp - 0x14]
shl edx, 5
xor ecx, edx
mov dword [ebp - 0x14], ecx
and ecx, 0x1fff
lea ecx, [eax + ecx*2 + 0x2030a]
movzx edx, word [ecx]
mov dword [ebp - 0x18], edx
mov edx, dword [ebp - 4]
mov word [ecx], dx
mov ecx, edx
mov edx, dword [ebp - 0x18]
and ecx, 0x7fff
add eax, 0x10106
test edx, edx
mov word [eax + ecx*2], dx
je 0x1004666b
push dword [ebp + 0x18]
mov esi, dword [ebp - 0xc]
push dword [ebp + 0xc]
lea ecx, [ebp - 0x1c]
push ecx
mov ecx, dword [ebp - 4]
push eax
call fcn.100463e1
mov edx, dword [ebp - 4]
mov ecx, dword [edi + 0x1c]
lea esi, [eax + edx]
cmp esi, ecx
mov esi, dword [ebp - 8]
mov dword [ebp - 0x10], eax
jle 0x10046672
sub ecx, edx
mov dword [ebp - 0x10], ecx
jmp 0x1004666f
and dword [ebp - 0x10], 0
mov eax, dword [ebp - 0x10]
cmp eax, 3
jge 0x100466e7
mov eax, dword [ebp - 0xc]
inc dword [edi + 0x14]
mov ecx, dword [ebp - 4]
movzx ecx, byte [ecx + eax]
mov edx, dword [edi + 0x38]
lea ecx, [edx + ecx*2 + 0x2f2d8]
inc word [ecx]
mov ecx, dword [ebp - 4]
movzx ecx, byte [ecx + eax]
mov edx, dword [edi + 0x38]
movzx edx, word [edx + ecx*2 + 0x2f098]
mov ecx, esi
shl edx, cl
mov ecx, dword [ebp - 4]
movzx ecx, byte [ecx + eax]
or ebx, edx
mov edx, dword [edi + 0x38]
movzx ecx, byte [edx + ecx + 0x2ef78]
add esi, ecx
cmp esi, 0x10
mov dword [ebp - 8], esi
jl 0x100466df
mov ecx, dword [ebp + 8]
mov byte [ecx], bl
mov edx, ebx
inc ecx
shr edx, 8
mov byte [ecx], dl
inc ecx
shr ebx, 0x10
sub esi, 0x10
mov dword [ebp + 8], ecx
mov dword [ebp - 8], esi
inc dword [ebp - 4]
jmp 0x10046c29
inc dword [ebp - 4]
cmp eax, dword [ebp + 0x10]
jg 0x10046a7d
mov ecx, dword [ebp - 0xc]
mov eax, dword [ebp - 4]
movzx eax, byte [ecx + eax + 2]
mov edx, dword [ebp - 0x14]
shl edx, 5
xor eax, edx
mov dword [ebp - 0x14], eax
and eax, 0x1fff
lea eax, [ecx + eax*2 + 0x2030a]
movzx edx, word [eax]
mov dword [ebp - 0x18], edx
mov edx, dword [ebp - 4]
mov word [eax], dx
mov eax, edx
mov edx, dword [ebp - 0x18]
and eax, 0x7fff
add ecx, 0x10106
test edx, edx
mov word [ecx + eax*2], dx
je 0x10046776
mov eax, dword [ebp - 0x10]
cmp eax, dword [ebp + 0x14]
mov eax, dword [ebp + 0xc]
jl 0x10046747
sar eax, 2
push dword [ebp + 0x18]
mov esi, dword [ebp - 0xc]
push eax
lea eax, [ebp - 0x20]
push eax
push ecx
mov ecx, dword [ebp - 4]
call fcn.100463e1
mov ecx, dword [ebp - 4]
mov esi, dword [ebp - 8]
mov edx, eax
mov eax, dword [edi + 0x1c]
mov dword [ebp - 0x18], edx
add edx, ecx
cmp edx, eax
jle 0x1004677a
sub eax, ecx
mov dword [ebp - 0x18], eax
jmp 0x1004677a
and dword [ebp - 0x18], 0
mov eax, dword [ebp - 0x18]
cmp eax, dword [ebp - 0x10]
jle 0x10046930
inc dword [edi + 0x14]
mov eax, dword [ebp - 4]
mov ecx, dword [ebp - 0xc]
mov edx, dword [edi + 0x38]
lea ecx, [eax + ecx - 1]
movzx eax, byte [ecx]
lea eax, [edx + eax*2 + 0x2f2d8]
inc word [eax]
movzx eax, byte [ecx]
mov ecx, dword [edi + 0x38]
movzx edx, word [ecx + eax*2 + 0x2f098]
mov ecx, esi
shl edx, cl
mov ecx, dword [edi + 0x38]
movzx eax, byte [ecx + eax + 0x2ef78]
add esi, eax
or ebx, edx
cmp esi, 0x10
jl 0x100467e0
mov eax, dword [ebp + 8]
mov byte [eax], bl
mov ecx, ebx
inc eax
shr ecx, 8
mov byte [eax], cl
inc eax
shr ebx, 0x10
mov dword [ebp + 8], eax
sub esi, 0x10
mov eax, dword [ebp - 0x20]
mov ecx, 0x100
cmp eax, ecx
jb 0x100467f1
shr eax, 7
add eax, ecx
movzx ecx, byte [eax + 0x68cd8180]
mov eax, dword [ebp - 0x18]
movzx edx, byte [eax + 0x68cd805d]
movzx eax, byte [ecx + 0x68cd1114]
mov dword [ebp - 0x24], eax
movzx eax, byte [edx + 0x68cd10f4]
inc dword [edi + 0x14]
mov dword [ebp - 0x10], eax
mov eax, dword [edi + 0x38]
lea eax, [eax + edx*2 + 0x2f4da]
inc word [eax]
mov eax, dword [edi + 0x38]
lea eax, [eax + ecx*2 + 0x2fab8]
inc word [eax]
mov eax, dword [edi + 0x38]
movzx eax, word [eax + edx*2 + 0x2f29a]
mov dword [ebp - 8], ecx
mov ecx, esi
shl eax, cl
or ebx, eax
mov eax, dword [edi + 0x38]
movzx eax, byte [eax + edx + 0x2f079]
add esi, eax
cmp esi, 0x10
mov eax, dword [ebp + 8]
jl 0x10046870
mov byte [eax], bl
mov ecx, ebx
inc eax
shr ecx, 8
mov byte [eax], cl
inc eax
shr ebx, 0x10
mov dword [ebp + 8], eax
sub esi, 0x10
mov ecx, dword [ebp - 0x10]
test ecx, ecx
jle 0x100468a7
xor edx, edx
inc edx
shl edx, cl
mov ecx, dword [ebp - 0x18]
add ecx, 0xfffffffd
dec edx
and edx, ecx
mov ecx, esi
add esi, dword [ebp - 0x10]
shl edx, cl
or ebx, edx
cmp esi, 0x10
jl 0x100468a7
mov byte [eax], bl
mov ecx, ebx
inc eax
shr ecx, 8
mov byte [eax], cl
inc eax
shr ebx, 0x10
mov dword [ebp + 8], eax
sub esi, 0x10
mov ecx, dword [edi + 0x38]
mov edx, dword [ebp - 8]
movzx edx, word [ecx + edx*2 + 0x2c638]
mov ecx, esi
shl edx, cl
mov ecx, dword [edi + 0x38]
or ebx, edx
mov edx, dword [ebp - 8]
movzx ecx, byte [ecx + edx + 0x2c618]
add esi, ecx
cmp esi, 0x10
mov dword [ebp - 8], esi
jl 0x100468ea
mov byte [eax], bl
mov ecx, ebx
inc eax
shr ecx, 8
mov byte [eax], cl
inc eax
shr ebx, 0x10
sub esi, 0x10
mov dword [ebp + 8], eax
mov dword [ebp - 8], esi
mov ecx, dword [ebp - 0x24]
test ecx, ecx
jle 0x10046922
xor edx, edx
inc edx
shl edx, cl
mov ecx, esi
add esi, dword [ebp - 0x24]
dec edx
and edx, dword [ebp - 0x20]
mov dword [ebp - 8], esi
shl edx, cl
or ebx, edx
cmp esi, 0x10
jl 0x10046922
mov byte [eax], bl
mov ecx, ebx
inc eax
shr ecx, 8
mov byte [eax], cl
inc eax
shr ebx, 0x10
sub esi, 0x10
mov dword [ebp + 8], eax
mov dword [ebp - 8], esi
mov eax, dword [ebp - 0x18]
inc dword [ebp - 4]
mov dword [ebp - 0x10], eax
jmp 0x10046bc1
mov eax, dword [ebp - 0x1c]
mov ecx, 0x100
cmp eax, ecx
jb 0x10046941
shr eax, 7
add eax, ecx
movzx edx, byte [eax + 0x68cd8180]
movzx ecx, byte [edx + 0x68cd1114]
mov eax, dword [ebp - 0x10]
movzx eax, byte [eax + 0x68cd805d]
mov dword [ebp - 0x28], ecx
movzx ecx, byte [eax + 0x68cd10f4]
inc dword [edi + 0x14]
mov dword [ebp - 0x24], ecx
mov ecx, dword [edi + 0x38]
lea ecx, [ecx + eax*2 + 0x2f4da]
inc word [ecx]
mov ecx, dword [edi + 0x38]
lea ecx, [ecx + edx*2 + 0x2fab8]
inc word [ecx]
mov ecx, dword [edi + 0x38]
mov dword [ebp - 0x18], edx
movzx edx, word [ecx + eax*2 + 0x2f29a]
mov ecx, esi
shl edx, cl
mov ecx, dword [edi + 0x38]
movzx eax, byte [ecx + eax + 0x2f079]
add esi, eax
mov eax, dword [ebp + 8]
or ebx, edx
cmp esi, 0x10
jl 0x100469c0
mov byte [eax], bl
mov ecx, ebx
inc eax
shr ecx, 8
mov byte [eax], cl
inc eax
shr ebx, 0x10
mov dword [ebp + 8], eax
sub esi, 0x10
mov ecx, dword [ebp - 0x24]
test ecx, ecx
jle 0x100469f7
xor edx, edx
inc edx
shl edx, cl
mov ecx, dword [ebp - 0x10]
add ecx, 0xfffffffd
dec edx
and edx, ecx
mov ecx, esi
add esi, dword [ebp - 0x24]
shl edx, cl
or ebx, edx
cmp esi, 0x10
jl 0x100469f7
mov byte [eax], bl
mov ecx, ebx
inc eax
shr ecx, 8
mov byte [eax], cl
inc eax
shr ebx, 0x10
mov dword [ebp + 8], eax
sub esi, 0x10
mov ecx, dword [edi + 0x38]
mov edx, dword [ebp - 0x18]
movzx edx, word [ecx + edx*2 + 0x2c638]
mov ecx, esi
shl edx, cl
mov ecx, dword [edi + 0x38]
or ebx, edx
mov edx, dword [ebp - 0x18]
movzx ecx, byte [ecx + edx + 0x2c618]
add esi, ecx
cmp esi, 0x10
mov dword [ebp - 8], esi
jl 0x10046a3a
mov byte [eax], bl
mov ecx, ebx
inc eax
shr ecx, 8
mov byte [eax], cl
inc eax
shr ebx, 0x10
sub esi, 0x10
mov dword [ebp + 8], eax
mov dword [ebp - 8], esi
mov ecx, dword [ebp - 0x28]
test ecx, ecx
jle 0x10046a72
xor edx, edx
inc edx
shl edx, cl
mov ecx, esi
add esi, dword [ebp - 0x28]
dec edx
and edx, dword [ebp - 0x1c]
mov dword [ebp - 8], esi
shl edx, cl
or ebx, edx
cmp esi, 0x10
jl 0x10046a72
mov byte [eax], bl
mov ecx, ebx
inc eax
shr ecx, 8
mov byte [eax], cl
inc eax
shr ebx, 0x10
sub esi, 0x10
mov dword [ebp + 8], eax
mov dword [ebp - 8], esi
dec dword [ebp - 0x10]
inc dword [ebp - 4]
jmp 0x10046bc1
mov ecx, dword [ebp - 0x1c]
mov edx, 0x100
cmp ecx, edx
jb 0x10046a8e
shr ecx, 7
add ecx, edx
movzx edx, byte [eax + 0x68cd805d]
movzx ecx, byte [ecx + 0x68cd8180]
movzx eax, byte [ecx + 0x68cd1114]
mov dword [ebp - 0x18], eax
movzx eax, byte [edx + 0x68cd10f4]
inc dword [edi + 0x14]
mov dword [ebp - 0x28], eax
mov eax, dword [edi + 0x38]
lea eax, [eax + edx*2 + 0x2f4da]
inc word [eax]
mov eax, dword [edi + 0x38]
lea eax, [eax + ecx*2 + 0x2fab8]
inc word [eax]
mov eax, dword [edi + 0x38]
movzx eax, word [eax + edx*2 + 0x2f29a]
mov dword [ebp - 0x24], ecx
mov ecx, esi
shl eax, cl
or ebx, eax
mov eax, dword [edi + 0x38]
movzx eax, byte [eax + edx + 0x2f079]
add esi, eax
cmp esi, 0x10
mov eax, dword [ebp + 8]
jl 0x10046b0a
mov byte [eax], bl
mov ecx, ebx
inc eax
shr ecx, 8
mov byte [eax], cl
inc eax
shr ebx, 0x10
mov dword [ebp + 8], eax
sub esi, 0x10
mov ecx, dword [ebp - 0x28]
test ecx, ecx
jle 0x10046b41
xor edx, edx
inc edx
shl edx, cl
mov ecx, dword [ebp - 0x10]
add ecx, 0xfffffffd
dec edx
and edx, ecx
mov ecx, esi
add esi, dword [ebp - 0x28]
shl edx, cl
or ebx, edx
cmp esi, 0x10
jl 0x10046b41
mov byte [eax], bl
mov ecx, ebx
inc eax
shr ecx, 8
mov byte [eax], cl
inc eax
shr ebx, 0x10
mov dword [ebp + 8], eax
sub esi, 0x10
mov ecx, dword [edi + 0x38]
mov edx, dword [ebp - 0x24]
movzx edx, word [ecx + edx*2 + 0x2c638]
mov ecx, esi
shl edx, cl
mov ecx, dword [edi + 0x38]
or ebx, edx
mov edx, dword [ebp - 0x24]
movzx ecx, byte [ecx + edx + 0x2c618]
add esi, ecx
cmp esi, 0x10
mov dword [ebp - 8], esi
jl 0x10046b84
mov byte [eax], bl
mov ecx, ebx
inc eax
shr ecx, 8
mov byte [eax], cl
inc eax
shr ebx, 0x10
sub esi, 0x10
mov dword [ebp + 8], eax
mov dword [ebp - 8], esi
cmp dword [ebp - 0x18], 0
jle 0x10046bc1
mov ecx, dword [ebp - 0x18]
xor eax, eax
inc eax
shl eax, cl
mov ecx, esi
add esi, dword [ebp - 0x18]
dec eax
and eax, dword [ebp - 0x1c]
mov dword [ebp - 8], esi
shl eax, cl
or ebx, eax
cmp esi, 0x10
jl 0x10046bc1
mov eax, dword [ebp + 8]
mov byte [eax], bl
mov ecx, ebx
inc eax
shr ecx, 8
mov byte [eax], cl
inc eax
shr ebx, 0x10
sub esi, 0x10
mov dword [ebp + 8], eax
mov dword [ebp - 8], esi
mov edx, dword [edi + 0x1c]
mov ecx, dword [ebp - 4]
mov eax, dword [ebp - 0x10]
sub edx, ecx
cmp edx, eax
jg 0x10046bd9
lea eax, [ecx + eax - 1]
mov dword [ebp - 4], eax
jmp 0x10046c26
dec eax
test eax, eax
jle 0x10046c26
mov dword [ebp - 0x28], eax
mov edx, dword [ebp - 4]
mov eax, dword [ebp - 0xc]
movzx eax, byte [eax + edx + 2]
mov ecx, dword [ebp - 0x14]
shl ecx, 5
xor eax, ecx
mov ecx, dword [ebp - 0xc]
mov dword [ebp - 0x14], eax
and eax, 0x1fff
lea eax, [ecx + eax*2 + 0x2030a]
movzx ecx, word [eax]
mov word [eax], dx
mov eax, dword [ebp - 0xc]
and edx, 0x7fff
add eax, 0x10106
inc dword [ebp - 4]
dec dword [ebp - 0x28]
mov word [eax + edx*2], cx
jne 0x10046be1
mov eax, dword [ebp - 0xc]
cmp dword [edi + 0x14], 0xfff2
jae 0x10046c3d
lea ecx, [eax + 0x2c302]
cmp dword [ebp + 8], ecx
jb 0x10046c79
mov eax, dword [ebp + 8]
mov byte [eax], bl
inc eax
mov ecx, ebx
shr ecx, 8
mov byte [eax], cl
inc eax
push edi
mov dword [ebp + 8], eax
call fcn.100492bb
cmp dword [edi], 0
mov eax, dword [ebp - 0xc]
jne 0x10046c85
mov ecx, dword [eax + 0x2c314]
mov ebx, dword [eax + 0x2c30c]
mov eax, dword [eax + 0x2c310]
mov dword [ebp - 8], eax
mov esi, eax
mov eax, dword [ebp - 0xc]
mov dword [ebp + 8], ecx
mov ecx, dword [ebp - 4]
cmp ecx, dword [edi + 0x1c]
jl 0x100465ec
mov ecx, dword [ebp + 8]
mov dword [eax + 0x2c314], ecx
mov dword [eax + 0x2c30c], ebx
mov dword [eax + 0x2c310], esi
mov eax, dword [ebp - 4]
cmp eax, 0x10000
mov dword [edi + 0x18], eax
jne 0x10046cad
push edi
call fcn.1004646f
pop edi
pop esi
pop ebx
leave
ret 0x14