Function at 0x4d3100
Capabilities:
Encode data using xor

Disassembly:
push ebp
push ebx
push edi
push esi
sub esp, 0x2c
mov ebp, dword [esp + 0x54]
mov edi, dword [esp + 0x48]
mov dword [edi], 0
xor eax, eax
cmp ebp, 0x10
jb 0x4d33fc
lea esi, [ebp - 8]
cmp esi, dword [esp + 0x4c]
ja 0x4d33fc
mov ecx, dword [esp + 0x50]
mov ebx, dword [esp + 0x44]
cmp ebp, 0x10
jne 0x4d3173
xorps xmm0, xmm0
movups xmmword [esp + 8], xmm0
lea eax, [esp + 8]
push dword [esp + 0x40]
push eax
push ecx
call fcn.004cf830
add esp, 0xc
mov eax, dword [esp + 8]
mov ecx, dword [esp + 0xc]
mov dword [esp + 0x1c], ecx
mov dword [esp + 0x18], eax
movsd xmm0, qword [esp + 0x10]
movsd qword [ebx], xmm0
jmp 0x4d3254
xor eax, eax
cmp ebp, 0x18
jl 0x4d33fc
mov edx, ebp
and edx, 7
jne 0x4d33fc
movsd xmm0, qword [ecx]
movsd qword [esp + 8], xmm0
add ecx, 8
mov dword [esp + 0x20], esi
push esi
push ecx
push ebx
call sub.api_ms_win_crt_private_l1_1_0.dll_memmove
add esp, 0xc
shr ebp, 3
lea eax, [ebp*2]
add eax, ebp
lea ebx, [eax + eax]
add ebx, 0xfffffffa
mov eax, 1
mov dword [esp + 0x28], ebp
sub eax, ebp
mov dword [esp + 0x24], eax
mov eax, 5
lea ebp, [esp + 8]
nop
mov dword [esp], eax
mov dword [esp + 4], ebx
mov edi, dword [esp + 0x28]
mov esi, dword [esp + 0x44]
nop
xor byte [esp + 0xf], bl
xor byte [esp + 0xe], bh
mov eax, ebx
shr eax, 0x10
xor byte [esp + 0xd], al
mov eax, ebx
shr eax, 0x18
xor byte [esp + 0xc], al
movsd xmm0, qword [esi + edi*8 - 0x10]
movsd qword [esp + 0x10], xmm0
push dword [esp + 0x40]
push ebp
push ebp
call fcn.004cf830
add esp, 0xc
movsd xmm0, qword [esp + 0x10]
movsd qword [esi + edi*8 - 0x10], xmm0
dec edi
dec ebx
cmp edi, 1
jne 0x4d31e0
mov eax, dword [esp]
dec eax
mov ebx, dword [esp + 4]
add ebx, dword [esp + 0x24]
cmp eax, 6
jb 0x4d31d0
mov eax, dword [esp + 8]
mov ecx, dword [esp + 0xc]
mov dword [esp + 0x1c], ecx
mov dword [esp + 0x18], eax
mov edi, dword [esp + 0x48]
mov ebp, dword [esp + 0x54]
mov esi, dword [esp + 0x20]
lea eax, [esp + 0x18]
push 4
push 0x595fd8
push eax
call sym.fastboot.exe_CRYPTO_memcmp
add esp, 0xc
mov ecx, eax
not eax
dec ecx
and ecx, eax
sar ecx, 0x1f
mov edx, dword [esp + 0x1c]
test edx, edx
cmove ecx, edx
bswap edx
lea eax, [edx - 1]
lea ebx, [ebp - 9]
movd xmm1, ebp
movd xmm2, eax
movdqa xmm3, xmm1
punpckldq xmm3, xmm2
mov dword [esp + 4], ebx
movd xmm4, ebx
movdqa xmm0, xmmword [0x595430]
punpckldq xmm0, xmm4
paddd xmm0, xmm3
pshufd xmm3, xmm4, 0
pshufd xmm2, xmm2, 0
pxor xmm2, xmm3
movdqa xmm3, xmm0
punpckldq xmm3, xmm2
movd xmm2, esi
movaps xmm4, xmmword [0x595440]
movss xmm4, xmm2
movdqa xmm2, xmmword [0x595450]
pxor xmm3, xmm2
xorps xmm4, xmm2
pcmpgtd xmm4, xmm3
pshufd xmm2, xmm4, 0x50
movmskpd ebx, xmm2
xor eax, eax
test bl, 2
cmovne eax, ecx
test bl, 1
je 0x4d33f3
lea edi, [ebp - 0xb]
mov ecx, edi
xor ecx, edx
mov ebx, edi
sub ebx, edx
xor ebx, edi
or ebx, ecx
mov ecx, dword [esp + 0x44]
movzx ecx, byte [ecx + ebp - 0xb]
dec ecx
sar ecx, 0x1f
xor ebx, edi
mov esi, 0xffffffff
cmovs ecx, esi
mov dword [esp], ecx
lea esi, [ebp - 0xa]
mov edi, esi
xor edi, edx
mov ebx, ebp
mov ebp, esi
sub ebp, edx
xor ebp, esi
or ebp, edi
mov ecx, dword [esp + 0x44]
movzx edi, byte [ecx + ebx - 0xa]
dec edi
sar edi, 0x1f
xor ebp, esi
movd esi, xmm0
movd xmm2, dword [ecx + esi]
mov ecx, 0xffffffff
cmovs edi, ecx
mov ecx, dword [esp + 4]
mov ebp, ecx
xor ebp, edx
mov esi, ecx
sub esi, edx
xor esi, ecx
or esi, ebp
mov ebp, dword [esp + 0x44]
movzx ebp, byte [ebp + ebx - 9]
dec ebp
sar ebp, 0x1f
xor esi, ecx
lea esi, [ebx - 0xe]
pshufd xmm1, xmm1, 0x50
paddd xmm1, xmmword [0x595460]
movd xmm3, esi
punpckldq xmm0, xmm3
punpcklqdq xmm0, xmm1
movd xmm1, edx
pshufd xmm1, xmm1, 0
movdqa xmm3, xmm0
pxor xmm3, xmm1
movdqa xmm4, xmm0
psubd xmm4, xmm1
pxor xmm4, xmm0
por xmm4, xmm3
pxor xmm4, xmm0
pxor xmm0, xmm0
punpcklbw xmm2, xmm0
punpcklwd xmm2, xmm0
pcmpeqd xmm0, xmm0
paddd xmm0, xmm2
por xmm0, xmm4
mov ecx, 0xffffffff
cmovs ebp, ecx
movmskps esi, xmm0
xor ebx, ebx
cmp esi, 0xf
sete bl
and ebp, edi
mov edi, dword [esp + 0x48]
and ebp, dword [esp]
and ebp, eax
neg ebx
and ebp, ebx
mov eax, ebp
mov ecx, eax
and ecx, edx
mov dword [edi], ecx
and eax, 1
add esp, 0x2c
pop esi
pop edi
pop ebx
pop ebp
ret