Function at 0x4036b0
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
and esp, 0xfffffff8
sub esp, 0x68
fld qword [ebp + 0x10]
fst qword [esp + 0x48]
mov ebx, dword [esp + 0x4c]
mov eax, ebx
shr eax, 0x14
fld st(0)
fchs
test ebx, ebx
js 0x4036d8
fstp st(0)
fld st(0)
mov esi, dword [ebp + 8]
mov edi, dword [esp + 0x48]
and eax, 0x7ff
je 0x403730
fstp st(1)
mov dword [esp + 0x10], ecx
mov dword [esp + 0x14], edx
cmp eax, 0x7ff
jne 0x403788
fstp st(0)
mov ecx, ebx
and ecx, 0xfffff
or edi, ecx
mov ecx, 0x44d2f5
je 0x403713
mov ecx, 0x44d543
mov eax, dword [esp + 0x10]
mov dword [eax], ecx
mov eax, dword [ebp + 0xc]
mov dword [eax], 0x7000
mov edi, 3
mov edx, dword [esp + 0x14]
jmp 0x403b44
fxch st(1)
fstp qword [esp + 0x40]
mov eax, SysReAllocString
and eax, dword [esp + 0x44]
or eax, dword [esp + 0x40]
je 0x4037d4
mov dword [esp + 0x10], ecx
mov dword [esp + 0x14], edx
test ebx, 0x80000
jne 0x4037ee
mov edx, 0x80000
xor esi, esi
xor eax, eax
mov dword [esp], edi
nop
nop
nop
nop
nop
nop
nop
dec eax
shrd esi, edx, 1
shr edx, 1
mov edi, edx
and edi, ebx
mov ecx, ebx
mov ebx, esi
and ebx, dword [esp]
or ebx, edi
mov ebx, ecx
je 0x403770
lea edi, [eax - 0x3ff]
cmp eax, 0x3fe
jle 0x4037f5
mov dword [esp + 0x18], ebx
mov esi, edi
or esi, 0x4d1
mov edx, edi
and edx, 0x4d1
imul edx, esi
and edi, 0xfffffb2e
mov esi, 0x3fe
sub esi, eax
and esi, 0x4d1
imul esi, edi
add esi, edx
mov edi, esi
sar edi, 0x1f
shr edi, 0x14
add edi, esi
sar edi, 0xc
inc edi
jmp 0x403832
fstp st(0)
mov eax, dword [ebp + 0xc]
mov dword [eax], 1
mov dword [ecx], esi
mov byte [esi], 0x30
mov edi, 1
jmp 0x403b44
xor eax, eax
mov edi, 0xfffffc01
mov dword [esp + 0x18], ebx
mov edx, 0x3fe
sub edx, eax
and edx, 0x269
mov eax, edi
and eax, 0xfffffd96
imul eax, edx
mov edx, edi
and edx, 0x269
or edi, 0x269
imul edi, edx
add edi, eax
mov eax, edi
sar eax, 0x1f
shr eax, 0x15
add eax, edi
mov edi, eax
sar edi, 0xb
mov esi, dword [ebp + 0x18]
mov eax, 0x12
sub eax, edi
sub esp, 0x14
mov dword [esp + 0x10], eax
fstp qword [esp + 8]
lea eax, [esp + 0x64]
mov dword [esp + 4], eax
lea eax, [esp + 0x6c]
mov dword [esp], eax
call fcn.00405d30
add esp, 0x14
fld qword [esp + 0x58]
fnstcw word [esp + 0xe]
movzx eax, word [esp + 0xe]
or eax, 0xc00
mov word [esp + 0x22], ax
fldcw word [esp + 0x22]
fld st(0)
fistp qword [esp + 0x38]
fldcw word [esp + 0xe]
mov edx, dword [esp + 0x38]
mov ebx, dword [esp + 0x3c]
mov dword [esp + 0x34], ebx
mov dword [esp + 0x30], edx
fild qword [esp + 0x30]
fld st(1)
fsub st(1)
fld st(0)
fsub st(3)
fld st(1)
fsub st(1)
fsubp st(4)
faddp st(2)
fxch st(2)
fsubrp st(1)
faddp st(1)
fadd qword [esp + 0x50]
fnstcw word [esp + 0xc]
movzx eax, word [esp + 0xc]
or eax, 0xc00
mov word [esp + 0x20], ax
fldcw word [esp + 0x20]
fistp qword [esp + 0x28]
fldcw word [esp + 0xc]
add edx, dword [esp + 0x28]
adc ebx, dword [esp + 0x2c]
mov eax, 0xa763ffff
cmp eax, edx
mov eax, 0xde0b6b3
sbb eax, ebx
adc edi, 0
test esi, esi
js 0x4038f1
add esi, edi
jmp 0x4038f8
and esi, 0x7ffffff
inc esi
mov dword [esp + 0x24], edi
cmp esi, 0x17
ja 0x403962
xor eax, eax
mov ecx, 0x3b9ac9ff
mov dword [esp], edx
cmp ecx, edx
sbb eax, ebx
setb al
movzx eax, al
lea edx, [eax + eax*8]
inc edx
mov eax, edx
mov dword [esp + 4], esi
sub eax, esi
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
mov ecx, dword [edx*8 + 0x44b0fc]
mov edi, dword [edx*8 + 0x44b0f8]
cmp dword [esp], edi
mov esi, ebx
sbb esi, ecx
jb 0x403950
inc edx
inc eax
cmp edx, 0x14
jne 0x403930
jmp 0x40395f
cmp dword [esp + 4], edx
jae 0x40395f
cmp eax, 0x17
jbe 0x403b5b
mov edx, dword [esp]
xor edi, edi
mov eax, edx
or eax, ebx
je 0x4039f9
test ebx, ebx
jle 0x4039c9
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
mov dword [esp], edx
push 0
push 0x3e8
push ebx
push edx
call fcn.0040c650
mov ecx, edx
mov dword [esp + 4], eax
mov edx, 0x3e8
mul edx
imul esi, ecx, 0x3e8
add esi, edx
mov edx, dword [esp]
sub edx, eax
mov eax, ebx
sbb eax, esi
or eax, edx
jne 0x403b53
shr ebx, 3
mov eax, dword [esp + 4]
mov edx, eax
cmp ebx, 0x7c
mov ebx, ecx
ja 0x403980
mov edx, eax
imul eax, edx, 0x26e978d5
ror eax, 3
cmp eax, 0x418937
ja 0x4039fb
mov ecx, 0x10624dd3
nop
nop
mov eax, edx
mul ecx
shr edx, 6
imul eax, edx, 0x26e978d5
ror eax, 3
cmp eax, 0x418938
jb 0x4039e0
jmp 0x4039fb
xor edx, edx
xor ebx, ebx
mov eax, dword [ebp + 8]
lea ecx, [eax + 0x40]
add eax, 0x3e
mov dword [esp], eax
jmp 0x403a3f
xor esi, esi
mov ecx, dword [esp + 8]
mov dword [esp + 4], ebx
lea eax, [ecx - 8]
mov ebx, ecx
lea ecx, [esi + 8]
push ecx
push 0x30
push eax
call fcn.0040c770
mov ecx, ebx
mov ebx, dword [esp + 0x10]
add esp, 0xc
add edi, esi
add edi, 8
add ecx, 0xfffffff8
add dword [esp], 0xfffffff8
mov edx, dword [esp + 0x1c]
cmp edx, 0x5f5e100
mov eax, ebx
sbb eax, 0
mov dword [esp + 8], ecx
jl 0x403a80
push 0
push 0x5f5e100
push ebx
push edx
mov esi, edx
call fcn.0040c650
mov ebx, edx
mov edx, esi
mov dword [esp + 0x1c], eax
imul eax, eax, 0x5f5e100
sub edx, eax
je 0x403a0b
mov dword [esp + 4], ebx
jmp 0x403a94
test edx, edx
je 0x403aff
mov dword [esp + 4], 0
mov dword [esp + 0x1c], 0
xor esi, esi
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
mov eax, edx
mov ebx, edx
mov ecx, 0x51eb851f
mul ecx
shr edx, 5
imul eax, edx, 0x64
mov ecx, ebx
sub ecx, eax
movzx eax, word [ecx + ecx + str.00010203040506070809101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899]
mov ecx, dword [esp]
mov word [ecx + esi], ax
mov eax, edi
and eax, 2
xor edi, 2
lea edi, [edi + eax*2]
add esi, 0xfffffffe
cmp ebx, 0x63
ja 0x403aa0
mov eax, dword [esp + 0x1c]
mov ebx, dword [esp + 4]
or eax, ebx
je 0x403af5
cmp esi, 0xfffffff8
mov ecx, dword [esp + 8]
jne 0x403a11
jmp 0x403a34
mov ebx, dword [esp + 0x18]
mov ecx, dword [esp + 8]
jmp 0x403b05
xor esi, esi
mov ebx, dword [esp + 0x18]
add ecx, esi
test edi, edi
je 0x403b27
cmp byte [ecx], 0x30
mov edx, dword [esp + 0x14]
mov esi, dword [esp + 0x10]
mov eax, ecx
mov ecx, dword [ebp + 0xc]
jne 0x403b1f
dec edi
inc eax
mov dword [esp + 8], eax
mov eax, esi
jmp 0x403b38
mov dword [esp + 8], ecx
xor edi, edi
mov edx, dword [esp + 0x14]
mov eax, dword [esp + 0x10]
mov ecx, dword [ebp + 0xc]
mov esi, dword [esp + 0x24]
mov dword [ecx], esi
mov ecx, dword [esp + 8]
mov dword [eax], ecx
mov dword [edx], edi
shr ebx, 0x1f
mov eax, ebx
lea esp, [ebp - 0xc]
pop esi
pop edi
pop ebx
pop ebp
ret
mov edx, dword [esp]
jmp 0x4039fd
mov esi, dword [eax*8 + 0x44b0f8]
mov dword [esp + 4], esi
mov edx, dword [eax*8 + 0x44b0fc]
mov eax, edx
shld eax, esi, 0x1f
mov esi, edx
shr esi, 1
add eax, dword [esp]
adc esi, ebx
cmp eax, edi
mov edi, esi
sbb edi, ecx
sbb dword [esp + 0x24], 0xffffffff
push edx
push dword [esp + 8]
push esi
push eax
call fcn.0040c650
mov ebx, edx
mov edx, eax
jmp 0x403962