Function at 0x41f37f
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x10
and dword [esp + 0xc], 0
cmp dword [esi + 0x48], 0
push ebx
mov ebx, dword [ebp + 8]
push edi
mov dword [esp + 0x10], ebx
je 0x41f3a6
mov dword [esp + 8], 2
jmp 0x41f3b2
mov eax, dword [esi + 0x10]
xor edx, edx
div dword [esi + 8]
mov dword [esp + 8], eax
mov eax, dword [esi + 0x38]
mov ecx, dword [esi + 0x3c]
mov edx, eax
or edx, ecx
je 0x41f3e2
sub eax, dword [esi + 0x40]
sbb ecx, dword [esi + 0x44]
xor edx, edx
cmp edx, ecx
jb 0x41f3e2
ja 0x41f3d1
cmp dword [ebp + 0xc], eax
jbe 0x41f3e2
mov dword [ebp + 0xc], eax
test eax, eax
jne 0x41f3e2
mov eax, 0x80000000
jmp 0x41f6d1
mov ecx, dword [esi + 0xc]
mov edi, dword [esp + 8]
cmp edi, ecx
je 0x41f422
jbe 0x41f414
push 4
pop eax
cmp edi, eax
jbe 0x41f3f8
mov eax, edi
imul eax, dword [ebp + 0xc]
xor edx, edx
div ecx
push eax
call fcn.00401055
mov dword [ebp + 8], eax
test eax, eax
je 0x41f6d1
mov ebx, dword [ebp + 8]
mov eax, edi
imul eax, dword [ebp + 0xc]
xor edx, edx
div dword [esi + 0xc]
mov dword [ebp + 0xc], eax
cmp dword [esi + 0x48], 0
je 0x41f50d
mov eax, dword [ebp + 0xc]
mov dword [esp + 0xc], eax
cmp dword [esi + 0x70], 0
jg 0x41f4c3
mov eax, dword [esi + 0x5c]
mov ecx, dword [esi + 0xa0]
sub ecx, eax
push ecx
mov ecx, dword [esi + 0x58]
add ecx, eax
push ecx
push dword [esi]
call fcn.00405bb6
add dword [esi + 0x5c], eax
mov eax, dword [esi + 0x5c]
cmp eax, dword [esi + 0xa0]
jae 0x41f477
push dword [esi]
call fcn.0040627e
test eax, eax
je 0x41f504
push 0x20
jmp 0x41f479
push 4
cmp dword [esi + 0x70], 0
pop eax
je 0x41f483
or eax, 0x10
push eax
lea eax, [esi + 0x4c]
push eax
push dword [esi + 0x48]
call dword [sym.imp.MSACM32.dll_acmStreamConvert]
test eax, eax
jne 0x41f4fc
mov ecx, dword [esi + 0x60]
test ecx, ecx
jne 0x41f4a1
cmp dword [esi + 0x70], ecx
je 0x41f4fc
sub dword [esi + 0x5c], ecx
mov edx, dword [esi + 0x5c]
je 0x41f4ba
mov eax, dword [esi + 0x58]
push edx
add ecx, eax
push ecx
push eax
call dword [0xea288c]
add esp, 0xc
mov eax, dword [esi + 0x68]
mov dword [esi + 0xa4], eax
mov ebx, dword [esi + 0x70]
cmp dword [esp + 0xc], ebx
jae 0x41f4d0
mov ebx, dword [esp + 0xc]
push ebx
push dword [esi + 0xa4]
push dword [ebp + 8]
call fcn.0042d326
add dword [ebp + 8], ebx
sub dword [esi + 0x70], ebx
add dword [esi + 0xa4], ebx
add esp, 0xc
sub dword [esp + 0xc], ebx
mov ebx, dword [ebp + 8]
je 0x41f504
jmp 0x41f433
mov dword [esp + 0x14], 0x80000000
mov eax, dword [esp + 0xc]
sub dword [ebp + 0xc], eax
jmp 0x41f581
mov edi, dword [esi + 0xac]
test edi, edi
je 0x41f527
push edi
push dword [esi + 0xa8]
push ebx
call fcn.0042d326
add esp, 0xc
mov eax, dword [ebp + 0xc]
sub eax, edi
push eax
lea eax, [edi + ebx]
push eax
push dword [esi]
call fcn.00405bb6
mov ecx, dword [esi + 0x10]
add eax, edi
xor edx, edx
mov dword [ebp + 0xc], eax
div ecx
mov dword [esi + 0xac], edx
test edx, edx
je 0x41f581
cmp dword [esi + 0xa8], 0
jne 0x41f563
push ecx
call fcn.00401055
mov dword [esi + 0xa8], eax
mov eax, dword [esi + 0xac]
sub dword [ebp + 0xc], eax
push eax
mov eax, dword [ebp + 0xc]
add eax, ebx
push eax
push dword [esi + 0xa8]
call fcn.0042d326
add esp, 0xc
cmp dword [ebp + 0xc], 0
je 0x41f6b2
push 3
pop edi
cmp dword [esp + 8], edi
jne 0x41f5d0
mov eax, dword [ebp + 0xc]
xor edx, edx
mov ecx, edi
div ecx
mov ecx, eax
imul ecx, ecx, 3
add ecx, ebx
shl eax, 2
lea edx, [eax + ebx]
mov dword [ebp + 0xc], eax
sub ecx, edi
mov eax, dword [ecx]
and eax, 0xffffff
cmp dword [esi + 0x20], 1
je 0x41f5bf
shl eax, 8
sub edx, 4
mov dword [edx], eax
cmp edx, ebx
jne 0x41f5ad
mov dword [esp + 8], 4
cmp dword [esp + 8], 1
jne 0x41f5eb
cmp dword [esi + 0x20], 0
je 0x41f606
mov ecx, dword [ebp + 0xc]
mov eax, ebx
xor byte [eax], 0x80
inc eax
dec ecx
jne 0x41f5e2
jmp 0x41f606
cmp dword [esi + 0x20], 1
jne 0x41f606
mov eax, dword [ebp + 0xc]
xor edx, edx
div dword [esp + 8]
push dword [esp + 8]
push eax
push ebx
push ebx
call fcn.0041f2f0
cmp dword [esi + 4], edi
jne 0x41f65c
cmp dword [esp + 8], 8
jne 0x41f638
cmp dword [esi + 0xc], 4
mov edx, dword [esp + 0x10]
je 0x41f61e
mov edx, ebx
mov ecx, dword [ebp + 0xc]
shr ecx, 3
xor eax, eax
test ecx, ecx
je 0x41f635
fld qword [ebx + eax*8]
fstp dword [edx + eax*4]
inc eax
cmp eax, ecx
jb 0x41f62a
shr dword [ebp + 0xc], 1
mov eax, dword [esi + 0xc]
cmp eax, 4
je 0x41f6b2
push eax
mov eax, dword [ebp + 0xc]
shr eax, 2
push eax
push dword [esp + 0x18]
push ebx
call fcn.0041f100
mov ecx, edi
sub ecx, dword [esi + 0xc]
shr dword [ebp + 0xc], cl
jmp 0x41f6b2
cmp dword [esi + 0xc], 4
jne 0x41f689
mov eax, dword [ebp + 0xc]
xor edx, edx
div dword [esp + 8]
push dword [esp + 8]
mov edi, eax
push edi
push dword [esp + 0x18]
push dword [esp + 0x1c]
call fcn.0041f010
mov eax, edi
shl eax, 2
mov dword [ebp + 0xc], eax
jmp 0x41f6b2
cmp dword [esp + 8], 4
jne 0x41f6b2
mov eax, dword [ebp + 0xc]
mov edx, dword [esp + 0x10]
shr eax, 2
lea edi, [eax + eax]
lea ecx, [ebx + 2]
mov dword [ebp + 0xc], edi
mov di, word [ecx]
mov word [edx], di
add edx, 2
add ecx, 4
dec eax
jne 0x41f6a3
mov eax, dword [esp + 8]
cmp eax, dword [esi + 0xc]
jbe 0x41f6c1
push ebx
call fcn.004010c2
mov ecx, dword [ebp + 0xc]
add dword [esi + 0x40], ecx
mov eax, dword [esp + 0x14]
adc dword [esi + 0x44], 0
or eax, ecx
pop edi
pop ebx
mov esp, ebp
pop ebp
ret 8