Function at 0x140049750
Capabilities:
Generate random numbers via rtlgenrandom

Disassembly:
test rdx, rdx
je 0x140049991
mov r11, rsp
push rbp
push r12
push r13
push r14
sub rsp, 0x138
mov qword [r11 + 8], rbx
xor r13d, r13d
mov qword [r11 + 0x20], rdi
mov rbp, rdx
mov qword [r11 - 0x28], r15
mov r12, rcx
mov qword [r11 + 0x18], rsi
mov r14d, r13d
mov dword [rsp + 0x168], r13d
mov eax, 0xffffffff
nop dword [rax]
nop word [rax + rax]
cmp rbp, rax
mov r15d, ebp
mov rcx, r12
cmova r15d, eax
mov edx, r15d
call sub.ADVAPI32.dll_SystemFunction036
test al, al
jne 0x14004993b
mov r9d, 0x7d
mov dword [rsp + 0x20], 4
lea r8, str..._.._.._third_party_mini_chromium_mini_chromium_base_rand_util.cc
or r14d, 1
lea rdx, str.void___cdecl_base::RandBytes_void__unsigned___int64_
lea rcx, [rsp + 0x30]
call fcn.14002aac0
mov rdi, rax
mov esi, r13d
mov rdx, qword [rax]
movsxd rcx, dword [rdx + 4]
mov rbx, qword [rcx + rax + 0x28]
cmp rbx, 0x16
jl 0x140049805
add rbx, 0xffffffffffffffeb
jmp 0x140049808
mov rbx, r13
mov rcx, qword [rcx + rax + 0x48]
mov r8, rdx
test rcx, rcx
je 0x140049821
mov rax, qword [rcx]
call qword [rax + 8]
mov rdx, qword [rdi]
mov r8, rdx
movsxd rax, dword [rdx + 4]
cmp dword [rax + rdi + 0x10], esi
jne 0x140049850
mov rcx, qword [rax + rdi + 0x50]
test rcx, rcx
je 0x14004985a
cmp rcx, rdi
je 0x14004985a
call qword [sym.imp.MSVCP140.dll_public:_class_std::basic_ostream_char__struct_std::char_traits_char______ptr64___cdecl_std::basic_ostream_char__struct_std::char_traits_char__::flush_void____ptr64]
mov rdx, qword [rdi]
mov r8, rdx
movsxd rax, dword [rdx + 4]
cmp dword [rax + rdi + 0x10], esi
je 0x14004985a
mov esi, 4
jmp 0x1400498fa
movsxd rax, dword [rdx + 4]
mov ecx, dword [rax + rdi + 0x18]
and ecx, 0x1c0
cmp ecx, 0x40
je 0x140049899
test rbx, rbx
jle 0x140049899
mov rax, qword [rdi]
movsxd rcx, dword [rax + 4]
movzx edx, byte [rcx + rdi + 0x58]
mov rcx, qword [rcx + rdi + 0x48]
call qword [sym.imp.MSVCP140.dll_public:_int___cdecl_std::basic_streambuf_char__struct_std::char_traits_char__::sputc_char____ptr64]
cmp eax, 0xffffffff
je 0x1400498e6
dec rbx
test rbx, rbx
jg 0x140049872
mov r8, qword [rdi]
movsxd rax, dword [r8 + 4]
lea rdx, str.Check_failed:_success
mov r8d, 0x15
mov rcx, qword [rax + rdi + 0x48]
call qword [sym.imp.MSVCP140.dll_public:_long_long___int64____cdecl_std::basic_streambuf_char__struct_std::char_traits_char__::sputn_char_const____ptr64__long_long___int64_____ptr64]
cmp rax, 0x15
jne 0x1400498e6
test rbx, rbx
jle 0x1400498eb
mov rax, qword [rdi]
movsxd rcx, dword [rax + 4]
movzx edx, byte [rcx + rdi + 0x58]
mov rcx, qword [rcx + rdi + 0x48]
call qword [sym.imp.MSVCP140.dll_public:_int___cdecl_std::basic_streambuf_char__struct_std::char_traits_char__::sputc_char____ptr64]
cmp eax, 0xffffffff
je 0x1400498e6
dec rbx
test rbx, rbx
jg 0x1400498c0
jmp 0x1400498eb
mov esi, 4
mov rax, qword [rdi]
movsxd rcx, dword [rax + 4]
mov qword [rcx + rdi + 0x28], r13
mov rdx, qword [rdi]
movsxd rcx, dword [rdx + 4]
xor r8d, r8d
add rcx, rdi
mov edx, esi
call qword [sym.imp.MSVCP140.dll_public:_void___cdecl_std::basic_ios_char__struct_std::char_traits_char__::setstate_int__bool____ptr64]
mov rcx, rdi
call qword [sym.imp.MSVCP140.dll_public:_void___cdecl_std::basic_ostream_char__struct_std::char_traits_char__::_Osfx_void____ptr64]
mov rax, qword [rdi]
movsxd rcx, dword [rax + 4]
mov rcx, qword [rcx + rdi + 0x48]
test rcx, rcx
je 0x14004992c
mov rax, qword [rcx]
call qword [rax + 0x10]
lea rdx, [0x1400d87ac]
mov rcx, rdi
call fcn.140008bc0
test r14b, 1
je 0x14004994f
and r14d, 0xfffffffe
lea rcx, [rsp + 0x30]
call fcn.14002ae10
mov eax, r15d
add r12, rax
sub rbp, rax
mov eax, 0xffffffff
jne 0x1400497a0
mov r15, qword [rsp + 0x130]
mov rdi, qword [rsp + 0x178]
mov rsi, qword [rsp + 0x170]
mov rbx, qword [rsp + 0x160]
add rsp, 0x138
pop r14
pop r13
pop r12
pop rbp
ret