Function at 0x4d1f80
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
and esp, 0xfffffff0
sub esp, 0x40
mov eax, edx
mov edi, dword [ebp + 8]
pcmpeqd xmm0, xmm0
movdqa xmmword [esp + 0x20], xmm0
mov dword [esp + 0x34], 0xffffffff
mov dword [esp + 0x30], 0xffffffff
mov dword [esp + 0x10], ecx
mov ecx, dword [ecx + 8]
mov edx, edi
mov dword [esp + 0x14], eax
push eax
call fcn.0049f530
add esp, 4
test byte [edi + 0x1c], 0x40
je 0x4d203d
mov eax, dword [esp + 0x10]
mov ecx, dword [eax + 8]
mov edx, dword [ecx]
mov eax, 0x53e0e4
cmp byte [edx + 0x57], 0
jne 0x4d1fea
mov eax, dword [ecx + 0x68]
mov ecx, dword [ecx + 0x6c]
lea ecx, [ecx + ecx*4]
lea eax, [eax + ecx*4]
add eax, 0xffffffec
movzx ecx, byte [eax]
cmp ecx, 0x5f
je 0x4d2036
cmp ecx, 0x60
jne 0x4d203d
mov eax, dword [eax + 0x10]
cmp byte [eax], 0
je 0x4d203d
xor ecx, ecx
mov edx, 0xa
mov esi, eax
jmp 0x4d2020
inc ecx
mov edi, dword [ebp + 8]
lea esi, [eax + ecx]
add edx, 0xc
cmp byte [eax + ecx], 0
je 0x4d203d
mov edi, dword [edi + 4]
movzx ebx, word [edi + edx]
test bl, 0x20
jne 0x4d2011
test bl, 0x40
je 0x4d2010
mov byte [esi], 0x40
jmp 0x4d2010
mov dword [eax + 0xc], 1
movzx edx, word [edi + 0x22]
test dx, dx
jle 0x4d2077
xor eax, eax
mov ecx, 0xa
jmp 0x4d205b
inc eax
movsx esi, dx
add ecx, 0xc
cmp eax, esi
jge 0x4d2077
mov esi, dword [edi + 4]
movzx ebx, word [esi + ecx]
test bl, 0x60
je 0x4d2050
or ebx, 0x80
mov word [esi + ecx], bx
movzx edx, word [edi + 0x22]
jmp 0x4d2050
mov dword [esp + 0x38], edi
mov dword [esp + 0x24], 0x4d5460
mov dword [esp + 0x28], 0
mov dword [esp + 0x2c], 0
mov eax, dword [esp + 0x14]
neg eax
mov ecx, dword [esp + 0x10]
mov dword [ecx + 0x34], eax
movzx eax, word [edi + 0x22]
pcmpeqd xmm7, xmm7
nop dword [eax + eax]
test ax, ax
jle 0x4d23aa
mov dword [esp + 0xc], 0
mov dword [esp + 0x18], 0
xor ebx, ebx
jmp 0x4d20e4
mov dword [esp + 0x18], eax
mov edi, dword [ebp + 8]
inc ebx
movsx eax, word [edi + 0x22]
cmp ebx, eax
jge 0x4d2380
mov edi, dword [edi + 4]
lea esi, [ebx + ebx*2]
movzx eax, word [edi + esi*4 + 0xa]
test al, 0x80
je 0x4d20d4
lea ecx, [edi + esi*4]
add ecx, 0xa
or eax, 0x100
mov dword [esp + 0x1c], ecx
mov word [ecx], ax
mov word [esp + 0x34], 0
movzx eax, word [edi + esi*4 + 8]
test eax, eax
je 0x4d2122
mov ecx, dword [ebp + 8]
cmp byte [ecx + 0x2b], 0
je 0x4d22e9
mov eax, dword [esp + 0x1c]
and byte [eax + 1], 0xfe
lea eax, [edi + esi*4]
test byte [esp + 0x34], 0x80
jne 0x4d20d0
test bx, bx
mov edi, dword [ebp + 8]
js 0x4d22e5
mov ecx, dword [edi + 0x1c]
and ecx, 0x20
je 0x4d22e5
xor edx, edx
mov ecx, dword [edi + 4]
mov dword [esp + 0xc], ecx
test bx, bx
je 0x4d2320
mov ecx, 0
cmp ebx, 0x11
jb 0x4d22b8
mov edi, ebx
and edi, 0xf
mov ecx, 0x10
cmove edi, ecx
mov edx, ebx
sub edx, edi
mov ecx, dword [esp + 0xc]
add ecx, 0xbe
pxor xmm0, xmm0
pxor xmm1, xmm1
nop
movzx esi, word [ecx - 0x60]
movd xmm2, esi
movzx esi, word [ecx - 0x6c]
movd xmm4, esi
punpcklwd xmm4, xmm2
movzx esi, word [ecx - 0x78]
movd xmm2, esi
movzx esi, word [ecx - 0x84]
movd xmm3, esi
punpcklwd xmm3, xmm2
punpckldq xmm3, xmm4
movzx esi, word [ecx - 0x90]
movd xmm2, esi
movzx esi, word [ecx - 0x9c]
movd xmm4, esi
punpcklwd xmm4, xmm2
movzx esi, word [ecx - 0xa8]
movd xmm5, esi
movzx esi, word [ecx - 0xb4]
movd xmm2, esi
punpcklwd xmm2, xmm5
punpckldq xmm2, xmm4
punpcklqdq xmm2, xmm3
movzx esi, word [ecx]
movd xmm3, esi
movzx esi, word [ecx - 0xc]
movd xmm5, esi
punpcklwd xmm5, xmm3
movzx esi, word [ecx - 0x18]
movd xmm3, esi
movzx esi, word [ecx - 0x24]
movd xmm4, esi
punpcklwd xmm4, xmm3
punpckldq xmm4, xmm5
movzx esi, word [ecx - 0x30]
movd xmm3, esi
movzx esi, word [ecx - 0x3c]
movd xmm5, esi
punpcklwd xmm5, xmm3
movzx esi, word [ecx - 0x48]
movd xmm6, esi
movzx esi, word [ecx - 0x54]
movd xmm3, esi
punpcklwd xmm3, xmm6
punpckldq xmm3, xmm5
punpcklqdq xmm3, xmm4
movdqa xmm4, xmmword [0x529710]
pxor xmm2, xmm7
psrlw xmm2, 5
pand xmm2, xmm4
paddw xmm0, xmm2
pxor xmm3, xmm7
psrlw xmm3, 5
pand xmm3, xmm4
paddw xmm1, xmm3
add ecx, 0xc0
add edi, 0x10
cmp ebx, edi
jne 0x4d2190
paddw xmm1, xmm0
pshufd xmm0, xmm1, 0xee
paddw xmm0, xmm1
pshufd xmm1, xmm0, 0x55
paddw xmm1, xmm0
movdqa xmm0, xmm1
psrld xmm0, 0x10
paddw xmm0, xmm1
movd ecx, xmm0
lea esi, [edx + edx*2]
mov edi, dword [esp + 0xc]
lea esi, [edi + esi*4]
add esi, 0xa
nop word cs:[eax + eax]
movzx edi, word [esi]
bt edi, 5
sbb cx, 0xffff
inc edx
add esi, 0xc
cmp ebx, edx
jne 0x4d22d0
jmp 0x4d2322
mov ecx, ebx
jmp 0x4d2345
mov ecx, dword [ebp + 8]
mov ecx, dword [ecx + 0x34]
test ecx, ecx
je 0x4d2122
cmp dword [ecx], eax
jl 0x4d2122
shl eax, 4
mov edx, dword [eax + ecx - 8]
test edx, edx
je 0x4d2122
lea ecx, [esp + 0x20]
call fcn.00499fb0
pcmpeqd xmm7, xmm7
jmp 0x4d2122
xor ecx, ecx
movsx edx, bx
lea edx, [edx + edx*2]
mov esi, dword [esp + 0xc]
test byte [esi + edx*4 + 0xa], 0x20
jne 0x4d2338
mov edi, dword [ebp + 8]
jmp 0x4d2345
mov edx, ebx
sub edx, ecx
mov edi, dword [ebp + 8]
add dx, word [edi + 0x24]
mov ecx, edx
movsx esi, cx
add esi, dword [esp + 0x14]
mov ecx, dword [esp + 0x10]
mov edx, edi
push esi
push eax
call fcn.00496790
add esp, 8
mov eax, dword [esp + 0x1c]
and byte [eax], 0x7f
mov dword [esp + 0xc], 1
pcmpeqd xmm7, xmm7
jmp 0x4d20d7
mov ecx, dword [esp + 0x18]
test ecx, ecx
je 0x4d2393
cmp dword [esp + 0xc], 0
jne 0x4d20b0
test ecx, ecx
je 0x4d23aa
push dword [ecx]
push 0x53162a
push dword [esp + 0x18]
call fcn.00434540
add esp, 0xc
mov eax, dword [esp + 0x10]
mov dword [eax + 0x34], 0
lea esp, [ebp - 0xc]
pop esi
pop edi
pop ebx
pop ebp
ret