Function at 0x10017520
Capabilities:
Encode data using xor

Disassembly:
mov eax, dword [esp + 0xc]
sub esp, 0x24
cmp dword [eax + 0x104], 0
jne 0x1001753a
mov dword [eax + 0x104], 0x10
mov ecx, dword [eax + 0x104]
xor edx, edx
and ecx, 0xfffffffe
or ecx, 2
mov dword [eax + 0x104], ecx
mov ecx, dword [esp + 0x28]
mov dh, byte [ecx + 3]
push ebx
push ebp
push esi
movzx esi, byte [ecx + 1]
mov dl, byte [ecx + 2]
push edi
mov ebp, dword [esp + 0x3c]
shr ebp, 2
shl edx, 8
or edx, esi
movzx esi, byte [ecx]
shl edx, 8
or esi, edx
xor edx, edx
mov dword [eax], esi
mov dh, byte [ecx + 7]
movzx edi, byte [ecx + 5]
mov dl, byte [ecx + 6]
shl edx, 8
or edx, edi
movzx edi, byte [ecx + 4]
shl edx, 8
or edi, edx
xor edx, edx
mov dword [eax + 4], edi
mov dh, byte [ecx + 0xb]
movzx ebx, byte [ecx + 9]
mov dl, byte [ecx + 0xa]
shl edx, 8
or edx, ebx
movzx ebx, byte [ecx + 8]
shl edx, 8
or edx, ebx
xor ebx, ebx
mov dword [eax + 8], edx
mov bh, byte [ecx + 0xf]
mov dword [esp + 0x1c], edx
movzx edx, byte [ecx + 0xd]
mov bl, byte [ecx + 0xe]
shl ebx, 8
or ebx, edx
movzx edx, byte [ecx + 0xc]
shl ebx, 8
or ebx, edx
cmp ebp, 4
mov dword [eax + 0xc], ebx
mov edx, ebp
ja 0x100175dd
mov edx, 4
add edx, 6
mov dword [eax + 0x100], edx
lea eax, [edx*4 + 3]
xor edx, edx
div ebp
mov edx, dword [esp + 0x3c]
cmp edx, 0x10
mov dword [esp + 0x38], eax
je 0x100178ff
cmp edx, 0x18
je 0x1001781a
cmp edx, 0x20
je 0x10017628
mov eax, dword [esp + 0x40]
pop edi
pop esi
pop ebp
mov dword [eax + 0x100], 0
xor eax, eax
pop ebx
add esp, 0x24
ret
xor eax, eax
mov ah, byte [ecx + 0x13]
movzx edx, byte [ecx + 0x11]
mov ebp, dword [esp + 0x40]
mov dword [esp + 0x3c], 0
mov al, byte [ecx + 0x12]
shl eax, 8
or eax, edx
movzx edx, byte [ecx + 0x10]
shl eax, 8
or eax, edx
mov dword [ebp + 0x10], eax
mov dword [esp + 0x24], eax
movzx edx, byte [ecx + 0x15]
xor eax, eax
mov ah, byte [ecx + 0x17]
mov al, byte [ecx + 0x16]
shl eax, 8
or eax, edx
movzx edx, byte [ecx + 0x14]
shl eax, 8
or eax, edx
mov dword [ebp + 0x14], eax
movzx edx, byte [ecx + 0x19]
mov dword [esp + 0x28], eax
xor eax, eax
mov ah, byte [ecx + 0x1b]
mov al, byte [ecx + 0x1a]
shl eax, 8
or eax, edx
movzx edx, byte [ecx + 0x18]
shl eax, 8
or eax, edx
mov dword [ebp + 0x18], eax
movzx edx, byte [ecx + 0x1d]
mov dword [esp + 0x2c], eax
xor eax, eax
mov ah, byte [ecx + 0x1f]
mov al, byte [ecx + 0x1e]
movzx ecx, byte [ecx + 0x1c]
shl eax, 8
or eax, edx
shl eax, 8
or eax, ecx
cmp dword [esp + 0x38], 0
mov dword [ebp + 0x1c], eax
jbe 0x100177a8
lea ecx, [ebp + 0x24]
mov dword [esp + 0x10], ebx
mov ebx, eax
mov edx, eax
shr edx, 0x18
mov edx, dword [edx*4 + 0x10030a50]
shr ebx, 0x10
movzx ebp, bl
xor edx, dword [ebp*4 + 0x10030650]
mov ebx, eax
shr ebx, 8
movzx ebp, bl
xor edx, dword [ebp*4 + str.cwko0]
mov ebx, dword [esp + 0x10]
movzx ebp, al
xor edx, dword [ebp*4 + 0x10030e50]
mov ebp, dword [esp + 0x3c]
xor edx, dword [ebp*4 + 0x1002f1d8]
mov dword [esp + 0x10], eax
xor esi, edx
mov edx, dword [esp + 0x1c]
xor edi, esi
xor edx, edi
mov dword [ecx + 4], edx
xor ebx, edx
mov dword [esp + 0x1c], edx
mov dword [ecx - 4], esi
mov dword [ecx], edi
mov dword [ecx + 8], ebx
mov eax, ebx
shr eax, 0x10
movzx ebp, al
mov edx, ebx
shr edx, 0x18
mov eax, dword [edx*4 + 0x10030e50]
xor eax, dword [ebp*4 + 0x10030a50]
mov ebp, dword [esp + 0x28]
mov edx, ebx
shr edx, 8
movzx edx, dl
xor eax, dword [edx*4 + 0x10030650]
movzx edx, bl
xor eax, dword [edx*4 + str.cwko0]
mov edx, dword [esp + 0x24]
xor edx, eax
mov eax, dword [esp + 0x10]
xor ebp, edx
mov dword [ecx + 0xc], edx
mov dword [esp + 0x24], edx
mov edx, dword [esp + 0x2c]
xor edx, ebp
xor eax, edx
mov dword [ecx + 0x14], edx
mov dword [esp + 0x2c], edx
mov edx, dword [esp + 0x3c]
add edx, 1
mov dword [ecx + 0x10], ebp
mov dword [ecx + 0x18], eax
add ecx, 0x20
cmp edx, dword [esp + 0x38]
mov dword [esp + 0x28], ebp
mov dword [esp + 0x3c], edx
jb 0x100176c2
mov ebp, dword [esp + 0x40]
mov ecx, dword [ebp + 0x100]
add ecx, ecx
mov eax, 4
add ecx, ecx
cmp ecx, eax
jbe 0x1001780d
jmp 0x100177c0
mov ecx, dword [ebp + eax*4]
mov ebx, ecx
mov edx, ecx
shr edx, 0x18
mov edx, dword [edx*4 + 0x10033e50]
shr ebx, 0x10
shr ecx, 8
movzx esi, bl
xor edx, dword [esi*4 + 0x10033a50]
movzx ecx, cl
xor edx, dword [ecx*4 + 0x10033650]
movzx ecx, byte [ebp + eax*4]
xor edx, dword [ecx*4 + 0x10033250]
add eax, 1
mov dword [ebp + eax*4 - 4], edx
mov edx, dword [ebp + 0x100]
add edx, edx
add edx, edx
cmp eax, edx
jb 0x100177c0
pop edi
pop esi
pop ebp
mov eax, 1
pop ebx
add esp, 0x24
ret
movzx edx, byte [ecx + 0x11]
xor eax, eax
mov ah, byte [ecx + 0x13]
mov ebp, dword [esp + 0x40]
mov dword [esp + 0x3c], 0
mov al, byte [ecx + 0x12]
shl eax, 8
or eax, edx
movzx edx, byte [ecx + 0x10]
shl eax, 8
or eax, edx
mov dword [ebp + 0x10], eax
movzx edx, byte [ecx + 0x15]
mov dword [esp + 0x24], eax
xor eax, eax
mov ah, byte [ecx + 0x17]
mov al, byte [ecx + 0x16]
movzx ecx, byte [ecx + 0x14]
shl eax, 8
or eax, edx
shl eax, 8
or ecx, eax
cmp dword [esp + 0x38], 0
mov dword [ebp + 0x14], ecx
jbe 0x100177a8
lea eax, [ebp + 0x1c]
mov dword [esp + 0x10], ebx
mov ebx, ecx
shr ebx, 0x10
movzx ebp, bl
mov edx, ecx
shr edx, 0x18
mov edx, dword [edx*4 + 0x10030a50]
xor edx, dword [ebp*4 + 0x10030650]
mov ebx, ecx
shr ebx, 8
movzx ebp, bl
xor edx, dword [ebp*4 + str.cwko0]
mov ebx, dword [esp + 0x10]
movzx ebp, cl
xor edx, dword [ebp*4 + 0x10030e50]
mov ebp, dword [esp + 0x3c]
xor edx, dword [ebp*4 + 0x1002f1d8]
add ebp, 1
xor esi, edx
mov edx, dword [esp + 0x1c]
xor edi, esi
xor edx, edi
xor ebx, edx
mov dword [eax + 4], edx
mov dword [esp + 0x1c], edx
mov edx, dword [esp + 0x24]
xor edx, ebx
xor ecx, edx
mov dword [eax - 4], esi
mov dword [eax], edi
mov dword [eax + 8], ebx
mov dword [eax + 0xc], edx
mov dword [eax + 0x10], ecx
add eax, 0x18
cmp ebp, dword [esp + 0x38]
mov dword [esp + 0x24], edx
mov dword [esp + 0x3c], ebp
jb 0x10017872
jmp 0x100177a4
test eax, eax
mov dword [esp + 0x3c], 0
jbe 0x100177a4
mov ebp, dword [esp + 0x40]
lea eax, [ebp + 0x14]
mov edx, ebx
shr edx, 0x10
movzx edx, dl
mov ecx, ebx
shr ecx, 0x18
mov ecx, dword [ecx*4 + 0x10030a50]
xor ecx, dword [edx*4 + 0x10030650]
mov edx, ebx
shr edx, 8
movzx edx, dl
xor ecx, dword [edx*4 + str.cwko0]
movzx edx, bl
xor ecx, dword [edx*4 + 0x10030e50]
mov edx, dword [esp + 0x3c]
xor ecx, dword [edx*4 + 0x1002f1d8]
add edx, 1
xor esi, ecx
mov ecx, dword [esp + 0x1c]
xor edi, esi
xor ecx, edi
xor ebx, ecx
mov dword [eax - 4], esi
mov dword [eax], edi
mov dword [eax + 4], ecx
mov dword [eax + 8], ebx
add eax, 0x10
cmp edx, dword [esp + 0x38]
mov dword [esp + 0x1c], ecx
mov dword [esp + 0x3c], edx
jb 0x10017916
jmp 0x100177a8