Function at 0x416250
Capabilities:
Encode data using xor

Disassembly:
sub esp, 0xc
mov edx, dword [esp + 0x14]
push ebx
push ebp
push esi
push edi
xor eax, eax
mov ecx, 0x400
mov edi, edx
xor ebp, ebp
rep stosd dword es:[edi], eax
mov dword [esp + 0x10], ebp
lea esp, [esp]
test ebp, ebp
jne 0x4164c4
mov eax, dword [esp + 0x20]
mov ecx, dword [eax]
mov dword [edx + 0x180], ecx
mov eax, dword [eax + 4]
mov dword [edx + 0x184], eax
mov ebx, 4
lea ecx, [ebx + 0x10]
shl ecx, 4
lea eax, [ecx + edx]
lea ecx, [ebx + 8]
shl ecx, 5
mov esi, dword [ecx + edx]
mov dword [eax], esi
mov ecx, dword [ecx + edx + 4]
mov dword [eax + 4], ecx
mov esi, 2
mov ecx, dword [eax + esi*4 - 4]
dec esi
mov edi, ecx
shl edi, 0x18
mov ebp, ecx
shr ebp, 8
or edi, ebp
mov ebp, ecx
and ebp, 0xff00
and edi, 0xff00ff00
shl ebp, 8
or edi, ebp
shr ecx, 0x18
or edi, ecx
test esi, esi
mov dword [eax + esi*4], edi
jne 0x4162b2
mov esi, dword [eax + 4]
mov ecx, esi
and ecx, 1
mov edi, dword [ecx*4 + 0x450700]
mov ecx, dword [eax]
mov ebp, ecx
shr esi, 1
shl ebp, 0x1f
or ebp, esi
shr ecx, 1
xor ecx, edi
mov dword [eax + 4], ebp
mov dword [eax], ecx
mov esi, 2
lea ebx, [ebx]
mov ecx, dword [eax + esi*4 - 4]
dec esi
mov edi, ecx
shl edi, 0x18
mov ebp, ecx
shr ebp, 8
or edi, ebp
mov ebp, ecx
and ebp, 0xff00
and edi, 0xff00ff00
shl ebp, 8
or edi, ebp
shr ecx, 0x18
or edi, ecx
test esi, esi
mov dword [eax + esi*4], edi
jne 0x416310
sar ebx, 1
test ebx, ebx
jg 0x416292
mov ecx, dword [edx + 0x114]
mov eax, dword [edx + 0x110]
mov dword [edx + 0x84], ecx
mov dword [edx + 0x80], eax
mov ecx, 2
mov eax, dword [edx + ecx*4 + 0x7c]
dec ecx
mov esi, eax
shl esi, 0x18
mov edi, eax
shr edi, 8
or esi, edi
mov edi, eax
and edi, 0xff00
and esi, 0xff00ff00
shl edi, 8
or esi, edi
shr eax, 0x18
or esi, eax
test ecx, ecx
mov dword [edx + ecx*4 + 0x80], esi
jne 0x416367
mov ecx, dword [edx + 0x84]
mov eax, ecx
and eax, 1
mov esi, dword [eax*4 + 0x450700]
mov eax, dword [edx + 0x80]
mov edi, eax
shr ecx, 1
shl edi, 0x1f
or edi, ecx
shr eax, 1
xor eax, esi
mov dword [edx + 0x84], edi
mov dword [edx + 0x80], eax
mov ecx, 2
mov eax, dword [edx + ecx*4 + 0x7c]
dec ecx
mov esi, eax
shl esi, 0x18
mov edi, eax
shr edi, 8
or esi, edi
mov edi, eax
and edi, 0xff00
and esi, 0xff00ff00
shl edi, 8
or esi, edi
shr eax, 0x18
or esi, eax
test ecx, ecx
mov dword [edx + ecx*4 + 0x80], esi
jne 0x4163d1
mov ebx, 4
lea ebx, [ebx]
mov ecx, ebx
shl ecx, 4
lea eax, [ecx + edx]
mov ecx, ebx
shl ecx, 5
mov esi, dword [ecx + edx]
mov dword [eax], esi
mov ecx, dword [ecx + edx + 4]
mov dword [eax + 4], ecx
mov esi, 2
mov edi, edi
mov ecx, dword [eax + esi*4 - 4]
dec esi
mov edi, ecx
shl edi, 0x18
mov ebp, ecx
shr ebp, 8
or edi, ebp
mov ebp, ecx
and ebp, 0xff00
and edi, 0xff00ff00
shl ebp, 8
or edi, ebp
shr ecx, 0x18
or edi, ecx
test esi, esi
mov dword [eax + esi*4], edi
jne 0x416430
mov esi, dword [eax + 4]
mov ecx, esi
and ecx, 1
mov edi, dword [ecx*4 + 0x450700]
mov ecx, dword [eax]
mov ebp, ecx
shr esi, 1
shl ebp, 0x1f
or ebp, esi
shr ecx, 1
xor ecx, edi
mov dword [eax + 4], ebp
mov dword [eax], ecx
mov esi, 2
mov ecx, dword [eax + esi*4 - 4]
dec esi
mov edi, ecx
shl edi, 0x18
mov ebp, ecx
shr ebp, 8
or edi, ebp
mov ebp, ecx
and ebp, 0xff00
and edi, 0xff00ff00
shl ebp, 8
or edi, ebp
shr ecx, 0x18
or edi, ecx
test esi, esi
mov dword [eax + esi*4], edi
jne 0x416488
sar ebx, 1
test ebx, ebx
jg 0x416410
jmp 0x41652f
cmp ebp, 1
jle 0x416533
lea ecx, [ebp - 2]
shl ecx, 4
mov eax, ebp
shl eax, 4
mov edi, 8
mov dword [esp + 0x18], ecx
mov dword [esp + 0x14], eax
jmp 0x4164f0
mov eax, dword [esp + 0x14]
mov ecx, dword [esp + 0x18]
jmp 0x4164f0
add ecx, edi
shl ecx, 4
mov esi, dword [ecx + edx]
mov ecx, dword [ecx + edx + 4]
add eax, edi
shl eax, 4
add eax, edx
mov dword [eax + 4], ecx
mov ebx, ecx
mov ebp, esi
shl ecx, 8
shr ebp, 0x18
or ebp, ecx
mov dword [eax], esi
shr ebx, 0x18
mov dword [eax + 4], ebp
movzx ecx, word [ebx*2 + 0x441208]
shl esi, 8
xor ecx, esi
sar edi, 1
test edi, edi
mov dword [eax], ecx
jg 0x4164e3
mov ebp, dword [esp + 0x10]
mov eax, ebp
shl eax, 8
mov ebx, ebp
lea ecx, [eax + edx + 0x10]
shl ebx, 4
mov edi, 2
mov dword [esp + 0x18], ecx
mov dword [esp + 0x14], ebx
mov edi, edi
mov ecx, dword [esp + 0x18]
lea eax, [ebx + edi]
shl eax, 4
cmp edi, 1
lea esi, [eax + edx]
lea eax, [esi + 0x10]
jle 0x4165a8
lea ebx, [edi - 1]
mov ebp, dword [ecx]
xor ebp, dword [esi]
add ecx, 4
mov dword [eax], ebp
mov ebp, dword [ecx]
xor ebp, dword [esi + 4]
add eax, 4
mov dword [eax], ebp
mov ebp, dword [ecx + 4]
xor ebp, dword [esi + 8]
add ecx, 4
add eax, 4
mov dword [eax], ebp
mov ebp, dword [esi + 0xc]
xor ebp, dword [ecx + 4]
add ecx, 4
add eax, 4
mov dword [eax], ebp
add eax, 4
add ecx, 4
dec ebx
jne 0x416568
mov ebx, dword [esp + 0x14]
mov ebp, dword [esp + 0x10]
add edi, edi
cmp edi, 0x10
jl 0x416550
inc ebp
cmp ebp, 0x10
mov dword [esp + 0x10], ebp
jl 0x416270
pop edi
pop esi
pop ebp
pop ebx
add esp, 0xc
ret