Function at 0x420400
Capabilities:
Encode data using xor

Disassembly:
push ebp
push ebx
push edi
push esi
sub esp, 0x468
xor ebx, ebx
cmp byte [esp + 0x480], 0
jne 0x4206d9
mov esi, dword [esp + 0x488]
mov ebp, dword [esp + 0x47c]
mov dword [esp + 8], 0
mov dword [esp + 0xc], 0
mov dword [esp + 0x10], 0x81ec81e0
mov dword [esp + 0x14], 0x812181d4
mov dword [esp + 0x18], 0x812a8121
mov dword [esp + 0x1c], 0x81ea81d1
mov dword [esp + 0x20], 0x816881eb
lea eax, [ebx + 0x5b47]
xor ax, word [esp + ebx*2 + 0x10]
add eax, 0x25c8
mov word [esp + ebx*2 + 0x10], ax
inc ebx
cmp ebx, 0xa
jne 0x420460
lea eax, [esp + 0x10]
lea ecx, [esp + 8]
push eax
call fcn.00438440
push 0xebc73df8
push dword [esp + 0xc]
call fcn.0043a3b0
add esp, 8
mov ecx, esp
push ecx
push 0x43d598
push 1
push 0
push 0x43d5a8
call eax
test eax, eax
js 0x420515
mov eax, dword [esp]
mov ecx, dword [eax]
lea edx, [esp + 4]
push edx
push 0x43d5b8
push eax
call dword [ecx]
test eax, eax
js 0x42051c
mov ebx, 0xfffffffe
nop
nop
nop
nop
cmp word [ebp + ebx + 2], 0
lea ebx, [ebx + 2]
jne 0x4204d0
mov edi, dword [esi + 8]
mov eax, 0xfffffffe
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
cmp word [edi + eax + 2], 0
lea eax, [eax + 2]
jne 0x4204f0
sar ebx, 1
sar eax, 1
inc eax
mov ecx, eax
and ecx, ebx
xor eax, ebx
lea edx, [eax + ecx*2]
inc edx
test edx, edx
jns 0x420523
mov eax, 0xffffffff
jmp 0x42052d
xor ebx, ebx
jmp 0x4206d9
xor ebx, ebx
jmp 0x4206d0
lea eax, [eax + ecx*2]
lea eax, [eax*2 + 2]
push eax
call fcn.00408130
add esp, 4
mov esi, eax
movzx ecx, word [edi]
test cx, cx
je 0x420561
add edi, 2
mov eax, esi
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
mov word [eax], cx
add eax, 2
movzx ecx, word [edi]
add edi, 2
test cx, cx
jne 0x420550
mov word [eax], 0x5c
add eax, 2
movzx ecx, word [ebp]
test cx, cx
je 0x420591
lea edx, [ebp + 2]
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
mov word [eax], cx
add eax, 2
movzx ecx, word [edx]
add edx, 2
test cx, cx
jne 0x420580
mov word [eax], 0
mov eax, dword [esp + 4]
mov ecx, dword [eax]
push 0
push esi
push eax
call dword [ecx + 0x14]
test eax, eax
js 0x42060e
mov eax, dword [esp]
mov ecx, dword [eax]
push 1
push 0
push eax
call dword [ecx + 0x4c]
test eax, eax
js 0x42060e
mov eax, dword [esp]
mov ecx, dword [eax]
lea edi, [esp + 0x260]
push 1
lea edx, [esp + 0x14]
push edx
push 0x104
push edi
push eax
call dword [ecx + 0xc]
test eax, eax
js 0x42060e
mov eax, dword [esp + 0x488]
mov edi, dword [eax + 4]
mov eax, 0xfffffffe
nop
nop
nop
nop
nop
nop
nop
nop
cmp word [edi + eax + 2], 0
lea eax, [eax + 2]
jne 0x4205f0
sar eax, 1
lea ecx, [ebx + eax]
add ecx, 2
test ecx, ecx
jns 0x420615
mov eax, 0xffffffff
jmp 0x42061e
xor ebx, ebx
jmp 0x4206bd
add ebx, eax
lea eax, [ebx*2 + 4]
push eax
call fcn.00408130
add esp, 4
mov ebx, eax
movzx ecx, word [edi]
test cx, cx
je 0x420651
add edi, 2
mov eax, ebx
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
mov word [eax], cx
add eax, 2
movzx ecx, word [edi]
add edi, 2
test cx, cx
jne 0x420640
mov word [eax], 0x2f
add eax, 2
movzx ecx, word [ebp]
test cx, cx
je 0x420684
add ebp, 2
lea edx, [esp + 0x260]
nop
nop
nop
nop
mov word [eax], cx
add eax, 2
movzx ecx, word [ebp]
add ebp, 2
test cx, cx
jne 0x420670
jmp 0x42068b
lea edx, [esp + 0x260]
mov word [eax], 0
mov ecx, dword [esp + 0x488]
mov eax, dword [ecx + 0x14]
dec eax
push 1
push eax
push dword [ecx + 0x10]
push dword [ecx + 0xc]
push edx
push ebx
push dword [ecx]
call fcn.0041fa70
add esp, 0x1c
mov ecx, ebx
mov ebx, eax
push ecx
call fcn.00408140
add esp, 4
mov eax, dword [esp + 4]
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
push esi
call fcn.00408140
add esp, 4
mov eax, dword [esp]
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
mov eax, ebx
add esp, 0x468
pop esi
pop edi
pop ebx
pop ebp
ret 0x10