Function at 0x438cb0
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x18
mov eax, ecx
push esi
push edi
mov edi, edx
mov dword [esp + 0x14], eax
mov esi, dword [eax + 0xd4]
mov dh, 0x7f
mov ecx, dword [eax + 0x1c]
mov dl, 0x80
mov dword [esp + 0x10], ecx
mov byte [esp + 0xd], dh
mov byte [esp + 0xe], dh
mov byte [esp + 0xc], dl
mov byte [esp + 0xf], dl
cmp edi, esi
jge 0x438d12
lea eax, [esp + 0xf]
mov edx, esi
push eax
lea eax, [esp + 0x12]
sub edx, edi
push eax
add ecx, edi
call fcn.00438740
mov dh, byte [esp + 0x16]
add esp, 8
mov dl, byte [esp + 0xf]
mov edi, esi
mov byte [esp + 0xd], dh
mov byte [esp + 0xc], dl
mov ecx, dword [ebp + 8]
mov eax, edi
sub eax, esi
add esi, 8
cmp esi, ecx
cmovg esi, ecx
mov dword [esp + 0x18], esi
mov esi, dword [esp + 0x14]
lea esi, [esi + eax*2]
mov eax, dword [esp + 0x18]
add esi, 0x94
cmp edi, eax
jge 0x438d87
sub eax, edi
mov edi, dword [esp + 0x18]
mov dword [esp + 0x18], edi
mov edi, eax
mov dword [esp + 0x14], eax
nop word [eax + eax]
mov dl, byte [esi]
lea esi, [esi + 2]
cmp dl, dh
movzx eax, dl
movzx ecx, dh
cmovl ecx, eax
cmp dl, byte [esp + 0xc]
mov dh, cl
movzx eax, dl
movzx ecx, byte [esp + 0xc]
cmovg ecx, eax
mov dl, cl
mov byte [esp + 0xc], dl
sub edi, 1
jne 0x438d50
mov ecx, dword [ebp + 8]
mov edi, dword [esp + 0x18]
mov byte [esp + 0xd], dh
cmp edi, ecx
jge 0x439019
sub ecx, edi
add edi, dword [esp + 0x10]
cmp byte [0x54e4b5], 0
mov dword [ebp + 8], ecx
je 0x438e7f
movaps xmm1, xmmword [0x4e2de0]
mov edx, ecx
movaps xmm3, xmmword [0x4e2db0]
xorps xmm2, xmm2
shr edx, 4
test edx, edx
je 0x438e39
mov eax, edx
mov esi, edi
shl eax, 4
add edi, eax
mov eax, esi
add esi, 0x10
movups xmm0, xmmword [eax]
pxor xmm0, xmm3
pminub xmm1, xmm0
pmaxub xmm2, xmm0
sub edx, 1
jne 0x438dc8
movaps xmm0, xmm1
punpckhqdq xmm0, xmm1
pminub xmm1, xmm0
movaps xmm0, xmm2
punpckhqdq xmm0, xmm2
pmaxub xmm2, xmm0
pshufd xmm0, xmm1, 0x55
pminub xmm1, xmm0
pshufd xmm0, xmm2, 0x55
pmaxub xmm2, xmm0
movaps xmm0, xmm1
psrad xmm0, 0x10
pminub xmm1, xmm0
movaps xmm0, xmm2
psrad xmm0, 0x10
pmaxub xmm2, xmm0
movaps xmm0, xmm1
psraw xmm0, 8
pminub xmm1, xmm0
movaps xmm0, xmm2
psraw xmm0, 8
pmaxub xmm2, xmm0
test cl, 0xf
je 0x438e69
nop
mov al, byte [edi]
lea edi, [edi + 1]
xor al, 0x80
dec ecx
movsx eax, al
movd xmm0, eax
punpcklbw xmm0, xmm0
punpcklwd xmm0, xmm0
pshufd xmm0, xmm0, 0
pminub xmm1, xmm0
pmaxub xmm2, xmm0
test cl, 0xf
jne 0x438e40
movd eax, xmm1
movd ecx, xmm2
xor al, 0x80
xor cl, 0x80
mov dword [esp + 0x18], ecx
jmp 0x438fd5
mov dl, 0x80
mov byte [esp + 0x10], 0x7f
xor eax, eax
mov dword [esp + 0x14], edx
test ecx, ecx
je 0x438fcd
cmp ecx, 0x20
jb 0x438f74
cmp dword [0x4ed0fc], 2
jl 0x438f74
movaps xmm2, xmmword [0x4e2d50]
mov edx, ecx
movaps xmm1, xmmword [0x4e2db0]
and edx, 0xffffffe0
movaps xmm3, xmm2
movaps xmm4, xmm1
nop dword [eax]
nop word [eax + eax]
movups xmm0, xmmword [edi + eax]
pminsb xmm2, xmm0
pmaxsb xmm1, xmm0
movups xmm0, xmmword [edi + eax + 0x10]
add eax, 0x20
pminsb xmm3, xmm0
pmaxsb xmm4, xmm0
cmp eax, edx
jb 0x438ed0
pmaxsb xmm1, xmm4
movaps xmm0, xmm1
psrldq xmm0, 8
pmaxsb xmm1, xmm0
movups xmm0, xmm1
psrldq xmm0, 4
pmaxsb xmm1, xmm0
movups xmm0, xmm1
psrldq xmm0, 2
pmaxsb xmm1, xmm0
movups xmm0, xmm1
psrldq xmm0, 1
pmaxsb xmm1, xmm0
pminsb xmm2, xmm3
movaps xmm0, xmm2
movd edx, xmm1
psrldq xmm0, 8
pminsb xmm2, xmm0
movups xmm0, xmm2
mov dword [esp + 0x14], edx
psrldq xmm0, 4
pminsb xmm2, xmm0
movups xmm0, xmm2
psrldq xmm0, 2
pminsb xmm2, xmm0
movups xmm0, xmm2
psrldq xmm0, 1
pminsb xmm2, xmm0
movd dword [esp + 0x10], xmm2
cmp eax, ecx
jae 0x438fcd
nop dword [eax + eax]
mov dl, byte [eax + edi]
cmp dl, byte [esp + 0x10]
movzx ecx, dl
mov dword [esp + 0x18], ecx
mov ecx, dword [esp + 0x10]
mov esi, dword [esp + 0x18]
movzx ecx, cl
cmovge esi, ecx
cmp dl, byte [esp + 0x14]
movzx ecx, dl
mov dword [esp + 0x1c], ecx
mov ecx, dword [esp + 0x14]
mov edx, dword [esp + 0x1c]
movzx ecx, cl
cmovle edx, ecx
mov dword [esp + 0x18], esi
inc eax
mov byte [esp + 0x14], dl
mov ecx, esi
mov byte [esp + 0x10], cl
cmp eax, dword [ebp + 8]
jb 0x438f80
mov al, cl
jmp 0x438fd1
mov eax, dword [esp + 0x10]
mov byte [esp + 0x18], dl
mov cl, byte [esp + 0xd]
mov dword [esp + 0x14], eax
cmp byte [esp + 0x14], cl
movzx eax, al
movzx edx, cl
movzx ecx, byte [esp + 0xc]
cmovl edx, eax
mov eax, dword [esp + 0x18]
mov dword [esp + 0x1c], edx
mov edx, dword [esp + 0x18]
cmp dl, byte [esp + 0xc]
mov edx, dword [esp + 0x1c]
movzx eax, al
cmovg ecx, eax
mov eax, dword [ebp + 0xc]
mov byte [eax], dl
mov eax, dword [ebp + 0x10]
mov byte [eax], cl
pop edi
pop esi
mov esp, ebp
pop ebp
ret
mov eax, dword [ebp + 0xc]
pop edi
pop esi
mov byte [eax], dh
mov eax, dword [ebp + 0x10]
mov byte [eax], dl
mov esp, ebp
pop ebp
ret