Function at 0x40cae0
Capabilities:
Generate random numbers via winapi

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x596296
mov eax, dword fs:[0]
push eax
sub esp, 0xe8
mov eax, dword [0x60dfd4]
xor eax, ebp
mov dword [ebp - 0x10], eax
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, ecx
mov dword [ebp - 0xc4], edi
mov byte [ebp - 0xbd], 0
xorps xmm0, xmm0
mov word [ebp - 0x14], 0
mov byte [ebp - 0x12], 0
movups xmmword [ebp - 0x24], xmm0
test edi, edi
jne 0x40cb35
xor eax, eax
jmp 0x40cb43
push 0x105
push edi
call fcn.005754d7
add esp, 8
add eax, 0x28
cmp eax, 0x105
jae 0x40cde3
push 2
push 0x13
lea eax, [ebp - 0x24]
push eax
push 0
call dword [sym.imp.bcrypt.dll_BCryptGenRandom]
test eax, eax
jne 0x40cde3
push 0x98
push eax
lea eax, [ebp - 0xbc]
push eax
lfence
call fcn.0056eeb0
add esp, 4
lea ecx, [ebp - 0xbc]
call fcn.0040d390
mov edx, edi
mov dword [ebp - 4], 0
lea ecx, [ebp - 0xbc]
call fcn.0040f680
push ecx
lea ecx, [ebp - 0xbc]
call fcn.00406790
lea edi, [ebp - 0x24]
nop
mov al, byte [edi]
lea ecx, [ebp - 0xa8]
mov byte [ebp - 0xbd], al
mov eax, dword [ebp - 0xbc]
push 0
push 2
mov eax, dword [eax + 4]
add ecx, eax
mov eax, dword [ecx]
and eax, 0xfffff9ff
or eax, 0x800
mov dword [ecx], eax
lea eax, [ebp - 0xd4]
push eax
call fcn.0056d496
mov esi, eax
lea ecx, [ebp - 0xbc]
mov eax, dword [ebp - 0xbc]
add esp, 0xc
push dword [esi + 0xc]
mov eax, dword [eax + 4]
push dword [esi + 8]
mov esi, dword [esi]
add eax, ecx
push eax
mov ecx, esi
call dword [0x5a72d4]
call esi
mov eax, dword [ebp - 0xbc]
add esp, 0xc
mov ecx, 0x30
mov eax, dword [eax + 4]
mov word [ebp + eax - 0x7c], cx
lea ecx, [ebp - 0xbc]
movzx eax, byte [ebp - 0xbd]
push eax
call fcn.0040dcd0
inc edi
lea eax, [ebp - 0x11]
cmp edi, eax
jne 0x40cbb0
push ecx
lea ecx, [ebp - 0xbc]
call fcn.00406790
lea ecx, [ebp - 0xbc]
call fcn.0040c000
lea eax, [ebp - 0xf4]
push eax
lea ecx, [ebp - 0xbc]
call fcn.0040d270
mov esi, eax
lea eax, [ebp - 0xdc]
mov byte [ebp - 4], 1
push eax
lea ecx, [ebp - 0xbc]
call fcn.0040d270
mov edi, dword [ebp - 0xc4]
mov edx, eax
mov eax, dword [esi + 0x10]
cmp dword [edx + 0x14], 8
jb 0x40cc99
mov edx, dword [edx]
add eax, eax
mov ecx, edi
push eax
push edx
mov edx, 0x105
call fcn.004105b0
mov edx, dword [ebp - 0xc8]
add esp, 8
cmp edx, 8
jb 0x40ccec
mov ecx, dword [ebp - 0xdc]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x40cce2
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40ce04
push edx
push ecx
call fcn.0056a733
add esp, 8
xor eax, eax
mov dword [ebp - 0xcc], 0
mov byte [ebp - 4], al
mov edx, dword [ebp - 0xe0]
mov dword [ebp - 0xc8], 7
mov word [ebp - 0xdc], ax
cmp edx, 8
jb 0x40cd4c
mov ecx, dword [ebp - 0xf4]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x40cd42
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40ce04
push edx
push ecx
call fcn.0056a733
add esp, 8
xor eax, eax
mov dword [ebp - 0xe4], 0
mov word [ebp - 0xf4], ax
mov eax, dword [ebp - 0xbc]
mov dword [ebp - 0xe0], 7
mov byte [ebp - 0xbd], 1
mov eax, dword [eax + 4]
mov dword [ebp + eax - 0xbc], vtable.std::basic_ostringstream_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__.0
mov eax, dword [ebp - 0xbc]
mov ecx, dword [eax + 4]
lea eax, [ecx - 0x50]
mov dword [ebp + ecx - 0xc0], eax
lea ecx, [ebp - 0xb8]
call fcn.0040dbd0
mov eax, dword [ebp - 0xbc]
mov eax, dword [eax + 4]
mov dword [ebp + eax - 0xbc], vtable.std::basic_ostream_unsigned_short_int__struct_std::char_traits_unsigned_short_int__.0
mov eax, dword [ebp - 0xbc]
mov ecx, dword [eax + 4]
lea eax, [ecx - 8]
mov dword [ebp + ecx - 0xc0], eax
lea eax, [ebp - 0x6c]
mov dword [ebp - 4], 2
push eax
mov dword [ebp - 0x6c], vtable.std::ios_base.0
call fcn.0056d3c3
add esp, 4
mov al, byte [ebp - 0xbd]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.0056a6fa
mov esp, ebp
pop ebp
ret
call fcn.005751b0
int3