Function at 0x42778c
Capabilities:
Encode data using xor

Disassembly:
sub esp, 8
push ebx
push esi
mov ebx, dword [esp + 0x18]
push edi
push ebp
mov edi, ecx
mov ebp, dword [esp + 0x20]
add ebx, 0x430
add ebp, 4
mov esi, dword [esp + 0x20]
add esi, 0x2c
mov ecx, dword [esp + 0x1c]
push 0x12
push ebx
mov eax, dword [ecx]
mov dword [esp + 0x18], eax
mov ecx, dword [eax + 8]
mov dword [esp + 0x1c], ecx
mov ecx, dword [esp + 0x24]
call dword [esp + 0x1c]
cmp eax, 0x12
je 0x427741
mov eax, 0xffffffff
pop ebp
pop edi
pop esi
pop ebx
add esp, 8
ret 8
lea ecx, [edi + 0x30]
mov eax, dword [ebx]
mov dword [ecx], eax
mov edx, dword [ebx + 4]
mov dword [ecx + 4], edx
mov eax, dword [ebx + 8]
mov dword [ecx + 8], eax
mov edx, dword [ebx + 0xc]
mov dword [ecx + 0xc], edx
mov ax, word [ebx + 0x10]
mov word [ecx + 0x10], ax
xor eax, eax
mov dl, byte [ebx + 2]
mov al, dl
cmp eax, 0xb
ja case.0x427776.2
xor ecx, ecx
mov cl, byte [eax + 0x427990]
jmp dword [ecx*4 + 0x427984]
mov eax, 0xffffffff
pop ebp
pop edi
pop esi
pop ebx
add esp, 8
ret 8
mov al, byte [ebx + 1]
cmp al, 1
jbe 0x4277a2
mov eax, 0xffffffff
pop ebp
pop edi
pop esi
pop ebx
add esp, 8
ret 8
cmp dl, 1
je 0x4277ac
cmp dl, 9
jne 0x4277bf
test al, al
jne 0x4277bf
mov eax, 0xffffffff
pop ebp
pop edi
pop esi
pop ebx
add esp, 8
ret 8
cmp al, 1
jne 0x4277ef
cmp word [ebx + 5], 0x100
jbe 0x4277da
mov eax, 0xffffffff
pop ebp
pop edi
pop esi
pop ebx
add esp, 8
ret 8
cmp byte [ebx + 7], 0x18
je 0x4277ef
mov eax, 0xffffffff
pop ebp
pop edi
pop esi
pop ebx
add esp, 8
ret 8
cmp byte [edi + 0x32], 9
mov dword [edi + 0x14], 0
sbb eax, eax
inc eax
mov dword [edi + 0x20], eax
test byte [ebx + 0x11], 0x20
jne 0x42780d
mov dword [edi + 0x14], 1
mov dword [edi + 0x24], 0
test byte [ebx + 0x11], 0x10
je 0x427821
mov dword [edi + 0x24], 1
mov eax, dword [esp + 0x10]
push 1
mov ecx, dword [esp + 0x20]
mov edi, dword [eax + 0x10]
xor eax, eax
mov al, byte [ebx]
push eax
call edi
mov ecx, dword [esp + 0x20]
mov dword [ecx + 0x42c], 0
mov al, byte [ebx + 2]
cmp al, 1
je 0x427872
cmp al, 9
je 0x427872
movzx ax, byte [ebx + 7]
imul ax, word [ebx + 5]
test ax, ax
je 0x427902
mov ecx, dword [esp + 0x1c]
push 1
movzx eax, ax
push eax
call edi
jmp 0x427902
xor eax, eax
mov ax, word [ebx + 5]
lea ecx, [eax + eax*2]
push ecx
call fcn.00409a50
mov dword [esp + 0x14], eax
add esp, 4
xor eax, eax
mov edx, dword [esp + 0x10]
mov ax, word [ebx + 5]
mov edi, esi
lea ecx, [eax + eax*2]
push ecx
push edx
mov ecx, dword [esp + 0x24]
call dword [esp + 0x1c]
xor eax, eax
mov ecx, 0x100
rep stosd dword es:[edi], eax
mov ax, word [ebx + 5]
mov ecx, dword [esp + 0x10]
push eax
push ecx
push esi
call fcn.00401cd0
mov ecx, dword [esp + 0x2c]
add esp, 0xc
xor edx, edx
mov dword [ecx + 0x42c], 1
cmp word [ebx + 5], dx
jbe 0x4278f5
mov cl, byte [esi + 2]
add esi, 4
inc edx
xor cl, byte [esi - 4]
mov byte [esi - 4], cl
mov al, byte [esi - 2]
xor al, cl
mov byte [esi - 2], al
xor byte [esi - 4], al
xor eax, eax
mov ax, word [ebx + 5]
cmp eax, edx
ja 0x4278d3
mov eax, dword [esp + 0x10]
push eax
call fcn.00409a70
add esp, 4
xor eax, eax
mov al, byte [ebx + 0x10]
sub eax, 8
cmp eax, 0x18
ja case.0x427917.12
xor ecx, ecx
mov cl, byte [eax + 0x4279b0]
jmp dword [ecx*4 + 0x42799c]
mov eax, 0xffffffff
pop ebp
pop edi
pop esi
pop ebx
add esp, 8
ret 8
mov esi, 0xc77240
jmp 0x427947
mov esi, 0xc77258
jmp 0x427947
mov esi, 0xc77210
jmp 0x427947
mov esi, 0xc77228
lea edi, [ebp + 0x10]
mov ecx, 6
rep movsd dword es:[edi], dword [esi]
xor eax, eax
xor ecx, ecx
mov ax, word [ebx + 0xc]
mov dword [ebp + 4], eax
mov eax, dword [ebp + 0x20]
mov cx, word [ebx + 0xc]
inc eax
shr eax, 3
imul eax, ecx
mov dword [ebp + 0xc], eax
xor eax, eax
mov ax, word [ebx + 0xe]
mov dword [ebp + 8], eax
xor eax, eax
pop ebp
pop edi
pop esi
pop ebx
add esp, 8
ret 8