Function at 0x4223a0
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
and esp, 0xfffffff8
sub esp, 0x148
cmp byte [ebp + 0x18], 0
je 0x422447
mov edi, dword [ebp + 0x10]
mov esi, dword [ebp + 8]
lea ebx, [esp + 0x20]
push 0x120
push 0
push ebx
call fcn.0040c720
add esp, 0xc
mov ecx, esi
push 0
push 0
push 0x120
push ebx
push edi
push dword [ebp + 0xc]
call fcn.0043fd10
xor ecx, ecx
test eax, eax
js 0x422913
mov dword [esp + 4], 0xe2e9fcf6
mov byte [esp + 8], 0x58
mov word [esp + 9], 0
mov byte [esp + 0xb], 0
nop
nop
nop
nop
nop
mov eax, ecx
add al, 0xef
xor al, byte [esp + ecx + 4]
add al, 0x55
mov byte [esp + ecx + 4], al
inc ecx
cmp ecx, 8
jne 0x422410
cmp byte [esp + 0x3f], 0
js 0x42244e
lea eax, [esp + 0x28]
lea ecx, [esp + 4]
push eax
push ecx
push dword [ebp + 0x14]
call fcn.00405b10
add esp, 0xc
mov al, 1
mov dword [esp], eax
jmp 0x4224a9
xor ecx, ecx
jmp 0x422913
mov ebx, dword [esp + 0x28]
mov esi, dword [esp + 0x2c]
mov eax, ebx
or eax, esi
je 0x4224a2
mov edi, dword [esp + 0x30]
inc edi
push edi
call fcn.0040c510
add esp, 4
mov ecx, dword [ebp + 8]
push 0
push 0
push edi
mov edi, eax
push eax
push esi
push ebx
call fcn.0043fd10
test eax, eax
setns bl
js 0x422494
lea eax, [esp + 4]
push edi
push eax
push dword [ebp + 0x14]
call fcn.00405b10
add esp, 0xc
mov dword [esp], ebx
push edi
call fcn.0040c520
add esp, 4
jmp 0x4224a9
mov dword [esp], 0
mov dword [esp + 4], 0xe2ee14e6
mov dword [esp + 8], 0x6713
mov byte [esp + 0xc], 0
lea eax, [esp + 4]
xor ecx, ecx
xor edx, edx
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
mov edi, ecx
and edi, 0x76976a2a
mov esi, edx
xor esi, 0x44b44aea
sub esi, edi
movzx edi, byte [eax]
inc esi
xor esi, edi
mov edi, esi
and edi, 1
xor esi, 1
lea ebx, [esi + edi*2]
add ebx, 0x1a7b4c16
mov esi, ebx
xor esi, 0xae
and ebx, 0x51
add ebx, ebx
sub ebx, esi
mov byte [eax], bl
inc eax
dec edx
add ecx, 0xfffffffe
cmp edx, 0xfffffff7
jne 0x4224d0
cmp byte [esp + 0x11f], 0
js 0x42253d
lea eax, [esp + 0x108]
lea ecx, [esp + 4]
push eax
push ecx
push dword [ebp + 0x14]
call fcn.00405b10
add esp, 0xc
mov al, 1
mov ebx, dword [esp]
jmp 0x4225a0
mov esi, dword [esp + 0x108]
mov ebx, dword [esp + 0x10c]
mov eax, esi
or eax, ebx
je 0x42267f
mov edi, dword [esp + 0x110]
inc edi
push edi
call fcn.0040c510
add esp, 4
mov ecx, dword [ebp + 8]
push 0
push 0
push edi
mov edi, eax
push eax
push ebx
push esi
call fcn.0043fd10
test eax, eax
setns al
mov esi, eax
js 0x422592
lea eax, [esp + 4]
push edi
push eax
push dword [ebp + 0x14]
call fcn.00405b10
add esp, 0xc
push edi
call fcn.0040c520
add esp, 4
mov ebx, dword [esp]
mov eax, esi
and bl, al
mov dword [esp + 4], 0xf010638
mov dword [esp + 8], 0x633363b
mov byte [esp + 0xc], 0x98
mov dword [esp + 0xd], 0
mov word [esp + 0x11], 0
xor eax, eax
nop
nop
nop
nop
nop
nop
nop
nop
movzx ecx, byte [esp + eax + 4]
mov esi, eax
and esi, 8
xor esi, 0x8c239a58
mov edx, eax
and edx, 7
sub edx, esi
add edx, 0x3da8af3c
mov esi, ecx
and esi, edx
add esi, esi
sub edx, esi
add dl, cl
add dl, 0x8c
mov byte [esp + eax + 4], dl
inc eax
cmp eax, 0xf
jne 0x4225d0
cmp byte [esp + 0x57], 0
js 0x422624
lea eax, [esp + 0x40]
lea ecx, [esp + 4]
push eax
push ecx
push dword [ebp + 0x14]
call fcn.00405b10
add esp, 0xc
mov al, 1
jmp 0x42268b
mov dword [esp], ebx
mov esi, dword [esp + 0x40]
mov ebx, dword [esp + 0x44]
mov eax, esi
or eax, ebx
je 0x422686
mov edi, dword [esp + 0x48]
inc edi
push edi
call fcn.0040c510
add esp, 4
mov ecx, dword [ebp + 8]
push 0
push 0
push edi
mov edi, eax
push eax
push ebx
push esi
call fcn.0043fd10
test eax, eax
setns al
mov esi, eax
js 0x42266f
lea eax, [esp + 4]
push edi
push eax
push dword [ebp + 0x14]
call fcn.00405b10
add esp, 0xc
push edi
call fcn.0040c520
add esp, 4
mov ebx, dword [esp]
mov eax, esi
jmp 0x42268b
xor eax, eax
jmp 0x422538
xor eax, eax
mov ebx, dword [esp]
and bl, al
mov dword [esp], ebx
mov dword [esp + 4], 0x575a6858
mov byte [esp + 8], 0xcc
mov word [esp + 9], 0
mov byte [esp + 0xb], 0
xor ecx, ecx
mov eax, 0xffffffff
mov edx, eax
or edx, 0x38392f32
lea esi, [ecx + edx]
inc esi
mov edx, esi
and edx, 0xfffffffd
mov edi, esi
and edi, 2
or esi, 2
imul esi, edi
xor edi, 2
imul edi, edx
mov edx, ecx
xor edx, 0x38392f32
add edx, esi
add edx, edi
lea esi, [edx + edx]
not esi
add esi, edx
mov ebx, esi
xor ebx, edx
sub ebx, esi
and esi, edx
add ebx, esi
movzx esi, byte [esp + ecx + 4]
xor ebx, edx
not ebx
and ebx, esi
xor ebx, edx
add bl, 6
mov byte [esp + ecx + 4], bl
inc ecx
dec eax
cmp ecx, 8
jne 0x4226b0
cmp byte [esp + 0x6f], 0
js 0x42272a
lea eax, [esp + 0x58]
lea ecx, [esp + 4]
push eax
push ecx
push dword [ebp + 0x14]
call fcn.00405b10
add esp, 0xc
mov bl, 1
jmp 0x42277d
mov esi, dword [esp + 0x58]
mov ebx, dword [esp + 0x5c]
mov eax, esi
or eax, ebx
je 0x42277b
mov edi, dword [esp + 0x60]
inc edi
push edi
call fcn.0040c510
add esp, 4
mov ecx, dword [ebp + 8]
push 0
push 0
push edi
mov edi, eax
push eax
push ebx
push esi
call fcn.0043fd10
test eax, eax
setns bl
js 0x422770
lea eax, [esp + 4]
push edi
push eax
push dword [ebp + 0x14]
call fcn.00405b10
add esp, 0xc
push edi
call fcn.0040c520
add esp, 4
jmp 0x42277d
xor ebx, ebx
mov eax, dword [esp]
and al, bl
mov dword [esp], eax
mov eax, dword [esp + 0x120]
mov ecx, dword [esp + 0x124]
mov dword [esp + 4], 0xda9e97ab
mov dword [esp + 8], 0xd4e7d4e2
mov dword [esp + 0xc], 0x79d3e3e3
mov dword [esp + 0x10], 0
xor esi, esi
mov edx, 0xffffffff
nop
nop
nop
nop
nop
nop
mov edi, edx
or edi, 0x16f61d3d
add edi, esi
mov ebx, esi
xor ebx, 0x96f61d3d
lea edi, [ebx + edi*2]
add edi, 2
movzx ebx, byte [esp + esi + 4]
xor edi, ebx
mov ebx, edi
and ebx, 1
xor edi, 1
lea ebx, [edi + ebx*2]
add bl, 0xce
mov byte [esp + esi + 4], bl
inc esi
dec edx
cmp esi, 0x10
jne 0x4227c0
mov dword [esp + 0x18], eax
mov dword [esp + 0x1c], ecx
fild qword [esp + 0x18]
sub esp, 0x10
lea esi, [esp + 0x14]
mov dword [esp + 4], esi
mov eax, dword [ebp + 0x14]
mov dword [esp], eax
fstp qword [esp + 8]
call fcn.00405b60
add esp, 0x10
mov edi, eax
movzx eax, byte [esp + 0x78]
mov dword [esp + 4], 0xecfbeefb
mov dword [esp + 8], 0xebd5fae3
mov dword [esp + 0xc], 0x53e7
xor ecx, ecx
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
mov edx, ecx
add dl, 0xef
xor dl, byte [esp + ecx + 4]
add dl, 0x55
mov byte [esp + ecx + 4], dl
inc ecx
cmp ecx, 0xc
jne 0x422850
push eax
push esi
push dword [ebp + 0x14]
call fcn.00405bf0
add esp, 0xc
mov esi, eax
movzx eax, byte [esp + 0x79]
mov dword [esp + 0x14], eax
mov dword [esp + 4], 0x676a95a0
mov dword [esp + 8], 0x67606657
mov word [esp + 0xc], 0xf169
mov dword [esp + 0xe], 0
or esi, edi
xor edi, edi
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
movzx edx, byte [esp + edi + 4]
mov ebx, edi
and ebx, 0xc
mov ecx, edi
and ecx, 2
mov eax, ecx
xor eax, 2
imul eax, ebx
or ebx, 2
imul ebx, ecx
mov ecx, edi
xor ecx, 0xc147dcfe
add ecx, eax
add ecx, ebx
lea ebx, [ecx + ecx]
not ebx
add ebx, ecx
or ecx, edx
not edx
or ebx, edx
and ecx, ebx
add cl, 0xa
mov byte [esp + edi + 4], cl
inc edi
cmp edi, 0xe
jne 0x4228b0
push dword [esp + 0x14]
lea eax, [esp + 8]
push eax
push dword [ebp + 0x14]
call fcn.00405bf0
add esp, 0xc
or esi, eax
sete al
mov ecx, dword [esp]
and cl, al
mov eax, ecx
lea esp, [ebp - 0xc]
pop esi
pop edi
pop ebx
pop ebp
ret