Function at 0x10018260
Capabilities:
Encode data using xor

Disassembly:
push ebp
push ebx
push edi
push esi
sub esp, 0x2c
mov eax, dword [esp + 0x40]
mov ebp, ecx
add dword [ecx + 0x38], eax
mov dword [esp + 0xc], ebp
mov dword [esp + 0x1c], edx
mov ecx, dword [ecx + 0x3c]
test ecx, ecx
je 0x100182a4
mov esi, 8
mov dword [esp], 0
mov dword [esp + 0x14], ecx
sub esi, ecx
cmp esi, eax
cmovb eax, esi
cmp eax, 4
jb 0x100182ab
mov edi, dword [edx]
mov ebx, 4
jmp 0x100182af
xor esi, esi
jmp 0x1001842d
xor ebx, ebx
xor edi, edi
mov ecx, ebx
mov dword [esp + 4], esi
or ecx, 1
cmp ecx, eax
jae 0x100182e5
movzx edx, word [edx + ebx]
lea ecx, [ebx*8]
xor ebp, ebp
xor esi, esi
shld ebp, edx, cl
shl edx, cl
test cl, 0x20
cmovne ebp, edx
cmovne edx, esi
or ebx, 2
or dword [esp], ebp
mov ebp, dword [esp + 0xc]
or edi, edx
cmp ebx, eax
jae 0x10018319
mov eax, dword [esp + 0x1c]
xor esi, esi
xor edx, edx
movzx eax, byte [eax + ebx]
shl ebx, 3
mov ecx, ebx
shld esi, eax, cl
shl eax, cl
test bl, 0x20
mov ebx, dword [esp]
cmovne esi, eax
cmovne eax, edx
or edi, eax
mov eax, dword [esp + 4]
or ebx, esi
mov esi, dword [esp + 0x14]
jmp 0x10018324
mov eax, dword [esp + 4]
mov esi, dword [esp + 0x14]
mov ebx, dword [esp]
lea ecx, [esi*8]
xor edx, edx
shld ebx, edi, cl
shl edi, cl
test cl, 0x20
mov ecx, dword [esp + 0x40]
cmovne ebx, edi
cmove edx, edi
or ebx, dword [ebp + 0x34]
or edx, dword [ebp + 0x30]
cmp eax, ecx
mov dword [ebp + 0x30], edx
mov dword [ebp + 0x34], ebx
jbe 0x1001835a
add esi, ecx
mov eax, ecx
mov ecx, esi
jmp 0x1001860f
mov eax, dword [ebp + 0x2c]
mov ecx, dword [ebp + 0x20]
mov edi, dword [ebp + 0x10]
mov esi, dword [ebp + 0x24]
mov dword [esp], ebx
xor eax, ebx
mov ebx, dword [ebp + 0x1c]
mov dword [esp + 0x20], eax
mov eax, dword [ebp + 0x28]
xor eax, edx
add edi, ecx
mov dword [esp + 0x18], edi
mov edi, dword [ebp + 0x14]
adc edi, esi
mov dword [esp + 0x10], edi
mov edi, ecx
shld edi, esi, 0xd
shld esi, ecx, 0xd
mov ecx, dword [ebp + 0x18]
mov ebp, eax
xor esi, dword [esp + 0x10]
xor edi, dword [esp + 0x18]
mov dword [esp + 8], ecx
add dword [esp + 8], eax
mov ecx, dword [esp + 0x20]
adc ebx, ecx
shld ebp, ecx, 0x10
shrd eax, ecx, 0x10
xor ebp, dword [esp + 8]
xor eax, ebx
add dword [esp + 0x10], ebp
mov ecx, ebp
adc dword [esp + 0x18], eax
shld ecx, eax, 0x15
shrd ebp, eax, 0xb
mov eax, dword [esp + 0xc]
xor ecx, dword [esp + 0x10]
xor ebp, dword [esp + 0x18]
mov dword [eax + 0x28], ecx
mov eax, dword [esp + 0xc]
mov ecx, dword [esp + 8]
mov dword [eax + 0x2c], ebp
mov ebp, dword [esp + 0xc]
add ecx, edi
mov eax, edi
adc ebx, esi
shld eax, esi, 0x11
shrd edi, esi, 0xf
mov esi, dword [esp + 4]
xor eax, ecx
xor edi, ebx
mov dword [ebp + 0x20], eax
mov dword [ebp + 0x24], edi
mov edi, dword [esp + 0x10]
mov dword [ebp + 0x18], ebx
mov ebx, dword [esp + 0x18]
mov eax, dword [esp + 0x40]
mov dword [ebp + 0x1c], ecx
xor edi, edx
xor ebx, dword [esp]
mov edx, dword [esp + 0x1c]
mov dword [ebp + 0x10], edi
mov dword [ebp + 0x14], ebx
mov dword [ebp + 0x3c], 0
sub eax, esi
mov ecx, eax
and eax, 0xfffffff8
and ecx, 7
cmp esi, eax
mov dword [esp + 0x14], ecx
jae 0x10018578
mov dword [esp + 0x24], eax
mov dword [esp + 4], esi
mov ebx, dword [ebp + 0x2c]
mov eax, dword [ebp + 0x28]
mov edi, dword [ebp + 0x10]
mov edx, dword [ebp + 0x14]
mov ecx, dword [ebp + 0x24]
mov esi, dword [ebp + 0x20]
mov ebp, dword [esp + 0xc]
mov ebp, dword [ebp + 0x1c]
mov dword [esp + 0x10], ebp
mov ebp, dword [esp + 0xc]
mov ebp, dword [ebp + 0x18]
mov dword [esp + 8], ebp
nop word cs:[eax + eax]
nop dword [eax]
mov dword [esp], ebx
mov ebp, dword [esp + 0x1c]
mov ebx, dword [esp + 4]
mov ebp, dword [ebp + ebx + 4]
mov ebx, dword [esp]
mov dword [esp + 0x18], ebp
mov ebp, dword [esp + 0x1c]
xor ebx, dword [esp + 0x18]
mov dword [esp], ebx
mov ebx, dword [esp + 4]
mov ebp, dword [ebp + ebx]
mov ebx, dword [esp]
xor eax, ebp
add edi, esi
mov dword [esp + 0x20], ebp
mov ebp, esi
adc edx, ecx
shld ebp, ecx, 0xd
shld ecx, esi, 0xd
mov esi, dword [esp + 8]
xor ebp, edi
xor ecx, edx
mov dword [esp + 0x28], ebp
mov ebp, dword [esp + 0x10]
add esi, eax
adc ebp, ebx
mov dword [esp + 8], ebp
mov ebp, eax
shrd eax, ebx, 0x10
shld ebp, ebx, 0x10
xor eax, dword [esp + 8]
xor ebp, esi
add edx, ebp
mov dword [esp], edx
mov edx, ebp
adc edi, eax
shld edx, eax, 0x15
shrd ebp, eax, 0xb
mov eax, edx
mov edx, dword [esp + 0x28]
mov ebx, ebp
mov ebp, dword [esp + 8]
xor ebx, edi
xor eax, dword [esp]
add esi, edx
mov dword [esp + 0x10], esi
mov esi, edx
adc ebp, ecx
shld esi, ecx, 0x11
shld ecx, edx, 0x11
mov dword [esp + 8], ebp
mov edx, edi
mov edi, dword [esp]
xor ecx, ebp
mov ebp, dword [esp + 4]
xor edx, dword [esp + 0x18]
xor esi, dword [esp + 0x10]
xor edi, dword [esp + 0x20]
add ebp, 8
cmp ebp, dword [esp + 0x24]
mov dword [esp + 4], ebp
jb 0x10018480
mov ebp, dword [esp + 0xc]
mov dword [ebp + 0x28], eax
mov dword [ebp + 0x2c], ebx
mov dword [ebp + 0x14], edx
mov dword [ebp + 0x10], edi
mov dword [ebp + 0x24], ecx
mov edx, dword [esp + 8]
mov ecx, dword [esp + 0x10]
mov dword [ebp + 0x20], esi
mov esi, dword [esp + 4]
mov dword [ebp + 0x18], edx
mov dword [ebp + 0x1c], ecx
mov edx, dword [esp + 0x1c]
mov ecx, dword [esp + 0x14]
xor eax, eax
cmp ecx, 4
jb 0x10018589
mov edi, dword [edx + esi]
mov ebx, 4
jmp 0x1001858d
xor ebx, ebx
xor edi, edi
mov ebp, dword [esp + 0x14]
mov ecx, ebx
mov dword [esp + 4], esi
or ecx, 1
cmp ecx, ebp
jae 0x100185d2
lea ecx, [ebx + esi]
xor ebp, ebp
mov esi, 0
movzx edx, word [edx + ecx]
lea ecx, [ebx*8]
shld ebp, edx, cl
shl edx, cl
test cl, 0x20
mov ecx, dword [esp + 0x14]
cmovne ebp, edx
cmovne edx, esi
or ebx, 2
or eax, ebp
or edi, edx
cmp ebx, ecx
jb 0x100185d8
jmp 0x10018605
mov ecx, ebp
cmp ebx, ecx
jae 0x10018605
mov ecx, dword [esp + 4]
mov edx, dword [esp + 0x1c]
xor ebp, ebp
xor esi, esi
add ecx, ebx
shl ebx, 3
movzx edx, byte [edx + ecx]
mov ecx, ebx
shld ebp, edx, cl
shl edx, cl
mov ecx, dword [esp + 0x14]
test bl, 0x20
cmovne ebp, edx
cmovne edx, esi
or eax, ebp
or edi, edx
mov ebp, dword [esp + 0xc]
mov dword [ebp + 0x30], edi
mov dword [ebp + 0x34], eax
mov dword [ebp + 0x3c], ecx
add esp, 0x2c
pop esi
pop edi
pop ebx
pop ebp
ret