Function at 0x406a3c
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x2c
push ebx
push esi
push edi
push 0x2000
mov edi, ecx
call fcn.00420ff6
pop ecx
push eax
lea ecx, [ebp - 8]
call fcn.0040538e
mov esi, dword [ebp + 8]
cmp word [esi], 0x23
je 0x406a89
push 3
pop ebx
mov eax, dword [ebp - 4]
push 0xf
push 0x492624
push esi
call fcn.00423a0b
add esp, 0xc
test eax, eax
je 0x406bd2
push 0xb
push 0x49267c
push esi
call fcn.00423a0b
add esp, 0xc
test eax, eax
je 0x406bda
push 0xd
push 0x492644
push esi
call fcn.00423a0b
add esp, 0xc
test eax, eax
je 0x43e6e3
push 0x16
push 0x4925f4
push esi
call fcn.00423a0b
add esp, 0xc
test eax, eax
je 0x43e6ee
push 0xd
push 0x492660
push esi
call fcn.00423a0b
add esp, 0xc
test eax, eax
je 0x43e771
push 8
push 0x49242c
push esi
call fcn.00423a0b
add esp, 0xc
test eax, eax
je 0x43e7b3
push 0xf
push 0x48fb50
push esi
call fcn.00423a0b
add esp, 0xc
test eax, eax
je 0x406b45
push 3
push 0x48fb70
push esi
call fcn.00423a0b
add esp, 0xc
test eax, eax
jne 0x406bd2
xor ebx, ebx
inc ebx
mov dword [ebp + 8], ebx
push ecx
mov ecx, dword [ebp + 0x14]
push esi
call fcn.004059cd
test al, al
je 0x43e820
mov eax, dword [ebp + 0x10]
push esi
inc dword [eax]
call fcn.0040710a
push esi
call fcn.004070bd
push 0xf
push 0x48fb50
push esi
call fcn.00423a0b
add esp, 0xc
test eax, eax
je 0x406be4
push 3
push 0x48fb70
push esi
call fcn.00423a0b
add esp, 0xc
test eax, eax
je 0x406be4
push 0xd
push 0x48fb2c
push esi
call fcn.00423a0b
add esp, 0xc
test eax, eax
je 0x406bbe
push 3
push 0x48fb48
push esi
call fcn.00423a0b
add esp, 0xc
test eax, eax
jne 0x406b4b
mov eax, dword [ebp + 8]
dec eax
mov dword [ebp + 8], eax
test eax, eax
jle 0x406a67
jmp 0x406b4b
xor ebx, ebx
inc ebx
jmp 0x406a67
xor ebx, ebx
inc ebx
mov byte [edi], bl
jmp 0x406a67
inc dword [ebp + 8]
jmp 0x406b4b
and al, 0x18
lea ecx, [ebp - 0x30]
call fcn.004077a8
lea ecx, [ebp - 0x20]
call fcn.00405f2d
jmp 0x406a63
mov eax, dword [ebp - 0xc]
mov ecx, edi
inc ebp
adc cl, bh
in al, 0xc8
push 0x4ba0a8
push eax
jae 0x43e74b
test al, 0xa0
dec ebx
add byte [eax + 0x73], dl
push esi
mov ebp, eax
call 0x5709e911
call 0x5a42109e
pop ebp
mov ecx, dword [ebp + 0x10]
call 0x8b9d2fc7
inc esi
lea ecx, [ebp - 0x68]
call fcn.00404fdc
jmp 0x43e6ce
daa
pop edx
cmp cx, dx
je 0x43e77f
movzx eax, word [ebx]
push 0x22
pop ecx
cmp ax, cx
je 0x43e76d
cmp ax, dx
je 0x43e76d
mov ecx, dword [edi + 4]
push ebx
mov eax, dword [ecx]
call dword [eax + 8]
jmp 0x43e797
push ebx
call 0x5a42109e
pop ebp
push esi
push 0x4ba0a8
jmp 0xc19bec63
invalid
cmp word [ebx], cx
jne 0x43e76d
xor ecx, ecx
mov word [ebx + eax*2 - 2], cx
lea eax, [ebx + 2]
mov ecx, dword [edi + 4]
push eax
mov edx, dword [ecx]
call dword [edx + 8]
push ebx
call 0x5a42109e
pop ebp
jmp 0x406c04
mov eax, dword [edi + 0x1c]
mov ecx, dword [ebp + 0xc]
push 0
in al, dx
or al, 0x6a
add ah, ch
xor al, 0xb0
call fcn.00407a9a
test eax, eax
je 0x43e7cd
inc esi
cmp esi, dword [edi + 0x20]
jb 0x43e7ae
jmp 0x406c04
mov eax, dword [edi + 0x2c]
xor ebx, ebx
inc ebx
mov eax, dword [eax + esi*4]
cmp dword [eax], ebx
jle 0x406a99
push 4
jmp 0xcb406a98
cld
call [ecx + 0x50]
lea eax, [ebp - 0x18]
mov ecx, edi
push eax
call fcn.00406c1e
lea ecx, [ebp - 0x18]
mov bl, al
call fcn.00405a96
lea ecx, [ebp - 0x28]
call fcn.00405a96
test bl, bl
je 0x43e872
jmp 0x406c04
xor ebx, ebx
jmp 0xcb406a99