Function at 0x439040
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
sub esp, 0x18
mov edx, dword [ebp + 0xc]
mov eax, dword [0x458d74]
test eax, eax
jne 0x4390b4
mov eax, dword [0x453380]
lea ecx, [eax + eax]
and ecx, 0xf51419c2
neg ecx
add eax, ecx
add eax, 0x7a8a0ce1
mov ecx, 0x52e46a56
xor ecx, dword [0x453384]
mov dword [0x4533a0], eax
mov dword [0x4533a4], ecx
mov eax, dword [0x453388]
lea ecx, [eax + eax]
and ecx, 0x6b1bb9de
neg ecx
add eax, ecx
add eax, 0xb58ddcef
mov dword [0x4533a8], eax
movsd xmm0, qword [0x45338c]
xorps xmm0, xmmword [0x4469f0]
movlps qword [0x4533ac], xmm0
mov esi, dword [ebp + 8]
mov dword [0x458d74], 1
push eax
sub esp, 0x10
mov eax, esp
sub esp, 0x40
mov edi, esp
sub esp, 0x40
mov ebx, esp
mov ecx, dword [0x4533b0]
mov dword [eax + 0x10], ecx
movaps xmm0, xmmword [0x4533a0]
mov dword [ebp - 0x20], eax
movups xmmword [eax], xmm0
cmp edx, 0x40
mov dword [ebp - 0x1c], ebx
jae 0x4390f3
mov eax, esi
jmp 0x439168
shr edx, 6
mov dword [ebp - 0x14], edx
xor ecx, ecx
mov eax, esi
nop dword [eax]
mov dword [ebp - 0x10], ecx
mov ebx, eax
xor esi, esi
nop word [eax + eax]
movzx eax, byte [ebx + esi]
mov dword [edi + esi], eax
movzx ecx, byte [ebx + esi + 1]
shl ecx, 8
or ecx, eax
mov dword [edi + esi], ecx
movzx eax, byte [ebx + esi + 2]
shl eax, 0x10
or eax, ecx
mov dword [edi + esi], eax
movzx ecx, byte [ebx + esi + 3]
shl ecx, 0x18
or ecx, eax
mov dword [edi + esi], ecx
add esi, 4
cmp esi, 0x40
jne 0x439110
push edi
push dword [ebp - 0x20]
call fcn.00439a00
add esp, 8
mov ecx, dword [ebp - 0x10]
inc ecx
lea eax, [ebx + esi]
cmp ecx, dword [ebp - 0x14]
jne 0x439100
add ebx, esi
mov eax, ebx
mov edx, dword [ebp + 0xc]
mov ebx, dword [ebp - 0x1c]
xorps xmm0, xmm0
movups xmmword [ebx + 0x30], xmm0
movups xmmword [ebx + 0x20], xmm0
movups xmmword [ebx + 0x10], xmm0
movups xmmword [ebx], xmm0
mov ecx, edx
and ecx, 0x3f
mov dword [ebp - 0x18], ecx
je 0x439210
mov ecx, edx
and ecx, 1
xor esi, esi
cmp dword [ebp - 0x18], 1
je 0x4391f7
mov dword [ebp - 0x24], ecx
sub dword [ebp - 0x18], ecx
xor ecx, ecx
xor esi, esi
mov dword [ebp - 0x14], eax
mov ebx, dword [ebp - 0x1c]
nop word cs:[eax + eax]
mov dword [ebp - 0x10], ecx
movzx edi, byte [eax + esi]
mov eax, dword [ebp - 0x10]
mov ecx, eax
and cl, 0x10
shl edi, cl
mov edx, esi
and edx, 0xfffffffc
xor edi, dword [ebx + edx]
mov dword [ebx + edx], edi
mov eax, dword [ebp - 0x14]
movzx eax, byte [eax + esi + 1]
or cl, 8
shl eax, cl
mov ecx, dword [ebp - 0x10]
xor eax, edi
mov dword [ebx + edx], eax
mov eax, dword [ebp - 0x14]
add esi, 2
add ecx, 0x10
cmp dword [ebp - 0x18], esi
jne 0x4391b0
add eax, esi
mov edx, dword [ebp + 0xc]
mov ecx, dword [ebp - 0x24]
test ecx, ecx
mov ebx, dword [ebp - 0x1c]
je 0x439210
movzx eax, byte [eax]
lea ecx, [esi*8]
shl eax, cl
and esi, 0xfffffffc
xor dword [ebx + esi], eax
mov eax, edx
shr eax, 2
mov edx, eax
not edx
or edx, 0xf
mov ecx, dword [ebp + 0xc]
lea ecx, [ecx*8]
mov dword [ebp - 0x10], ecx
and cl, 0x18
or cl, 7
mov esi, 1
shl esi, cl
add edx, eax
xor dword [ebx + edx*4 + 4], esi
mov edx, dword [ebp + 0xc]
mov esi, dword [ebp + 0x10]
mov eax, edx
not eax
test al, 0x38
jne 0x439264
push ebx
push dword [ebp - 0x20]
call fcn.00439a00
mov edx, dword [ebp + 0xc]
add esp, 8
xor eax, eax
mov edi, ebx
mov ecx, 0x10
rep stosd dword es:[edi], eax
mov eax, dword [ebp - 0x10]
mov dword [ebx + 0x38], eax
shr edx, 0x1d
mov dword [ebx + 0x3c], edx
push ebx
mov edi, dword [ebp - 0x20]
push edi
call fcn.00439a00
add esp, 8
mov eax, dword [edi]
mov dword [esi], eax
mov eax, dword [edi + 4]
mov dword [esi + 4], eax
mov eax, dword [edi + 8]
mov dword [esi + 8], eax
mov eax, dword [edi + 0xc]
mov dword [esi + 0xc], eax
mov eax, dword [edi + 0x10]
mov dword [esi + 0x10], eax
lea esp, [ebp - 0xc]
pop esi
pop edi
pop ebx
pop ebp
ret