Function at 0x473650
Capabilities:
Get common file path

Disassembly:
push ebx
mov ebx, esp
sub esp, 8
and esp, 0xfffffff0
add esp, 4
push ebp
mov ebp, dword [ebx + 4]
mov dword [esp + 4], ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4c00d6
mov eax, dword fs:[0]
push eax
push ebx
sub esp, 0x738
mov eax, dword [0x66bf78]
xor eax, ebp
mov dword [ebp - 0x14], eax
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
xor eax, eax
cmp dword [0x68a4b8], eax
jne 0x473c29
mov dword [ebp - 0x714], eax
mov ecx, 0x68a4a4
mov dword [0x68a4ac], eax
mov dword [0x68a4b0], eax
mov dword [0x68a4b4], eax
mov eax, dword [0x68a4a4]
push dword [eax + 4]
call fcn.00472590
mov eax, dword [0x68a4a4]
mov dword [eax + 4], eax
mov eax, dword [0x68a4a4]
mov dword [eax], eax
mov eax, dword [0x68a4a4]
mov dword [eax + 8], eax
mov eax, dword [0x68a49c]
mov dword [0x68a4a8], 0
mov ecx, dword [eax]
mov dword [eax], eax
mov eax, dword [0x68a49c]
mov dword [eax + 4], eax
mov dword [0x68a4a0], 0
cmp ecx, dword [0x68a49c]
je 0x473725
lea ebx, [ebx]
mov esi, dword [ecx]
push ecx
call sub.MSVCR120.dll_void___cdecl_operator_delete_void__
add esp, 4
mov ecx, esi
cmp esi, dword [0x68a49c]
jne 0x473710
push str.nmap_services
lea eax, [ebp - 0x248]
mov dword [0x68a4bc], 0
push 0x200
push eax
call fcn.00425160
add esp, 0xc
cmp eax, 1
je 0x473805
call dword [sym.imp.KERNEL32.dll_GetVersion]
cmp eax, 0x80000000
push str.Unable_to_find_nmap_services___Resorting_to__etc_services
sbb esi, esi
call fcn.00431e00
add esp, 4
lea eax, [ebp - 0x248]
neg esi
push 0x1e0
push eax
je 0x473783
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
jmp 0x473789
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryA]
mov ecx, eax
test ecx, ecx
jne 0x4737b5
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
mov ecx, str.Windows
test esi, esi
mov eax, str.System
cmove eax, ecx
push eax
push str.Get_sDirectory_failed___d_____
call fcn.00431e00
add esp, 0xc
jmp 0x473805
test esi, esi
je 0x4737e6
movdqu xmm0, xmmword [str.driversetc_services]
mov eax, dword [0x4d77b0]
movdqu xmmword [ebp + ecx - 0x248], xmm0
mov dword [ebp + ecx - 0x238], eax
mov ax, word [0x4d77b4]
mov word [ebp + ecx - 0x234], ax
jmp 0x473805
movq xmm0, qword [str._services]
mov ax, word [0x4d77c0]
movq qword [ebp + ecx - 0x248], xmm0
mov word [ebp + ecx - 0x240], ax
lea eax, [ebp - 0x248]
push 0x4e1648
push eax
call dword [sym.imp.MSVCR120.dll_fopen]
mov esi, eax
add esp, 8
mov dword [ebp - 0x734], esi
test esi, esi
jne 0x473837
lea eax, [ebp - 0x248]
push eax
push str.Unable_to_open__s_for_reading_service_information
call fcn.00431e30
push str.nmap_services
lea ecx, [ebp - 0x6f0]
call fcn.00410450
lea eax, [ebp - 0x6f0]
mov dword [ebp - 4], 0
push eax
mov ecx, 0x682158
call fcn.00421220
cmp byte [ebp - 0x248], 0
mov edx, eax
jne 0x47386e
xor ecx, ecx
jmp 0x473886
lea ecx, [ebp - 0x248]
lea esi, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x473877
sub ecx, esi
mov esi, dword [ebp - 0x734]
push ecx
lea eax, [ebp - 0x248]
mov ecx, edx
push eax
call fcn.00410e10
cmp dword [ebp - 0x6dc], 0x10
mov dword [ebp - 4], 0xffffffff
jb 0x4738b3
push dword [ebp - 0x6f0]
call sub.MSVCR120.dll_void___cdecl_operator_delete_void__
add esp, 4
push esi
lea eax, [ebp - 0x6c8]
push 0x400
push eax
call dword [sym.imp.MSVCR120.dll_fgets]
add esp, 0xc
test eax, eax
je 0x473c04
mov edi, dword [sym.imp.MSVCR120.dll__strnicmp]
jmp 0x4738e0
inc dword [ebp - 0x714]
lea esi, [ebp - 0x6c8]
cmp byte [ebp - 0x6c8], 0
je 0x47390c
movzx eax, byte [esi]
push eax
call dword [sym.imp.MSVCR120.dll_isspace]
add esp, 4
test eax, eax
je 0x47390c
inc esi
cmp byte [esi], 0
jne 0x4738f5
cmp byte [esi], 0x23
je 0x473be0
lea eax, [ebp - 0x44]
push eax
lea eax, [ebp - 0x24]
push eax
lea eax, [ebp - 0x710]
push eax
lea eax, [ebp - 0x2c8]
push eax
lea eax, [ebp - 0x6c8]
push str._127s__hu__15s__31s
push eax
call dword [sym.imp.MSVCR120.dll_sscanf]
add esp, 0x18
cmp eax, 3
je 0x473a2a
cmp eax, 4
jne 0x473be0
lea eax, [ebp - 0x44]
push 0x2f
push eax
call dword [sym.imp.MSVCR120.dll_strchr]
add esp, 8
test eax, eax
je 0x4739e2
lea eax, [ebp - 0x738]
push eax
lea eax, [ebp - 0x73c]
push eax
lea eax, [ebp - 0x44]
push str._d__d
push eax
call dword [sym.imp.MSVCR120.dll_sscanf]
add esp, 0x10
cmp eax, 2
jne 0x473d70
mov ecx, dword [ebp - 0x73c]
test ecx, ecx
js 0x473d58
mov eax, dword [ebp - 0x738]
test eax, eax
js 0x473d58
cmp ecx, eax
jg 0x473d24
test eax, eax
je 0x473d0c
movd xmm1, ecx
movd xmm0, eax
cvtdq2pd xmm1, xmm1
mov dword [0x68a4bc], 1
cvtdq2pd xmm0, xmm0
divsd xmm1, xmm0
movsd qword [ebp - 0x730], xmm1
jmp 0x473a35
push 2
lea eax, [ebp - 0x44]
push 0x4d78e4
push eax
call dword [sym.imp.MSVCR120.dll_strncmp]
add esp, 0xc
test eax, eax
jne 0x473a2a
push eax
lea eax, [ebp - 0x44]
push eax
call dword [sym.imp.MSVCR120.dll_strtod]
fstp qword [ebp - 0x730]
movsd xmm0, qword [ebp - 0x730]
add esp, 8
mov dword [0x68a4bc], 1
movsd qword [ebp - 0x730], xmm0
jmp 0x473a35
xorps xmm0, xmm0
movsd qword [ebp - 0x730], xmm0
mov dword [ebp - 0x6f4], 0xf
mov dword [ebp - 0x6f8], 0
mov byte [ebp - 0x708], 0
cmp byte [ebp - 0x24], 0
movzx eax, word [ebp - 0x710]
mov dword [ebp - 4], 1
mov dword [ebp - 0x70c], eax
jne 0x473a6e
xor ecx, ecx
jmp 0x473a7d
lea ecx, [ebp - 0x24]
lea edx, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x473a74
sub ecx, edx
push ecx
lea eax, [ebp - 0x24]
push eax
lea ecx, [ebp - 0x708]
call fcn.00410e10
lea eax, [ebp - 0x70c]
mov ecx, 0x68a4a4
push eax
lea eax, [ebp - 0x740]
push eax
call fcn.00472c00
mov eax, dword [eax]
cmp eax, dword [0x68a4a4]
je 0x473ae1
cmp dword [0x67dff0], 0
je 0x473bc2
lea eax, [ebp - 0x248]
push eax
lea eax, [ebp - 0x24]
push eax
movzx eax, word [ebp - 0x710]
push eax
push str.Port__d_proto__s_is_duplicated_in_services_file__s
call fcn.00431e00
add esp, 0x10
jmp 0x473bc2
push 3
lea eax, [ebp - 0x24]
push 0x4e165c
push eax
call edi
add esp, 0xc
test eax, eax
jne 0x473c47
inc dword [0x68a4ac]
lea eax, [ebp - 0x2c8]
push eax
call fcn.00410270
mov dword [ebp - 0x6f0], eax
mov ax, word [ebp - 0x710]
mov word [ebp - 0x6e8], ax
lea eax, [ebp - 0x24]
push eax
call fcn.00410270
movsd xmm0, qword [ebp - 0x730]
add esp, 8
mov dword [ebp - 0x6e4], eax
mov ecx, 0x68a4a4
lea eax, [ebp - 0x70c]
mov dword [ebp - 0x6ec], 0
movsd qword [ebp - 0x6e0], xmm0
push eax
call fcn.004723c0
movdqu xmm0, xmmword [ebp - 0x6f0]
lea ecx, [ebp - 0x6f0]
push ecx
movdqu xmmword [eax], xmm0
mov ecx, 0x68a49c
movsd xmm0, qword [ebp - 0x730]
movq qword [eax + 0x10], xmm0
mov eax, dword [0x68a49c]
mov dword [ebp - 0x72c], eax
push dword [eax + 4]
push eax
call fcn.00471940
mov edx, dword [0x68a4a0]
mov ecx, 0x7fffffe
sub ecx, edx
mov esi, eax
cmp ecx, 1
jb 0x473d8c
mov eax, dword [ebp - 0x72c]
inc edx
mov dword [0x68a4a0], edx
mov dword [eax + 4], esi
mov eax, dword [esi + 4]
mov dword [eax], esi
cmp dword [ebp - 0x6f4], 0x10
mov dword [ebp - 4], 0xffffffff
jb 0x473be0
push dword [ebp - 0x708]
call sub.MSVCR120.dll_void___cdecl_operator_delete_void__
add esp, 4
mov esi, dword [ebp - 0x734]
lea eax, [ebp - 0x6c8]
push esi
push 0x400
push eax
call dword [sym.imp.MSVCR120.dll_fgets]
add esp, 0xc
test eax, eax
jne 0x4738e0
push 0x473dc0
mov ecx, 0x68a49c
call fcn.00472040
push esi
call dword [sym.imp.MSVCR120.dll_fclose]
add esp, 4
mov dword [0x68a4b8], 1
xor eax, eax
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov ecx, dword [ebp - 0x14]
xor ecx, ebp
call fcn.004bb11e
mov esp, ebp
pop ebp
mov esp, ebx
pop ebx
ret
push 3
lea eax, [ebp - 0x24]
push 0x4e1658
push eax
call edi
add esp, 0xc
test eax, eax
jne 0x473c66
inc dword [0x68a4b0]
jmp 0x473aff
push 4
lea eax, [ebp - 0x24]
push str.sctp
push eax
call edi
add esp, 0xc
test eax, eax
jne 0x473c85
inc dword [0x68a4b4]
jmp 0x473aff
push 3
lea eax, [ebp - 0x24]
push 0x4d791c
push eax
call edi
add esp, 0xc
test eax, eax
je 0x473aff
push 6
lea eax, [ebp - 0x24]
push str.divert
push eax
call edi
add esp, 0xc
test eax, eax
je 0x473aff
push 1
lea eax, [ebp - 0x24]
push 0x4e1638
push eax
call edi
add esp, 0xc
test eax, eax
je 0x473aff
cmp dword [0x67dff0], 0
je 0x473cf5
lea eax, [ebp - 0x248]
push eax
mov eax, dword [ebp - 0x714]
push eax
lea eax, [ebp - 0x24]
push eax
push str.Unknown_protocol___s__on_line__d_of_services_file__s.
call fcn.00431e00
add esp, 0x10
lea ecx, [ebp - 0x70c]
mov dword [ebp - 4], 0xffffffff
call fcn.00472390
jmp 0x473be0
mov eax, dword [ebp - 0x714]
push eax
lea eax, [ebp - 0x248]
push eax
push str._s:_d_has_a_ratio_denominator_of_0_causing_a_division_by_0_error
call fcn.00431e30
movd xmm0, eax
sub esp, 8
movd xmm1, ecx
cvtdq2pd xmm1, xmm1
mov eax, dword [ebp - 0x714]
cvtdq2pd xmm0, xmm0
divsd xmm1, xmm0
movsd qword [esp], xmm1
push eax
lea eax, [ebp - 0x248]
push eax
push str._s:_d_has_a_ratio__g._All_ratios_must_be___1
call fcn.00431e30
mov eax, dword [ebp - 0x714]
push eax
lea eax, [ebp - 0x248]
push eax
push str._s:_d_contains_an_invalid_negative_value
call fcn.00431e30
lea eax, [ebp - 0x44]
push eax
mov eax, dword [ebp - 0x714]
push eax
lea eax, [ebp - 0x248]
push eax
push str._s:_d_contains_invalid_port_ratio_string:__s
call fcn.00431e30
push str.list_T__too_long
call dword [sym.imp.MSVCP120.dll_void___cdecl_std::_Xlength_error_char_const__]
int3