Function at 0x4d9cdb
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x30
push ebx
mov ebx, dword [ebp + 8]
xor ecx, ecx
push esi
mov esi, dword [ebp + 0x14]
push edi
mov eax, dword [ebx + 0x170]
mov dword [ebp - 0x20], eax
mov eax, dword [ebx + 0x174]
mov dword [ebp - 0x1c], eax
mov eax, esi
add eax, dword [ebx + 0x38]
adc ecx, dword [ebx + 0x3c]
cmp ecx, 0xf
ja 0x4da04c
jb 0x4d9d1a
cmp eax, 0xffffffe0
ja 0x4da04c
cmp dword [ebx + 0x16c], 0
mov edx, dword [ebx + 0x168]
mov dword [ebx + 0x3c], ecx
lea ecx, [ebx + 0x40]
mov dword [ebx + 0x38], eax
mov dword [ebp - 0xc], edx
mov dword [ebp - 0x18], ecx
je 0x4d9d8a
test esi, esi
jne 0x4d9d55
lea eax, [ebx + 0x60]
push eax
push ecx
call fcn.004daa77
and dword [ebx + 0x16c], esi
pop ecx
pop ecx
xor eax, eax
jmp 0x4da04f
lea eax, [ebx + 0x178]
mov esi, ecx
mov edi, eax
mov dword [ebp - 0x28], eax
xor eax, eax
push 0x10
pop edx
movsd dword es:[edi], dword [esi]
mov dword [ebp - 0xc], edx
mov dword [ebx + 0x16c], eax
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
mov esi, dword [ebp + 0x14]
lea edi, [ebx + 0x178]
mov dword [ecx], eax
mov dword [ecx + 4], eax
mov dword [ebx + 0x48], eax
mov dword [ebx + 0x4c], eax
jmp 0x4d9d96
lea edi, [ebx + 0x178]
mov dword [ebp - 0x18], ecx
mov dword [ebp - 0x28], edi
movzx ecx, byte [ebx + 0xc]
movzx eax, byte [ebx + 0xd]
shl ecx, 8
or ecx, eax
movzx eax, byte [ebx + 0xe]
shl ecx, 8
or ecx, eax
movzx eax, byte [ebx + 0xf]
shl ecx, 8
or ecx, eax
mov eax, edx
mov dword [ebp - 8], ecx
and eax, 0xf
mov ecx, dword [ebp + 0xc]
mov dword [ebp - 0x10], eax
mov dword [ebp - 4], ecx
je 0x4d9e46
mov eax, edi
mov edi, dword [ebp + 0x10]
jmp 0x4d9dd5
lea eax, [ebx + 0x178]
mov dword [ebp - 0xc], eax
lea eax, [ebx + 0x10]
mov dword [ebp - 0x14], eax
test esi, esi
je 0x4d9e13
mov esi, dword [ebp - 0x10]
mov al, byte [eax + esi]
lea esi, [ebx + 0x178]
xor al, byte [ecx]
mov byte [edi], al
mov byte [esi + edx], al
inc edx
mov eax, dword [ebp - 0x10]
inc edi
mov dword [ebp - 0xc], esi
inc ecx
mov esi, dword [ebp + 0x14]
dec esi
mov dword [ebp - 4], ecx
inc eax
mov dword [ebp + 0x14], esi
and eax, 0xf
mov dword [ebp - 0x10], eax
jne 0x4d9dcf
jmp 0x4d9e19
mov dword [ebp - 0x14], eax
mov eax, dword [ebp - 0x10]
test eax, eax
jne 0x4d9e3b
push edx
push dword [ebp - 0xc]
lea ecx, [ebx + 0x60]
lea eax, [ebx + 0x40]
push ecx
push eax
call fcn.004da85a
mov eax, dword [ebp - 0x14]
add esp, 0x10
xor edx, edx
mov dword [ebp - 0xc], edx
jmp 0x4d9e4f
mov dword [ebx + 0x168], edx
jmp 0x4d9d4e
mov edi, dword [ebp + 0x10]
lea eax, [ebx + 0x10]
mov dword [ebp - 0x14], eax
mov dword [ebp - 0x10], eax
cmp esi, 0x10
jb 0x4d9e7f
mov dword [ebp - 0x10], eax
test edx, edx
je 0x4d9e7f
push edx
lea eax, [ebx + 0x178]
push eax
lea eax, [ebx + 0x60]
push eax
push dword [ebp - 0x18]
call fcn.004da85a
mov eax, dword [ebp - 0x14]
add esp, 0x10
and dword [ebp - 0xc], 0
mov dword [ebp - 0x10], eax
mov eax, 0xc00
mov dword [ebp - 0x24], eax
cmp esi, eax
jb 0x4d9f42
mov eax, esi
lea ecx, [ebx + 0x10]
xor edx, edx
mov dword [ebp - 0x2c], ecx
div dword [ebp - 0x24]
mov dword [ebp - 0x24], eax
mov esi, dword [ebp - 4]
mov dword [ebp - 0x14], 0xc0
push dword [ebp - 0x1c]
push ecx
push ebx
call dword [ebp - 0x20]
mov ecx, dword [ebp - 8]
add esp, 0xc
mov edx, dword [ebp - 0x2c]
inc ecx
mov eax, ecx
mov byte [ebx + 0xf], cl
shr eax, 0x18
mov byte [ebx + 0xc], al
mov eax, ecx
shr eax, 0x10
mov byte [ebx + 0xd], al
mov eax, ecx
shr eax, 8
mov byte [ebx + 0xe], al
mov ebx, esi
push 4
mov dword [ebp - 8], ecx
sub ebx, edi
mov ecx, edi
pop esi
mov eax, dword [ebx + ecx]
xor eax, dword [edx]
lea edx, [edx + 4]
mov dword [ecx], eax
lea ecx, [ecx + 4]
sub esi, 1
jne 0x4d9ee2
mov esi, dword [ebp - 4]
add edi, 0x10
mov ebx, dword [ebp + 8]
add esi, 0x10
sub dword [ebp - 0x14], 1
mov dword [ebp - 4], esi
lea ecx, [ebx + 0x10]
jne 0x4d9ea9
mov eax, 0xc00
push eax
lea eax, [edi - 0xc00]
push eax
lea eax, [ebx + 0x60]
push eax
push dword [ebp - 0x18]
call fcn.004da85a
mov esi, dword [ebp + 0x14]
lea ecx, [ebx + 0x10]
mov eax, 0xc00
add esp, 0x10
sub esi, eax
sub dword [ebp - 0x24], 1
mov dword [ebp + 0x14], esi
jne 0x4d9e9f
mov ecx, esi
and ecx, 0xfffffff0
mov dword [ebp - 0x30], ecx
je 0x4d9fe3
cmp esi, 0x10
jb 0x4d9fce
mov eax, esi
lea ecx, [ebx + 0x10]
shr eax, 4
mov dword [ebp - 0x2c], ecx
mov dword [ebp - 0x24], eax
push dword [ebp - 0x1c]
push ecx
push ebx
call dword [ebp - 0x20]
mov ecx, dword [ebp - 8]
add esp, 0xc
inc ecx
mov edx, edi
mov eax, ecx
mov byte [ebx + 0xf], cl
shr eax, 0x18
mov byte [ebx + 0xc], al
mov eax, ecx
shr eax, 0x10
mov byte [ebx + 0xd], al
mov eax, ecx
mov dword [ebp - 8], ecx
mov ecx, dword [ebp - 4]
shr eax, 8
sub ecx, edi
push 4
mov byte [ebx + 0xe], al
mov ebx, dword [ebp - 0x2c]
pop esi
mov eax, dword [edx + ecx]
xor eax, dword [ebx]
lea ebx, [ebx + 4]
mov dword [edx], eax
lea edx, [edx + 4]
sub esi, 1
jne 0x4d9f9d
mov esi, dword [ebp + 0x14]
add edi, 0x10
mov ebx, dword [ebp + 8]
sub esi, 0x10
add dword [ebp - 4], 0x10
sub dword [ebp - 0x24], 1
mov dword [ebp + 0x14], esi
lea ecx, [ebx + 0x10]
jne 0x4d9f63
mov ecx, dword [ebp - 0x30]
push ecx
mov eax, edi
sub eax, ecx
push eax
lea eax, [ebx + 0x60]
push eax
push dword [ebp - 0x18]
call fcn.004da85a
add esp, 0x10
test esi, esi
je 0x4da03e
push dword [ebp - 0x1c]
push dword [ebp - 0x10]
push ebx
call dword [ebp - 0x20]
mov ecx, dword [ebp - 8]
add esp, 0xc
mov edx, dword [ebp - 0x10]
inc ecx
mov eax, ecx
mov byte [ebx + 0xf], cl
shr eax, 0x18
mov byte [ebx + 0xc], al
mov eax, ecx
shr eax, 0x10
mov byte [ebx + 0xd], al
mov eax, ecx
mov ecx, dword [ebp - 0xc]
shr eax, 8
mov byte [ebx + 0xe], al
mov ebx, dword [ebp - 4]
sub ebx, edi
mov dword [ebp - 4], ebx
mov al, byte [ebx + edi]
xor al, byte [edx]
mov ebx, dword [ebp - 0x28]
mov byte [edi], al
mov byte [ebx + ecx], al
inc ecx
mov ebx, dword [ebp - 4]
inc edx
inc edi
sub esi, 1
jne 0x4da021
mov ebx, dword [ebp + 8]
jmp 0x4da041
mov ecx, dword [ebp - 0xc]
mov dword [ebx + 0x168], ecx
jmp 0x4d9d4e
or eax, 0xffffffff
pop edi
pop esi
pop ebx
leave
ret