Function at 0x40b3b1
Capabilities:
Encode data using xor

Disassembly:
mov edx, dword [esp + 0x18]
mov ecx, dword [esp + 0x10]
push ebx
mov ebx, dword [esp + 0xc]
push ebp
push esi
lea eax, [edx - 0x16b]
add ebx, 0xc58
push edi
mov dword [esp + 0x20], eax
lea ebp, [edx - 0x621]
mov edi, ecx
lea eax, [ecx + 0x2f3]
xor edi, 0xcf8
mov dword [esp + 0x28], eax
mov eax, edi
lea esi, [ecx + 0x25f]
xor eax, 0x7df
add edx, 0xffffd409
cmp ebp, eax
jl 0x40b559
mov esi, dword [esp + 0x24]
xor eax, eax
inc eax
xor ecx, ecx
mov dword [0x976898], eax
mov dword [esi + 8], eax
mov eax, dword [0x93113c]
mov dword [0x9768b0], 0xb
mov dword [eax + 0x20], ecx
mov eax, dword [0x93113c]
mov dword [0x9768d4], ecx
mov dword [0x9768c0], 9
mov dword [eax + 0x4c], ecx
xor eax, eax
mov dword [0x9768f0], ecx
inc eax
mov dword [esi + 0x60], 6
mov dword [esi + 0x68], eax
mov dword [0x976914], eax
mov eax, dword [0x93113c]
mov dword [eax + 0x80], 7
mov dword [esi + 0xa4], ecx
mov eax, dword [0x93113c]
mov dword [eax + 0xa8], ecx
mov eax, dword [0x93113c]
mov dword [eax + 0xb8], 1
mov dword [0x976968], 0x22
mov dword [esi + 0xdc], 0x11
mov ecx, dword [0x93113c]
cmp dword [ecx + 0x68], 0x1a0b
je 0x40b4c2
mov eax, dword [esi + 0xb8]
mov ecx, dword [ecx + 0x4c]
add eax, 0x12570c
add eax, ecx
imul eax, dword [esi + 0x18]
mov dword [esi + 0x18], eax
jmp 0x40b4d1
mov eax, dword [ecx + 8]
xor eax, dword [esi + 0x4c]
xor eax, dword [0x976900]
add dword [ecx + 0x60], eax
mov eax, ebp
xor edx, 0x345d
xor eax, 0x15e2
push eax
push dword [0x93113c]
lea eax, [ebx - 0x115e]
push edx
push eax
mov eax, edi
xor eax, 0x11fd
push eax
lea eax, [edi - 0x139]
push eax
call fcn.00409c35
mov ecx, eax
add esp, 0x18
imul eax, dword [esi + 0x60], 0x165458
mov dword [esi + 0x60], eax
lea eax, [ecx + 0x51]
cmp edi, eax
je 0x40b647
mov eax, ecx
xor eax, 0x3e17
push eax
lea eax, [ecx + 0x4b6]
push eax
lea eax, [ebx + 0x4c4]
push eax
lea eax, [ebx - 0x637]
push eax
lea eax, [ebp + 0x4b6]
push eax
lea eax, [edi - 0x30f]
push eax
push dword [0x93113c]
call fcn.0040ab89
add esp, 0x1c
jmp 0x40b647
mov eax, dword [0x9768e0]
add eax, esi
cmp dword [0x97690c], eax
jae 0x40b647
mov ecx, dword [esp + 0x24]
mov eax, dword [ecx + 0x58]
or eax, dword [esp + 0x20]
cmp ebp, eax
jbe 0x40b647
mov eax, ebp
or eax, edi
and eax, esi
mov dword [esp + 0x20], eax
lea eax, [ebp - 0x2400]
mov dword [esp + 0x18], eax
mov esi, dword [0x93113c]
mov ecx, dword [ecx + 0xa4]
mov edx, dword [0x976914]
mov eax, dword [esp + 0x24]
add edx, 0x2fa9
mov edi, dword [esi + 0x28]
add edx, ecx
mov esi, dword [esp + 0x24]
xor edi, 0x353e
mov ecx, dword [0x97689c]
mov eax, dword [eax + 0x60]
and ecx, 0x1d6
add edi, dword [esp + 0x28]
or ecx, 0x2400
add eax, dword [esi + 0x5c]
mov esi, dword [0x93113c]
push eax
mov eax, dword [esp + 0x2c]
push ecx
push esi
push dword [esp + 0x2c]
xor eax, ebx
or eax, 0x23dd
push eax
push edx
push edi
call fcn.00409419
mov esi, dword [esp + 0x40]
mov dword [esp + 0x44], eax
mov ecx, dword [esi + 0xcc]
mov edx, dword [esi + 0x28]
sub ecx, eax
mov eax, dword [0x9768f0]
sub edx, 0x2627
add eax, 0xffffeeec
and eax, 0x23dd
push eax
push dword [0x93113c]
push ecx
push dword [esp + 0x40]
push edx
call fcn.00409da2
mov ecx, dword [esi + 0x58]
add esp, 0x30
or ecx, eax
inc ebp
cmp ebp, ecx
mov ecx, esi
ja 0x40b593
pop edi
pop esi
xor ebx, 0x162e
pop ebp
mov eax, ebx
pop ebx
ret