Function at 0x407261
Capabilities:
Connect to wmi namespace via wbemlocator
Reference absolute stream path on windows

Disassembly:
push 0x47c
mov eax, 0x41a5a3
call fcn.00409e37
xor eax, eax
mov edi, 0x206
push edi
mov word [ebp - 0x218], ax
xor esi, esi
lea eax, [ebp - 0x216]
push esi
push eax
call fcn.004087d0
add esp, 0xc
lea eax, [ebp - 0x428]
push eax
push 0x41e540
xor ebx, ebx
inc ebx
push ebx
push esi
push 0x41e610
mov dword [ebp - 0x428], esi
call dword [sym.imp.ole32.dll_CoCreateInstance]
cmp eax, esi
jl 0x40766a
push str.ROOTCIMV2
mov dword [ebp - 0x424], esi
lea ecx, [ebp - 0x434]
call fcn.00404c0a
mov eax, dword [eax]
mov dword [ebp - 4], esi
cmp eax, esi
je 0x4072e4
mov eax, dword [eax]
mov dword [ebp - 0x42c], eax
jmp 0x4072ea
mov dword [ebp - 0x42c], esi
lea edx, [ebp - 0x424]
mov eax, dword [ebp - 0x428]
mov ecx, dword [eax]
push edx
push esi
push esi
push esi
push esi
push esi
push esi
push dword [ebp - 0x42c]
push eax
call dword [ecx + 0xc]
mov ecx, dword [ebp - 0x434]
or dword [ebp - 4], 0xffffffff
mov dword [ebp - 0x438], eax
cmp ecx, esi
je 0x407322
call fcn.00404c57
cmp dword [ebp - 0x438], esi
jge 0x407345
mov eax, dword [ebp - 0x428]
cmp eax, esi
je 0x40733a
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
mov eax, dword [ebp - 0x424]
jmp 0x407660
push esi
push esi
push 3
push 3
push esi
push esi
push 0xa
push dword [ebp - 0x424]
call dword [sym.imp.ole32.dll_CoSetProxyBlanket]
or eax, eax
js 0x40764a
xor eax, eax
push edi
mov word [ebp - 0x420], ax
lea eax, [ebp - 0x41e]
push esi
push eax
call fcn.004087d0
push dword [ebp + 8]
lea eax, [ebp - 0x420]
push str.._rootCIMV2:Win32_NetworkAdapterConfiguration.Index
push str._s_d
push eax
call fcn.00404804
mov edi, dword [sym.imp.OLEAUT32.dll_SysReAllocString]
add esp, 0x1c
lea eax, [ebp - 0x420]
push eax
call edi
push str.SetGateways
mov dword [ebp - 0x454], eax
call edi
push str.Win32_NetworkAdapterConfiguration
mov dword [ebp - 0x434], eax
call edi
mov ecx, dword [ebp - 0x424]
push esi
lea edx, [ebp - 0x444]
push edx
push esi
mov dword [ebp - 0x42c], eax
push esi
push dword [ebp - 0x42c]
mov dword [ebp - 0x444], esi
mov dword [ebp - 0x440], esi
mov dword [ebp - 0x430], esi
mov dword [ebp - 0x43c], esi
mov eax, dword [ecx]
push ecx
call dword [eax + 0x18]
test eax, eax
jns 0x407425
mov eax, dword [ebp - 0x424]
cmp eax, esi
je 0x40740d
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
mov eax, dword [ebp - 0x428]
cmp eax, esi
je 0x40741d
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
or eax, 0xffffffff
jmp 0x40766c
lea edx, [ebp - 0x440]
mov eax, dword [ebp - 0x444]
mov ecx, dword [eax]
push esi
push edx
push esi
push dword [ebp - 0x434]
push eax
call dword [ecx + 0x4c]
or eax, eax
js 0x4073fd
lea edx, [ebp - 0x430]
mov eax, dword [ebp - 0x440]
mov ecx, dword [eax]
push edx
push esi
push eax
call dword [ecx + 0x3c]
test eax, eax
js 0x4073fd
lea eax, [ebp - 0x218]
push eax
push dword [ebp + 0xc]
call fcn.00402851
lea eax, [ebp - 0x218]
pop ecx
pop ecx
push eax
call edi
mov edi, dword [sym.imp.OLEAUT32.dll_SafeArrayDestroy]
mov dword [ebp - 0x42c], eax
mov eax, 0x2008
mov word [ebp - 0x478], ax
lea eax, [ebp - 0x450]
push eax
push ebx
push 8
mov dword [ebp - 0x458], ebx
mov dword [ebp - 0x450], ebx
mov dword [ebp - 0x44c], esi
mov dword [ebp - 0x448], esi
call edi
push dword [ebp - 0x42c]
mov ebx, dword [sym.imp.OLEAUT32.dll_SafeArrayCopy]
lea ecx, [ebp - 0x448]
push ecx
push eax
mov dword [ebp - 0x470], eax
call ebx
mov eax, 0x2017
mov word [ebp - 0x468], ax
lea eax, [ebp - 0x450]
push eax
push 1
push 0x17
call edi
lea ecx, [ebp - 0x458]
push ecx
lea ecx, [ebp - 0x448]
push ecx
push eax
mov dword [ebp - 0x460], eax
call ebx
mov eax, dword [ebp - 0x430]
lea edx, [ebp - 0x478]
mov ecx, dword [eax]
push esi
push edx
push esi
push str.DefaultIPGateway
push eax
call dword [ecx + 0x14]
or eax, eax
js 0x4073fd
mov eax, dword [ebp - 0x430]
lea edx, [ebp - 0x468]
mov ecx, dword [eax]
push esi
push edx
push esi
push str.GatewayCostMetric
push eax
call dword [ecx + 0x14]
cmp eax, esi
jge 0x407549
cmp eax, 0x80041005
jne 0x4073fd
mov eax, dword [ebp - 0x424]
mov ecx, dword [eax]
lea edx, [ebp - 0x43c]
push esi
push edx
push dword [ebp - 0x430]
push esi
push esi
push dword [ebp - 0x434]
push dword [ebp - 0x454]
push eax
call dword [ecx + 0x60]
cmp eax, esi
jl 0x4073fd
push str.ReturnValue
lea ecx, [ebp - 0x438]
call fcn.00404c0a
mov eax, dword [eax]
xor ebx, ebx
inc ebx
cmp eax, esi
mov dword [ebp - 4], ebx
je 0x407599
mov ecx, dword [eax]
jmp 0x40759b
xor ecx, ecx
mov eax, dword [ebp - 0x43c]
lea edi, [ebp - 0x488]
mov edx, dword [eax]
push esi
push esi
push edi
push esi
push ecx
push eax
call dword [edx + 0x10]
mov edi, eax
mov ecx, dword [ebp - 0x438]
or dword [ebp - 4], 0xffffffff
cmp ecx, esi
je 0x4075cd
call fcn.00404c57
mov dword [ebp - 0x438], esi
cmp edi, esi
jl 0x4073fd
cmp dword [ebp - 0x42c], esi
je 0x4075e9
push dword [ebp - 0x42c]
call dword [sym.imp.OLEAUT32.dll_SysStringLen]
mov eax, dword [ebp - 0x444]
cmp eax, esi
je 0x4075f9
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
mov eax, dword [ebp - 0x440]
cmp eax, esi
je 0x407609
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
mov eax, dword [ebp - 0x43c]
cmp eax, esi
je 0x407619
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
mov eax, dword [ebp - 0x430]
cmp eax, esi
je 0x407629
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
mov edi, dword [sym.imp.OLEAUT32.dll_VariantCopy]
lea eax, [ebp - 0x478]
push eax
call edi
lea eax, [ebp - 0x468]
push eax
call edi
lea eax, [ebp - 0x488]
push eax
call edi
mov eax, dword [ebp - 0x424]
cmp eax, esi
je 0x40765a
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
mov eax, dword [ebp - 0x428]
cmp eax, esi
je 0x40766a
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
mov eax, ebx
call fcn.00409e81
ret