Function at 0x4d9a20
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x158
mov eax, dword [0x5b0008]
xor eax, esp
mov dword [esp + 0x154], eax
mov eax, dword [ebp + 8]
mov dword [esp + 0x44], eax
mov eax, dword [ebp + 0xc]
mov dword [esp + 0x4c], eax
push esi
push edi
mov edi, ecx
mov dword [esp + 0x44], 0xf
mov esi, edx
mov dword [esp + 0x50], edi
mov dword [esp + 0x10], esi
mov edx, 1
mov eax, dword [edi + 0x5c]
mov ecx, dword [edi + 4]
mov dword [esp + 0x2c], eax
mov eax, dword [edi + 0x28]
mov dword [esp + 0x30], eax
mov eax, dword [edi + 0x24]
mov dword [esp + 0x18], eax
mov eax, esi
sub eax, ecx
mov dword [esp + 0x20], ecx
mov ecx, dword [edi + 0xb8]
mov dword [esp + 0xc], eax
mov esi, dword [esp + 0xc]
shl edx, cl
mov ecx, dword [edi + 0x10]
sub esi, edx
sub eax, ecx
cmp eax, edx
mov eax, esi
mov esi, dword [esp + 0x10]
cmovbe eax, ecx
cmp dword [edi + 0x18], 0
cmovne eax, ecx
mov ecx, 4
mov dword [esp + 0x38], eax
mov eax, dword [edi + 0xc4]
cmp eax, ecx
cmovb ecx, eax
mov eax, dword [edi + 0x50]
mov dword [esp + 0x48], eax
mov eax, dword [edi + 0x54]
mov dword [esp + 0x28], eax
mov eax, 1
shl eax, cl
cmp dword [edi + 0xdc], 0
mov dword [esp + 0x3c], eax
jne 0x4d9d5c
mov esi, dword [edi + 0x1c]
mov eax, dword [esp + 0xc]
mov edx, dword [esp + 0x18]
sub eax, esi
mov dword [esp + 0x1c], esi
mov ecx, edx
cmp eax, 0x180
jbe 0x4d9c5e
lea eax, [esi + 0x60]
mov dword [esp + 0x14], edx
mov dword [esp + 0x34], eax
cmp esi, eax
jae 0x4d9bb7
mov eax, 0x38
sub eax, edx
mov dword [esp + 0x24], eax
mov eax, dword [esp + 0x20]
add eax, 8
mov dword [esp + 8], eax
nop dword [eax]
push 0xcf1bbcdc
push 0xbf9b0000
push dword [eax + esi + 4]
push dword [eax + esi]
call fcn.00546f20
xor eax, dword [edi + 0x50]
xor edx, dword [edi + 0x54]
mov ecx, dword [esp + 0x24]
call fcn.00519d00
and esi, 7
mov ecx, eax
mov eax, 0
mov edx, dword [edi + esi*4 + 0x2c]
mov dword [edi + esi*4 + 0x2c], ecx
mov esi, edx
shr esi, 4
and esi, 0xffffff0
mov dword [esp + 0x14], edx
mov edx, dword [esp + 0x30]
add edx, esi
movzx ecx, byte [edx]
dec ecx
and ecx, 0xf
cmove eax, dword [esp + 0x44]
add ecx, eax
mov eax, dword [esp + 0x14]
mov byte [edx], cl
mov byte [ecx + edx], al
lea eax, [ecx + esi]
mov ecx, dword [esp + 0x2c]
mov esi, dword [esp + 0x1c]
mov dword [ecx + eax*4], esi
inc esi
mov eax, dword [esp + 8]
mov dword [esp + 0x1c], esi
cmp esi, dword [esp + 0x34]
jb 0x4d9b30
mov eax, dword [edi + 0x24]
mov dword [esp + 0x14], eax
mov esi, dword [esp + 0xc]
mov ecx, dword [esp + 0x10]
add esi, 0xffffffe0
mov eax, dword [esp + 0x20]
inc ecx
add eax, esi
mov dword [esp + 0x1c], esi
mov edx, esi
cmp eax, ecx
mov eax, dword [esp + 0x20]
mov dword [esp + 0x24], edx
jbe 0x4d9bdf
xor ecx, ecx
jmp 0x4d9be4
sub ecx, eax
sub ecx, esi
inc ecx
cmp ecx, 8
mov dword [esp + 8], 8
cmova ecx, dword [esp + 8]
add ecx, esi
mov dword [esp + 8], ecx
cmp esi, ecx
jae 0x4d9c5a
mov esi, dword [esp + 8]
mov ecx, 0x38
sub ecx, dword [esp + 0x14]
mov dword [esp + 0x34], ecx
nop
push 0xcf1bbcdc
push 0xbf9b0000
push dword [edx + eax + 4]
push dword [edx + eax]
call fcn.00546f20
xor eax, dword [edi + 0x50]
xor edx, dword [edi + 0x54]
mov ecx, dword [esp + 0x34]
call fcn.00519d00
mov edx, dword [esp + 0x24]
mov ecx, eax
mov eax, edx
inc edx
and eax, 7
mov dword [esp + 0x24], edx
mov dword [edi + eax*4 + 0x2c], ecx
mov eax, dword [esp + 0x20]
cmp edx, esi
jb 0x4d9c10
mov ecx, dword [edi + 0x24]
mov esi, dword [esp + 0x1c]
jmp 0x4d9c5e
mov ecx, dword [esp + 0x14]
mov eax, dword [edi + 0x5c]
mov edx, dword [edi + 4]
mov dword [esp + 0x14], eax
mov eax, dword [edi + 0x28]
mov dword [esp + 0x34], eax
mov dword [esp + 0x40], edx
cmp esi, dword [esp + 0xc]
jae 0x4d9d15
mov eax, 0x38
sub eax, ecx
mov dword [esp + 8], eax
nop dword [eax + eax]
push 0xcf1bbcdc
push 0xbf9b0000
push dword [edx + esi + 0xc]
push dword [edx + esi + 8]
call fcn.00546f20
xor eax, dword [edi + 0x50]
xor edx, dword [edi + 0x54]
mov ecx, dword [esp + 8]
call fcn.00519d00
and esi, 7
mov ecx, eax
mov eax, 0
mov edx, dword [edi + esi*4 + 0x2c]
mov dword [edi + esi*4 + 0x2c], ecx
mov esi, edx
shr esi, 4
and esi, 0xffffff0
mov dword [esp + 0x24], edx
mov edx, dword [esp + 0x34]
add edx, esi
movzx ecx, byte [edx]
dec ecx
and ecx, 0xf
cmove eax, dword [esp + 0x44]
add ecx, eax
mov eax, dword [esp + 0x24]
mov byte [edx], cl
mov byte [ecx + edx], al
lea eax, [ecx + esi]
mov ecx, dword [esp + 0x14]
mov esi, dword [esp + 0x1c]
mov edx, dword [esp + 0x40]
mov dword [ecx + eax*4], esi
inc esi
mov dword [esp + 0x1c], esi
cmp esi, dword [esp + 0xc]
jb 0x4d9c90
mov eax, dword [esp + 0x10]
mov esi, dword [esp + 0xc]
push 0xcf1bbcdc
push 0xbf9b0000
mov dword [edi + 0x1c], esi
push dword [eax + 0xc]
push dword [eax + 8]
call fcn.00546f20
xor eax, dword [esp + 0x48]
mov ecx, 0x38
xor edx, dword [esp + 0x28]
sub ecx, dword [esp + 0x18]
call fcn.00519d00
mov ecx, eax
mov eax, esi
and eax, 7
mov edx, dword [edi + eax*4 + 0x2c]
mov dword [edi + eax*4 + 0x2c], ecx
jmp 0x4d9d8f
push 0xcf1bbcdc
push 0xbf9b0000
push dword [esi + 4]
push dword [esi]
call fcn.00546f20
xor eax, dword [esp + 0x48]
mov ecx, 0x38
xor edx, dword [esp + 0x28]
sub ecx, dword [esp + 0x18]
call fcn.00519d00
mov edx, eax
mov eax, dword [esp + 0xc]
mov dword [edi + 0x1c], eax
mov eax, dword [esp + 0x2c]
mov ecx, edx
add dword [edi + 0x58], edx
xor edi, edi
shr ecx, 4
and ecx, 0xffffff0
mov dword [esp + 0x28], edx
mov dword [esp + 0x18], 0
lea eax, [eax + ecx*4]
add ecx, dword [esp + 0x30]
mov dword [esp + 0x2c], eax
movsx eax, dl
mov dword [esp + 8], ecx
movzx esi, byte [ecx]
and esi, 0xf
movd xmm0, eax
punpcklbw xmm0, xmm0
punpcklwd xmm0, xmm0
pshufd xmm1, xmm0, 0
movups xmm0, xmmword [ecx]
mov ecx, esi
mov dword [esp + 0x40], esi
neg ecx
pcmpeqb xmm0, xmm1
and ecx, 0xf
pmovmskb edx, xmm0
mov ax, dx
shl ax, cl
mov cx, si
shr dx, cl
or ax, dx
movzx eax, ax
cdq
mov dword [esp + 0x30], edx
mov esi, eax
test edx, edx
jne 0x4d9e0f
test esi, esi
je 0x4d9e65
xor edi, edi
cmp dword [esp + 0x3c], 0
jbe 0x4d9e5f
push edx
push esi
call fcn.004d6c70
add eax, dword [esp + 0x48]
add esp, 8
and eax, 0xf
je 0x4d9e41
mov ecx, dword [esp + 0x2c]
mov eax, dword [ecx + eax*4]
cmp eax, dword [esp + 0x38]
jb 0x4d9e5f
mov dword [esp + edi*4 + 0x58], eax
inc edi
dec dword [esp + 0x3c]
mov edx, dword [esp + 0x30]
mov ecx, esi
add ecx, 0xffffffff
mov eax, edx
adc eax, 0xffffffff
and esi, ecx
and edx, eax
mov dword [esp + 0x30], edx
ja 0x4d9e11
jb 0x4d9e5f
test esi, esi
jne 0x4d9e11
mov dword [esp + 0x18], edi
xor edi, edi
mov edx, dword [esp + 8]
mov esi, 0xf
mov eax, 0
movzx ecx, byte [edx]
dec ecx
and ecx, 0xf
cmove eax, esi
mov esi, dword [esp + 0x2c]
add ecx, eax
mov eax, dword [esp + 0x28]
mov byte [edx], cl
mov byte [ecx + edx], al
mov edx, dword [esp + 0x50]
mov eax, dword [edx + 0x1c]
mov dword [esi + ecx*4], eax
inc dword [edx + 0x1c]
cmp dword [esp + 0x18], 0
jbe 0x4d9f14
mov ecx, dword [esp + 0x10]
mov esi, 3
nop dword [eax]
mov edx, dword [esp + 0x20]
add edx, dword [esp + edi*4 + 0x58]
mov eax, dword [edx + esi - 3]
cmp eax, dword [esi + ecx - 3]
jne 0x4d9ef7
push dword [esp + 0x4c]
call fcn.004d6d00
mov ecx, eax
add esp, 4
cmp ecx, esi
jbe 0x4d9ef3
mov eax, dword [esp + 0xc]
mov esi, ecx
sub eax, dword [esp + edi*4 + 0x58]
mov edx, dword [esp + 0x54]
add eax, 3
mov dword [edx], eax
mov eax, dword [esp + 0x10]
add eax, ecx
cmp eax, dword [esp + 0x4c]
je 0x4d9efe
mov ecx, dword [esp + 0x10]
inc edi
cmp edi, dword [esp + 0x18]
jb 0x4d9eb0
mov eax, esi
pop edi
pop esi
mov ecx, dword [esp + 0x154]
xor ecx, esp
call fcn.00519459
mov esp, ebp
pop ebp
ret
mov ecx, dword [esp + 0x15c]
mov eax, 3
pop edi
pop esi
xor ecx, esp
call fcn.00519459
mov esp, ebp
pop ebp
ret