Function at 0x10016e70
Capabilities:
Generate random numbers via winapi

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x154
mov eax, dword [section..data]
xor eax, ebp
mov dword [ebp - 4], eax
xor eax, eax
mov dword [ebp - 0x144], eax
mov dword [ebp - 0x130], eax
lea eax, [ebp - 0x130]
mov dword [ebp - 0x148], eax
xor eax, eax
push ebx
mov ebx, ecx
mov dword [ebp - 0x13c], eax
mov word [ebp - 0x138], ax
movzx eax, word [0x10058588]
push esi
movzx ecx, word [ebx + 0xd2]
mov esi, edx
and eax, ecx
movzx ecx, word [0x10058586]
cdq
idiv ecx
mov al, byte [ebp + 0xc]
mov word [ebp - 0x136], dx
push edi
test al, al
je 0x10016eee
test byte [0x10059abc], 1
je 0x10016f2a
push dword [ebp + 8]
push str.Recv__u_deferred_UDP_datagrams
jmp 0x10016eff
test byte [0x10059abc], 1
je 0x10016f2a
push dword [ebp + 8]
push str.Recv__u_UDP_datagrams
push 0xffffffffffffffff
lea eax, [ebp - 0x88]
push 0x80
push eax
call fcn.100015f0
add esp, 0x14
lea eax, [ebp - 0x88]
mov edx, 0x1004c9b0
push eax
push ebx
call fcn.10001280
add esp, 8
xor al, al
mov dword [ebp - 0x140], 0
mov byte [ebp - 0x12c], al
mov edi, esi
test esi, esi
je 0x10017472
mov esi, dword [esi]
mov edx, edi
mov dword [edi], 0
mov ecx, ebx
and byte [edi + 0x41], 0xfe
mov dword [ebp - 0x150], esi
call fcn.1002f110
mov dword [ebp - 0x14c], eax
test eax, eax
jne 0x10016f82
push str.Max_paths_already_tracked
lea edx, [edi + 0x18]
mov ecx, ebx
call fcn.1000c440
add esp, 4
jmp 0x100171d1
mov ecx, dword [ebp - 0x140]
cmp eax, ecx
je 0x10016fd0
cmp byte [ebp - 0x12c], 0
je 0x10016fca
lea eax, [ebp - 0x138]
mov edx, ecx
push eax
lea eax, [ebp - 0x108]
mov ecx, ebx
push eax
lea eax, [ebp - 0x128]
push eax
push dword [ebp - 0x12c]
call fcn.10016bb0
add esp, 0x10
xor al, al
mov byte [ebp - 0x12c], al
mov eax, dword [ebp - 0x14c]
mov dword [ebp - 0x140], eax
cmp byte [ebp + 0xc], 0
jne 0x10017070
movzx eax, word [edi + 0xc]
cdq
add eax, dword [ebx + 0xbe8]
mov dword [ebx + 0xbe8], eax
adc edx, dword [ebx + 0xbec]
mov dword [ebx + 0xbec], edx
test byte [0x10059aba], 8
je 0x10017010
push edx
push eax
push ebx
mov edx, 0x1004c970
call fcn.100080a0
add esp, 0xc
mov ecx, dword [ebp - 0x140]
test byte [ecx + 1], 0x20
jne 0x10017070
movzx eax, word [edi + 0xc]
mov edx, 4
lea eax, [eax + eax*2]
add dword [ecx + 0x6c], eax
cmp dword [ecx + 0x6c], 0x4b
mov ecx, ebx
jb 0x10017064
call fcn.1000dc10
test al, al
je 0x10017070
cmp dword [ebx + 0xab8], 0
je 0x10017055
lea ecx, [ebx + 0xa70]
mov edx, 0xb
call fcn.1002f5e0
lea ecx, [ebx + 0x808]
mov dl, 1
call fcn.100315b0
jmp 0x10017070
call fcn.10024270
nop dword [eax]
add dword [ebx + 0xbb0], 1
adc dword [ebx + 0xbb4], 0
test byte [edi + 0x40], 2
jne 0x10017094
mov ax, word [edi + 0xc]
sub ax, word [edi + 0x28]
add ax, word [edi + 8]
mov word [edi + 0x34], ax
test byte [ebx + 0x878], 4
jne 0x1001718b
test byte [ebx + 0x9a4], 1
jne 0x1001718b
movzx eax, byte [ebp - 0x12c]
lea ecx, [ebp - 0x108]
shl eax, 4
lea edx, [edi + 0x18]
add eax, ecx
mov ecx, ebx
push eax
mov dword [ebp - 0x14c], eax
call fcn.100139a0
add esp, 4
test al, al
je 0x1001718b
test byte [edi + 0x40], 4
mov cl, byte [ebp - 0x12c]
jne 0x1001712d
test cl, cl
je 0x1001712d
mov edx, dword [ebp - 0x140]
lea eax, [ebp - 0x138]
push eax
lea eax, [ebp - 0x108]
mov ecx, ebx
push eax
lea eax, [ebp - 0x128]
push eax
push dword [ebp - 0x12c]
call fcn.10016bb0
push 0x10
lea eax, [ebp - 0x108]
push eax
push dword [ebp - 0x14c]
call fcn.10049810
add esp, 0x1c
xor cl, cl
movzx eax, cl
inc cl
test byte [edi + 0x40], 4
mov byte [ebp - 0x12c], cl
mov dword [ebp + eax*4 - 0x128], edi
je 0x1001714e
cmp cl, 8
jb 0x100171d1
mov edx, dword [ebp - 0x140]
lea eax, [ebp - 0x138]
push eax
lea eax, [ebp - 0x108]
mov ecx, ebx
push eax
lea eax, [ebp - 0x128]
push eax
push dword [ebp - 0x12c]
call fcn.10016bb0
mov dl, byte [edi + 0x40]
xor al, al
add esp, 0x10
mov byte [ebp - 0x12c], al
test dl, 4
jne 0x100171d1
jmp 0x1001719e
test byte [edi + 0x41], 1
jne 0x100171c3
mov dl, byte [edi + 0x40]
test dl, 4
jne 0x100171d1
test dl, 8
je 0x100171d1
movzx eax, word [edi + 0x34]
and dl, 0x45
add dword [edi + 0x28], eax
and byte [edi + 0x41], 0xf0
mov ecx, dword [edi + 0x28]
mov byte [edi + 0x40], dl
sub ecx, dword [edi + 8]
movzx eax, word [edi + 0xc]
cmp ecx, eax
jl 0x10017070
jmp 0x100171d1
add dword [ebx + 0xbb0], 0xffffffff
adc dword [ebx + 0xbb4], 0xffffffff
test byte [edi + 0x41], 1
jne 0x1001734d
mov eax, dword [ebp - 0x148]
mov ecx, dword [ebp - 0x13c]
inc ecx
mov dword [ebp - 0x148], edi
mov dword [ebp - 0x13c], ecx
mov dword [eax], edi
mov eax, 0xfffd
and word [edi + 0x12], ax
cmp ecx, 0x20
jne 0x10017341
cmp byte [ebp - 0x12c], 0
je 0x10017244
mov edx, dword [ebp - 0x140]
lea eax, [ebp - 0x138]
push eax
lea eax, [ebp - 0x108]
mov ecx, ebx
push eax
lea eax, [ebp - 0x128]
push eax
push dword [ebp - 0x12c]
call fcn.10016bb0
add esp, 0x10
xor al, al
mov byte [ebp - 0x12c], al
mov eax, dword [ebp - 0x130]
xor edx, edx
xor esi, esi
test eax, eax
je 0x1001731d
mov edi, eax
nop dword [eax + eax]
mov edi, dword [edi + 0x14]
mov eax, dword [eax]
mov dword [ebp - 0x130], eax
mov dword [ebp - 0x13c], edi
cmp esi, edi
jne 0x10017278
inc edx
jmp 0x100172d1
test esi, esi
je 0x100172ca
neg edx
lea eax, [esi + 8]
mov ecx, edx
lock xadd dword [eax], ecx
add ecx, edx
jne 0x100172c4
mov edi, dword [esi]
push edi
call dword [sym.imp.KERNEL32.dll_QueryDepthSList]
movzx eax, ax
cmp eax, dword [edi + 0x10]
lfence
jb 0x100172b6
push edi
push dword [edi + 0xc]
push esi
mov esi, dword [edi + 0x18]
mov ecx, esi
call dword [0x1004b298]
call esi
add esp, 0xc
jmp 0x100172be
push esi
push edi
call dword [sym.imp.KERNEL32.dll_InterlockedPushEntrySList]
mov edi, dword [ebp - 0x13c]
mov eax, dword [ebp - 0x130]
mov esi, edi
mov edx, 1
mov edi, eax
test eax, eax
jne 0x10017260
test esi, esi
je 0x1001731d
neg edx
lea eax, [esi + 8]
mov ecx, edx
lock xadd dword [eax], ecx
add ecx, edx
jne 0x1001731d
mov edi, dword [esi]
push edi
call dword [sym.imp.KERNEL32.dll_QueryDepthSList]
movzx eax, ax
cmp eax, dword [edi + 0x10]
lfence
jb 0x10017315
push edi
push dword [edi + 0xc]
push esi
mov esi, dword [edi + 0x18]
mov ecx, esi
call dword [0x1004b298]
call esi
add esp, 0xc
jmp 0x1001731d
push esi
push edi
call dword [sym.imp.KERNEL32.dll_InterlockedPushEntrySList]
xor eax, eax
mov dword [ebp - 0x144], eax
mov dword [ebp - 0x130], eax
lea eax, [ebp - 0x130]
mov dword [ebp - 0x148], eax
xor eax, eax
mov dword [ebp - 0x13c], eax
jmp 0x1001734d
mov eax, dword [ebp - 0x130]
mov dword [ebp - 0x144], eax
mov esi, dword [ebp - 0x150]
mov edi, esi
test esi, esi
jne 0x10016f46
cmp byte [ebp - 0x12c], 0
je 0x10017391
mov edx, dword [ebp - 0x140]
lea eax, [ebp - 0x138]
push eax
lea eax, [ebp - 0x108]
mov ecx, ebx
push eax
lea eax, [ebp - 0x128]
push eax
push dword [ebp - 0x12c]
call fcn.10016bb0
add esp, 0x10
cmp byte [ebp - 0x138], 0
je 0x100173a1
mov ecx, ebx
call fcn.10017790
mov eax, dword [ebp - 0x144]
test eax, eax
je 0x10017472
xor edx, edx
mov edi, eax
xor esi, esi
mov edi, dword [edi + 0x14]
mov eax, dword [eax]
mov dword [ebp - 0x144], eax
mov dword [ebp - 0x13c], edi
cmp esi, edi
jne 0x100173cd
inc edx
jmp 0x10017426
test esi, esi
je 0x1001741f
neg edx
lea eax, [esi + 8]
mov ecx, edx
lock xadd dword [eax], ecx
add ecx, edx
jne 0x10017419
mov edi, dword [esi]
push edi
call dword [sym.imp.KERNEL32.dll_QueryDepthSList]
movzx eax, ax
cmp eax, dword [edi + 0x10]
lfence
jb 0x1001740b
push edi
push dword [edi + 0xc]
push esi
mov esi, dword [edi + 0x18]
mov ecx, esi
call dword [0x1004b298]
call esi
add esp, 0xc
jmp 0x10017413
push esi
push edi
call dword [sym.imp.KERNEL32.dll_InterlockedPushEntrySList]
mov edi, dword [ebp - 0x13c]
mov eax, dword [ebp - 0x144]
mov esi, edi
mov edx, 1
mov edi, eax
test eax, eax
jne 0x100173b5
test esi, esi
je 0x10017472
neg edx
lea eax, [esi + 8]
mov ecx, edx
lock xadd dword [eax], ecx
add ecx, edx
jne 0x10017472
mov edi, dword [esi]
push edi
call dword [sym.imp.KERNEL32.dll_QueryDepthSList]
movzx eax, ax
cmp eax, dword [edi + 0x10]
lfence
jb 0x1001746a
push edi
push dword [edi + 0xc]
push esi
mov esi, dword [edi + 0x18]
mov ecx, esi
call dword [0x1004b298]
call esi
add esp, 0xc
jmp 0x10017472
push esi
push edi
call dword [sym.imp.KERNEL32.dll_InterlockedPushEntrySList]
cmp dword [ebx], 4
jne 0x100174de
mov eax, dword [ebx + 0xbd8]
or eax, dword [ebx + 0xbdc]
jne 0x100174de
test byte [ebx + 0xc0], 0x10
jne 0x100174de
test byte [0x10059abb], 0x40
je 0x100174c4
push str.Aborting_connection_with_invalid_initial_packets
push 0xffffffffffffffff
lea eax, [ebp - 0x88]
push 0x80
push eax
call fcn.100015f0
lea eax, [ebp - 0x88]
mov edx, 0x1004ca20
push eax
push ebx
call fcn.10001280
add esp, 0x18
push 0
push 0
push 0xffffffffffffffff
push 0x80004004
mov edx, 0x13
mov ecx, ebx
call fcn.10010570
add esp, 0x10
mov cl, byte [ebx + 0xd6]
sub cl, 1
mov byte [ebp - 0x131], cl
je 0x1001756a
movzx eax, cl
imul esi, eax, 0x98
add esi, 0x100
add esi, ebx
test byte [esi + 1], 0x10
jne 0x10017558
test byte [0x10059abb], 0x80
je 0x10017549
movzx eax, byte [esi]
push eax
push str.Removing_invalid_path__hhu_
push 0xffffffffffffffff
lea eax, [ebp - 0x88]
push 0x80
push eax
call fcn.100015f0
add esp, 0x14
lea eax, [ebp - 0x88]
mov edx, 0x1004ccf8
push eax
push ebx
call fcn.10001280
mov cl, byte [ebp - 0x131]
add esp, 8
mov dl, cl
mov ecx, ebx
call fcn.1002ef00
mov cl, byte [ebp - 0x131]
dec cl
sub esi, 0x98
mov byte [ebp - 0x131], cl
test cl, cl
jne 0x10017500
test byte [ebx + 0xc2], 0x40
jne 0x1001761f
test byte [ebx + 0xc0], 8
je 0x1001761f
cmp byte [ebp - 0x137], 0
je 0x1001761f
push 2
push 2
lea eax, [ebp - 0x12c]
push eax
push 0
call dword [sym.imp.bcrypt.dll_BCryptGenRandom]
mov eax, dword [0x10058588]
not eax
and ax, word [ebp - 0x12c]
or ax, word [ebp - 0x136]
test byte [ebx + 0xc3], 2
mov word [ebx + 0xd2], ax
je 0x10017618
mov cl, byte [ebx + 0xd5]
mov eax, dword [ebx + 0x360]
mov byte [ebp - 0x129], cl
test eax, eax
je 0x100175ea
nop
or byte [eax + 8], 0x20
mov eax, dword [eax]
test eax, eax
jne 0x100175e0
mov byte [ebp - 0x131], 0
test cl, cl
je 0x10017618
xor dl, dl
mov ecx, ebx
call fcn.1000fae0
test eax, eax
je 0x10017618
mov al, byte [ebp - 0x131]
inc al
mov byte [ebp - 0x131], al
cmp al, byte [ebp - 0x129]
jb 0x100175f5
or byte [ebx + 0xc2], 0x40
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.100483f7
mov esp, ebp
pop ebp
ret