Function at 0x4f37f4
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffff004
push eax
add esp, 0xfffff550
push ebx
push esi
push edi
mov dword [ebp - 0x40c], eax
lea edi, [ebp - 0x1112]
mov dword [ebp - 0x1a78], 0
mov dword [ebp - 0x1a74], 0
push ebp
call fcn.004f3410
pop ecx
push ebp
call fcn.004f14d8
pop ecx
push ebp
call fcn.004f1cd8
pop ecx
push ebp
call fcn.004f2f2c
pop ecx
xor eax, eax
mov dword [ebp - 0x1aa8], eax
mov bx, 2
xor esi, esi
mov eax, dword [ebp - 0x40c]
cmp dword [eax + 0x1b0], 3
jg 0x4f3878
push ebp
call fcn.004f34dc
pop ecx
mov dword [ebp - 0x1a98], eax
mov dword [ebp - 0x1a94], edx
jmp 0x4f3b6d
cmp word [ebp - 0x1a7a], 0
je 0x4f3b2f
cmp word [ebp - 0x1a7a], 3
jb 0x4f391f
movzx eax, word [edi]
add eax, 3
mov edx, dword [ebp - 0x40c]
mov edx, dword [edx + 0xba4]
movzx eax, byte [edx + eax - 1]
mov dx, word [ebp - 0x1a8c]
shl edx, 5
xor ax, dx
and ax, 0x7fff
mov word [ebp - 0x1a8c], ax
movzx eax, word [ebp - 0x1a8c]
mov edx, dword [ebp - 0x40c]
mov edx, dword [edx + 0xbac]
mov ax, word [edx + eax*2]
mov dx, word [edi]
and dx, 0x7fff
movzx edx, dx
mov ecx, dword [ebp - 0x40c]
mov ecx, dword [ecx + 0xba8]
mov word [ecx + edx*2], ax
movzx eax, word [ebp - 0x1a8c]
mov edx, dword [ebp - 0x40c]
mov edx, dword [edx + 0xbac]
mov si, word [edx + eax*2]
mov edx, dword [ebp - 0x40c]
mov edx, dword [edx + 0xbac]
mov cx, word [edi]
mov word [edx + eax*2], cx
mov word [ebp - 0x1a8e], bx
mov ax, word [ebp - 0x1a7e]
mov word [ebp - 0x1aa2], ax
mov bx, 2
test si, si
je 0x4f3994
mov ax, word [ebp - 0x1a8e]
cmp ax, word [ebp - 0x1a82]
jae 0x4f3994
movzx eax, word [edi]
movzx edx, si
sub eax, edx
cmp eax, 0x7efa
jg 0x4f3994
push ebp
mov eax, esi
call fcn.004f312c
pop ecx
mov ebx, eax
cmp bx, word [ebp - 0x1a7a]
jbe 0x4f3977
mov bx, word [ebp - 0x1a7a]
cmp bx, 3
jne 0x4f3994
movzx eax, word [edi]
movzx edx, word [ebp - 0x1a7e]
sub eax, edx
cmp eax, 0x1000
jle 0x4f3994
mov bx, 2
cmp word [ebp - 0x1a8e], 3
jb 0x4f3aab
cmp bx, word [ebp - 0x1a8e]
ja 0x4f3aab
push ebp
movzx eax, word [edi]
dec eax
movzx edx, word [ebp - 0x1aa2]
sub eax, edx
movzx edx, word [ebp - 0x1a8e]
sub edx, 3
call fcn.004f1d38
pop ecx
mov dx, word [ebp - 0x1a8e]
dec edx
sub word [ebp - 0x1a7a], dx
sub word [ebp - 0x1a8e], 2
inc word [edi]
movzx edx, word [edi]
add edx, 3
mov ecx, dword [ebp - 0x40c]
mov ecx, dword [ecx + 0xba4]
movzx edx, byte [ecx + edx - 1]
mov cx, word [ebp - 0x1a8c]
shl ecx, 5
xor dx, cx
and dx, 0x7fff
mov word [ebp - 0x1a8c], dx
movzx edx, word [ebp - 0x1a8c]
mov ecx, dword [ebp - 0x40c]
mov ecx, dword [ecx + 0xbac]
mov dx, word [ecx + edx*2]
mov cx, word [edi]
and cx, 0x7fff
movzx ecx, cx
mov ebx, dword [ebp - 0x40c]
mov ebx, dword [ebx + 0xba8]
mov word [ebx + ecx*2], dx
movzx edx, word [ebp - 0x1a8c]
mov ecx, dword [ebp - 0x40c]
mov ecx, dword [ecx + 0xbac]
mov bx, word [edi]
mov word [ecx + edx*2], bx
dec word [ebp - 0x1a8e]
cmp word [ebp - 0x1a8e], 0
jne 0x4f39e4
xor edx, edx
mov dword [ebp - 0x1aa8], edx
mov bx, 2
inc word [edi]
test al, al
je 0x4f3b0f
push ebp
xor eax, eax
call fcn.004f3378
pop ecx
movzx eax, word [edi]
xor edx, edx
mov dword [ebp - 0x1120], eax
mov dword [ebp - 0x111c], edx
jmp 0x4f3b0f
cmp dword [ebp - 0x1aa8], 0
je 0x4f3afb
push ebp
movzx eax, word [edi]
mov edx, dword [ebp - 0x40c]
mov edx, dword [edx + 0xba4]
movzx edx, byte [edx + eax - 1]
xor eax, eax
call fcn.004f1d38
pop ecx
test al, al
je 0x4f3aef
push ebp
xor eax, eax
call fcn.004f3378
pop ecx
movzx eax, word [edi]
xor edx, edx
mov dword [ebp - 0x1120], eax
mov dword [ebp - 0x111c], edx
inc word [edi]
dec word [ebp - 0x1a7a]
jmp 0x4f3b0f
mov dword [ebp - 0x1aa8], 1
inc word [edi]
dec word [ebp - 0x1a7a]
cmp word [ebp - 0x1a7a], 0x106
jae 0x4f3b21
push ebp
call fcn.004f2d78
pop ecx
cmp word [ebp - 0x1a7a], 0
jne 0x4f3886
cmp dword [ebp - 0x1aa8], 0
je 0x4f3b55
push ebp
movzx eax, word [edi]
mov edx, dword [ebp - 0x40c]
mov edx, dword [edx + 0xba4]
movzx edx, byte [edx + eax - 1]
xor eax, eax
call fcn.004f1d38
pop ecx
push ebp
mov eax, 1
call fcn.004f3378
pop ecx
mov dword [ebp - 0x1a98], eax
mov dword [ebp - 0x1a94], edx
mov eax, dword [ebp - 0x1a98]
mov edx, dword [ebp - 0x1a94]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret