Function at 0x408c30
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
mov edx, dword [ebp + 8]
push ebx
xor ebx, ebx
mov dword [ebp - 4], ebx
test edx, edx
jne 0x408c4b
lea eax, [ebx - 0x66]
pop ebx
mov esp, ebp
pop ebp
ret
push esi
mov esi, dword [edx + 0x9c]
test esi, esi
jne 0x408c5f
lea eax, [esi - 0x66]
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
cmp dword [esi], ebx
jne 0x408c6e
pop esi
mov eax, 0xffffff9c
pop ebx
mov esp, ebp
pop ebp
ret
mov edx, dword [ebp + 0x10]
test edx, edx
jne 0x408c7d
pop esi
xor eax, eax
pop ebx
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], edx
cmp edx, eax
jbe 0x408c98
cmp dword [esi + 0x8c], ebx
jne 0x408c98
mov dword [esi + 0x14], eax
mov eax, dword [esi + 8]
add eax, dword [esi + 0x58]
cmp edx, eax
jbe 0x408cad
cmp dword [esi + 0x8c], ebx
je 0x408cad
mov dword [esi + 0x14], eax
cmp dword [esi + 0x14], ebx
push edi
jbe 0x408e6d
cmp dword [esi + 8], 0
mov edi, 0xfffffffd
jne 0x408d96
mov eax, dword [esi + 0x58]
test eax, eax
je 0x408d96
mov edi, 0x4000
cmp eax, edi
cmovb edi, eax
mov eax, dword [esi + 0x88]
add eax, dword [esi + 0x3c]
push 0
push eax
push dword [esi + 0x80]
mov eax, dword [esi + 0x70]
push dword [esi + 0x7c]
call eax
add esp, 0x10
test eax, eax
jne 0x408e63
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 0x408e63
mov edx, dword [ebp + 8]
cmp dword [edx + 0xa0], 0
je 0x408d83
xor ebx, ebx
test edi, edi
je 0x408d80
lea ecx, [edx + 0xa4]
mov dword [ebp - 8], ecx
jmp 0x408d40
mov eax, dword [ebp + 8]
mov edx, dword [esi]
push dword [eax + 0xb0]
push ecx
call fcn.00408470
movsx ecx, byte [edx + ebx]
xor eax, ecx
mov byte [edx + ebx], al
movsx eax, al
push eax
mov eax, dword [ebp + 8]
push dword [eax + 0xb0]
push dword [ebp - 8]
call fcn.00409630
mov ecx, dword [esi]
inc ebx
mov byte [ebx + ecx - 1], al
mov ecx, dword [ebp - 8]
add esp, 0x14
cmp ebx, edi
jb 0x408d40
mov ebx, dword [ebp - 4]
add dword [esi + 0x3c], edi
mov eax, dword [esi]
sub dword [esi + 0x58], edi
mov dword [esi + 8], edi
mov dword [esi + 4], eax
mov edi, 0xfffffffd
cmp dword [esi + 0x84], 0
je 0x408e06
cmp dword [esi + 0x8c], 0
jne 0x408e06
mov eax, dword [esi + 0x18]
mov dword [ebp - 8], eax
mov eax, dword [esi + 0x10]
mov dword [ebp - 0xc], eax
lea eax, [esi + 4]
push 2
push eax
call fcn.0040a7b0
mov ebx, eax
add esp, 8
test ebx, ebx
js 0x408dcf
cmp dword [esi + 0x1c], 0
cmovne ebx, edi
mov edi, dword [esi + 0x18]
sub edi, dword [ebp - 8]
push edi
push dword [ebp - 0xc]
push dword [esi + 0x50]
call fcn.0040c060
sub dword [esi + 0x5c], edi
mov dword [esi + 0x50], eax
mov eax, dword [ebp - 4]
add eax, edi
add esp, 0xc
mov dword [ebp - 4], eax
cmp ebx, 1
je 0x408e6f
test ebx, ebx
jne 0x408e6d
cmp dword [esi + 0x14], 0
mov ebx, eax
jmp 0x408cb1
mov edi, dword [esi + 8]
test edi, edi
jne 0x408e12
cmp dword [esi + 0x58], edi
je 0x408e6d
cmp dword [esi + 0x14], edi
cmovb edi, dword [esi + 0x14]
xor edx, edx
test edi, edi
je 0x408e31
nop
mov eax, dword [esi + 4]
mov ecx, dword [esi + 0x10]
mov al, byte [edx + eax]
mov byte [edx + ecx], al
inc edx
cmp edx, edi
jb 0x408e20
push edi
push dword [esi + 0x10]
push dword [esi + 0x50]
call fcn.0040c060
sub dword [esi + 0x5c], edi
sub dword [esi + 8], edi
sub dword [esi + 0x14], edi
add dword [esi + 0x10], edi
add dword [esi + 4], edi
add dword [esi + 0x18], edi
add ebx, edi
add esp, 0xc
mov dword [esi + 0x50], eax
cmp dword [esi + 0x14], 0
mov dword [ebp - 4], ebx
jmp 0x408cb1
pop edi
pop esi
or eax, 0xffffffff
pop ebx
mov esp, ebp
pop ebp
ret
mov eax, ebx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret