Function at 0x49bb80
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
mov ecx, dword [ebp + 8]
xor edx, edx
mov dword [ebp - 4], edx
push esi
test ecx, ecx
je 0x49bd8d
mov esi, dword [ecx + 0x9c]
test esi, esi
je 0x49bd8d
cmp dword [esi], edx
jne 0x49bbb1
lea eax, [edx - 0x64]
pop esi
mov esp, ebp
pop ebp
ret
mov ecx, dword [ebp + 0x10]
test ecx, ecx
jne 0x49bbbf
xor eax, eax
pop esi
mov esp, ebp
pop ebp
ret
mov eax, dword [ebp + 0xc]
mov dword [esi + 0x10], eax
mov eax, dword [esi + 0x5c]
mov dword [esi + 0x14], ecx
cmp ecx, eax
jbe 0x49bbd4
mov dword [esi + 0x14], eax
mov ecx, eax
push ebx
push edi
test ecx, ecx
je 0x49bd7a
nop
mov edi, dword [esi + 8]
test edi, edi
jne 0x49bcb6
mov eax, dword [esi + 0x58]
test eax, eax
je 0x49bcb6
mov edi, 0x8000
cmp eax, edi
push 0
cmovb edi, eax
mov eax, dword [esi + 0x88]
add eax, dword [esi + 0x3c]
push eax
push dword [esi + 0x80]
mov eax, dword [esi + 0x70]
push dword [esi + 0x7c]
call eax
add esp, 0x10
test eax, eax
jne 0x49bd83
mov eax, dword [esi + 0x64]
push edi
push dword [esi]
push dword [esi + 0x80]
push dword [esi + 0x7c]
call eax
add esp, 0x10
cmp eax, edi
jne 0x49bd83
mov ecx, dword [ebp + 8]
cmp dword [ecx + 0xa0], 0
je 0x49bca5
xor ebx, ebx
test edi, edi
je 0x49bca5
lea eax, [ecx + 0xa4]
mov dword [ebp - 8], eax
nop dword [eax]
mov edx, dword [ecx + 0xac]
mov ecx, dword [esi]
and edx, 0xfffd
or edx, 2
mov eax, edx
xor eax, 1
imul eax, edx
shr eax, 8
xor byte [ecx + ebx], al
movsx eax, byte [ecx + ebx]
push eax
mov eax, dword [ebp + 8]
push dword [eax + 0xb0]
push dword [ebp - 8]
call fcn.0049c4b0
mov ecx, dword [esi]
add esp, 0xc
mov byte [ebx + ecx], al
inc ebx
mov ecx, dword [ebp + 8]
cmp ebx, edi
jb 0x49bc60
add dword [esi + 0x3c], edi
mov eax, dword [esi]
sub dword [esi + 0x58], edi
mov edx, dword [ebp - 4]
mov dword [esi + 4], eax
mov dword [esi + 8], edi
cmp dword [esi + 0x84], 0
je 0x49bd13
cmp dword [esi + 0x8c], 0
jne 0x49bd13
mov edi, dword [esi + 0x18]
lea eax, [esi + 4]
mov ebx, dword [esi + 0x10]
push 2
push eax
call fcn.004a8800
mov dword [ebp - 0xc], eax
mov eax, dword [esi + 0x18]
sub eax, edi
push eax
push ebx
push dword [esi + 0x50]
mov dword [ebp - 8], eax
call fcn.004aa3b0
mov edx, dword [ebp - 4]
add esp, 0x14
mov dword [esi + 0x50], eax
mov eax, dword [ebp - 8]
add edx, eax
sub dword [esi + 0x5c], eax
mov eax, dword [ebp - 0xc]
mov dword [ebp - 4], edx
cmp eax, 1
je 0x49bd7a
test eax, eax
jne 0x49bd7c
mov eax, dword [esi + 0x14]
jmp 0x49bd72
test edi, edi
jne 0x49bd1c
cmp dword [esi + 0x58], edi
je 0x49bd7a
mov ebx, dword [esi + 0x14]
cmp ebx, edi
cmovae ebx, edi
xor edx, edx
test ebx, ebx
je 0x49bd41
nop word [eax + eax]
mov eax, dword [esi + 4]
mov ecx, dword [esi + 0x10]
mov al, byte [edx + eax]
mov byte [edx + ecx], al
inc edx
cmp edx, ebx
jb 0x49bd30
push ebx
push dword [esi + 0x10]
push dword [esi + 0x50]
call fcn.004aa3b0
mov edx, dword [ebp - 4]
add esp, 0xc
sub dword [esi + 0x5c], ebx
sub dword [esi + 8], ebx
add dword [esi + 0x10], ebx
add dword [esi + 4], ebx
add dword [esi + 0x18], ebx
mov dword [esi + 0x50], eax
mov eax, dword [esi + 0x14]
sub eax, ebx
add edx, ebx
mov dword [esi + 0x14], eax
mov dword [ebp - 4], edx
test eax, eax
jne 0x49bbe0
mov eax, edx
pop edi
pop ebx
pop esi
mov esp, ebp
pop ebp
ret
pop edi
pop ebx
or eax, 0xffffffff
pop esi
mov esp, ebp
pop ebp
ret
mov eax, 0xffffff9a
pop esi
mov esp, ebp
pop ebp
ret