Function at 0x50b284
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
mov ecx, 0x20
push 0
push 0
dec ecx
jne 0x50b28c
push ebx
push esi
mov dword [ebp - 8], edx
mov dword [ebp - 4], eax
mov eax, dword [ebp - 4]
call fcn.004048c8
mov eax, dword [ebp - 8]
call fcn.004048c8
xor eax, eax
push ebp
push 0x50b77e
push dword fs:[eax]
mov dword fs:[eax], esp
call fcn.0050b114
mov edx, eax
lea eax, [ebp - 0x50]
call fcn.00404610
mov eax, dword [ebp - 0x50]
lea edx, [ebp - 0x3c]
call fcn.00408d80
cmp dword [ebp - 0x3c], 0
jne 0x50b2e6
lea eax, [ebp - 0x3c]
mov edx, 0x50b798
call fcn.004044b0
call fcn.0040b198
fstp qword [ebp - 0x28]
wait
lea eax, [ebp - 0x4c]
call fcn.004f0c4c
lea edx, [ebp - 0x54]
mov eax, dword [ebp - 0x4c]
call fcn.00409150
push dword [ebp - 0x54]
lea edx, [ebp - 0x58]
mov eax, dword [ebp - 0x48]
call fcn.00409150
push dword [ebp - 0x58]
lea edx, [ebp - 0x5c]
mov eax, dword [ebp - 0x44]
call fcn.00409150
push dword [ebp - 0x5c]
lea edx, [ebp - 0x60]
mov eax, dword [ebp - 0x40]
call fcn.00409150
push dword [ebp - 0x60]
lea eax, [ebp - 0x1c]
mov edx, 4
call fcn.00404798
lea eax, [ebp - 0x14]
call fcn.00404418
lea eax, [ebp - 0xc]
push eax
lea edx, [ebp - 0x64]
mov eax, dword [ebp - 0x1c]
call fcn.00408d80
mov eax, dword [ebp - 0x64]
mov ecx, 0xc
mov edx, 1
call fcn.00404938
lea eax, [ebp - 0xc]
mov edx, dword [ebp - 0x3c]
call fcn.004046e0
jmp 0x50b37f
lea eax, [ebp - 0xc]
mov edx, 0x50b7a4
call fcn.004046e0
mov eax, dword [ebp - 0xc]
call fcn.004046d8
cmp eax, 0x14
jl 0x50b372
cmp dword [ebp - 4], 0
jne 0x50b3fc
lea edx, [ebp - 0x30]
lea eax, [ebp - 0x10]
call fcn.0050b9b0
test al, al
jne 0x50b407
call fcn.0050b8d0
mov ebx, eax
mov eax, ebx
call fcn.0050b7f4
fld qword [ebp - 0x28]
fsub qword [ebp - 0x30]
fstp qword [ebp - 0x38]
wait
fld qword [ebp - 0x38]
fcomp dword [0x50b7a8]
fnstsw ax
sahf
nop
nop
fld qword [ebp - 0x38]
fcomp dword [0x50b7ac]
fnstsw ax
sahf
nop
nop
cmp ebx, 0x64
jmp 0x50b3f5
xor ebx, ebx
jmp 0x50b73b
lea eax, [ebp - 0x10]
mov edx, dword [ebp - 4]
call fcn.004044b0
mov eax, dword [ebp - 0xc]
call fcn.004046d8
mov esi, eax
test esi, esi
jle 0x50b458
mov dword [ebp - 0x18], 1
lea eax, [ebp - 0x68]
push eax
mov ecx, 1
mov edx, dword [ebp - 0x18]
mov eax, dword [ebp - 0xc]
call fcn.00404938
mov eax, dword [ebp - 0x68]
call fcn.004048d8
mov bl, byte [eax]
lea eax, [ebp - 0x6c]
mov edx, ebx
xor dl, 9
call fcn.00404600
mov edx, dword [ebp - 0x6c]
lea eax, [ebp - 0x14]
call fcn.004046e0
inc dword [ebp - 0x18]
dec esi
jne 0x50b41c
lea eax, [ebp - 0x70]
mov edx, dword [ebp - 0x14]
mov dl, byte [edx]
mov byte [eax + 1], dl
mov byte [eax], 1
lea edx, [ebp - 0x70]
lea eax, [ebp - 0x74]
call fcn.00402d10
lea eax, [ebp - 0x78]
mov edx, dword [ebp - 0x14]
mov dl, byte [edx + 1]
mov byte [eax + 1], dl
mov byte [eax], 1
lea edx, [ebp - 0x78]
lea eax, [ebp - 0x74]
mov cl, 2
call fcn.00402ce0
lea edx, [ebp - 0x74]
lea eax, [ebp - 0x7c]
call fcn.00402d10
lea eax, [ebp - 0x78]
mov edx, dword [ebp - 0x14]
mov dl, byte [edx + 2]
mov byte [eax + 1], dl
mov byte [eax], 1
lea edx, [ebp - 0x78]
lea eax, [ebp - 0x7c]
mov cl, 3
call fcn.00402ce0
lea edx, [ebp - 0x7c]
lea eax, [ebp - 0x84]
call fcn.00402d10
lea eax, [ebp - 0x78]
mov edx, dword [ebp - 0x14]
mov dl, byte [edx + 3]
mov byte [eax + 1], dl
mov byte [eax], 1
lea edx, [ebp - 0x78]
lea eax, [ebp - 0x84]
mov cl, 4
call fcn.00402ce0
lea edx, [ebp - 0x84]
lea eax, [ebp - 0x8c]
call fcn.00402d10
mov edx, 0x50b7f0
lea eax, [ebp - 0x8c]
mov cl, 5
call fcn.00402ce0
lea edx, [ebp - 0x8c]
lea eax, [ebp - 0x94]
call fcn.00402d10
lea eax, [ebp - 0x78]
mov edx, dword [ebp - 0x14]
mov dl, byte [edx + 4]
mov byte [eax + 1], dl
mov byte [eax], 1
lea edx, [ebp - 0x78]
lea eax, [ebp - 0x94]
mov cl, 6
call fcn.00402ce0
lea edx, [ebp - 0x94]
lea eax, [ebp - 0x9c]
call fcn.00402d10
lea eax, [ebp - 0x78]
mov edx, dword [ebp - 0x14]
mov dl, byte [edx + 5]
mov byte [eax + 1], dl
mov byte [eax], 1
lea edx, [ebp - 0x78]
lea eax, [ebp - 0x9c]
mov cl, 7
call fcn.00402ce0
lea edx, [ebp - 0x9c]
lea eax, [ebp - 0xa8]
call fcn.00402d10
lea eax, [ebp - 0x78]
mov edx, dword [ebp - 0x14]
mov dl, byte [edx + 6]
mov byte [eax + 1], dl
mov byte [eax], 1
lea edx, [ebp - 0x78]
lea eax, [ebp - 0xa8]
mov cl, 8
call fcn.00402ce0
lea edx, [ebp - 0xa8]
lea eax, [ebp - 0xb4]
call fcn.00402d10
lea eax, [ebp - 0x78]
mov edx, dword [ebp - 0x14]
mov dl, byte [edx + 7]
mov byte [eax + 1], dl
mov byte [eax], 1
lea edx, [ebp - 0x78]
lea eax, [ebp - 0xb4]
mov cl, 9
call fcn.00402ce0
lea edx, [ebp - 0xb4]
lea eax, [ebp - 0xc0]
call fcn.00402d10
mov edx, 0x50b7f0
lea eax, [ebp - 0xc0]
mov cl, 0xa
call fcn.00402ce0
lea edx, [ebp - 0xc0]
lea eax, [ebp - 0xcc]
call fcn.00402d10
lea eax, [ebp - 0x78]
mov edx, dword [ebp - 0x14]
mov dl, byte [edx + 8]
mov byte [eax + 1], dl
mov byte [eax], 1
lea edx, [ebp - 0x78]
lea eax, [ebp - 0xcc]
mov cl, 0xb
call fcn.00402ce0
lea edx, [ebp - 0xcc]
lea eax, [ebp - 0xdc]
call fcn.00402d10
lea eax, [ebp - 0x78]
mov edx, dword [ebp - 0x14]
mov dl, byte [edx + 9]
mov byte [eax + 1], dl
mov byte [eax], 1
lea edx, [ebp - 0x78]
lea eax, [ebp - 0xdc]
mov cl, 0xc
call fcn.00402ce0
lea edx, [ebp - 0xdc]
lea eax, [ebp - 0xec]
call fcn.00402d10
lea eax, [ebp - 0x78]
mov edx, dword [ebp - 0x14]
mov dl, byte [edx + 0xa]
mov byte [eax + 1], dl
mov byte [eax], 1
lea edx, [ebp - 0x78]
lea eax, [ebp - 0xec]
mov cl, 0xd
call fcn.00402ce0
lea edx, [ebp - 0xec]
lea eax, [ebp - 0xfc]
call fcn.00402d10
lea eax, [ebp - 0x78]
mov edx, dword [ebp - 0x14]
mov dl, byte [edx + 0xb]
mov byte [eax + 1], dl
mov byte [eax], 1
lea edx, [ebp - 0x78]
lea eax, [ebp - 0xfc]
mov cl, 0xe
call fcn.00402ce0
lea edx, [ebp - 0xfc]
lea eax, [ebp - 0x14]
call fcn.0040467c
lea ecx, [ebp - 0x100]
mov edx, dword [ebp - 8]
mov eax, dword [ebp - 0x10]
call fcn.0050bd8c
mov edx, dword [ebp - 0x100]
lea eax, [ebp - 0x10]
call fcn.004044b0
mov eax, dword [ebp - 0x10]
mov edx, dword [ebp - 0x14]
call fcn.00404824
jne 0x50b6e5
mov bl, 1
jmp 0x50b73b
call fcn.0050b8d0
mov ebx, eax
mov eax, ebx
call fcn.0050b7f4
fld qword [ebp - 0x28]
fsub qword [ebp - 0x30]
fstp qword [ebp - 0x38]
wait
fld qword [ebp - 0x38]
fcomp dword [0x50b7a8]
fnstsw ax
sahf
ja 0x50b71e
fld qword [ebp - 0x38]
fcomp dword [0x50b7ac]
fnstsw ax
sahf
jb 0x50b71e
cmp ebx, 0x64
jle 0x50b739
push 0x40030
mov ecx, 0x50b7b0
mov edx, 0x50b7b8
mov eax, dword [0x51a64c]
mov eax, dword [eax]
call fcn.0048ce70
xor ebx, ebx
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x50b785
lea eax, [ebp - 0x100]
call fcn.00404418
lea eax, [ebp - 0x6c]
mov edx, 8
call fcn.0040443c
lea eax, [ebp - 0x3c]
call fcn.00404418
lea eax, [ebp - 0x1c]
call fcn.00404418
lea eax, [ebp - 0x14]
mov edx, 5
call fcn.0040443c
ret