Function at 0x416380
Capabilities:
Enumerate files on windows
Get common file path

Disassembly:
push 0xffffffffffffffff
push 0x468358
mov eax, dword fs:[0]
push eax
sub esp, 0xcfc
mov eax, dword [0x48807c]
xor eax, esp
mov dword [esp + 0xcf8], eax
push ebx
push ebp
push esi
push edi
mov eax, dword [0x48807c]
xor eax, esp
push eax
lea eax, [esp + 0xd10]
mov dword fs:[0], eax
mov eax, dword [esp + 0xd24]
mov edi, dword [esp + 0xd20]
mov dword [esp + 0x24], ecx
xor ebp, ebp
lea ecx, [esp + 0x4c]
mov dword [esp + 0x2c], edi
mov dword [esp + 0x18], eax
mov dword [esp + 0x28], ebp
call fcn.00407e20
lea ecx, [esp + 0x64]
mov dword [esp + 0xd18], ebp
call fcn.00407e20
xor esi, esi
mov byte [esp + 0xd18], 1
cmp edi, ebp
je 0x416409
cmp word [edi], bp
je 0x416409
mov esi, edi
lea ecx, [esp + 0x1c]
push ecx
lea edx, [esp + 0x24]
push edx
push ebp
push ebp
push 3
push ebp
push esi
mov dword [esp + 0x3c], ebp
mov dword [esp + 0x38], ebp
call sub.WINSPOOL.DRV_EnumPrinterDriversW
mov eax, dword [esp + 0x20]
cmp eax, ebp
je 0x4164aa
push eax
call fcn.00453c61
mov edx, dword [esp + 0x24]
add esp, 4
mov ebx, eax
lea eax, [esp + 0x1c]
push eax
lea ecx, [esp + 0x24]
push ecx
push edx
push ebx
push 3
push ebp
push esi
call sub.WINSPOOL.DRV_EnumPrinterDriversW
test eax, eax
je 0x41649b
xor ebp, ebp
cmp dword [esp + 0x1c], ebp
jle 0x41649b
lea edi, [ebx + 4]
push 0x208
call fcn.00453c61
mov edx, dword [edi]
add esp, 4
mov esi, eax
movzx ecx, word [edx]
mov word [esi], cx
add edx, 2
add esi, 2
test cx, cx
jne 0x416472
push 0xffffffffffffffff
push 1
push eax
lea ecx, [esp + 0x70]
call fcn.00403750
inc ebp
add edi, 0x28
cmp ebp, dword [esp + 0x1c]
jl 0x416461
push ebx
call fcn.00453c56
mov edi, dword [esp + 0x30]
add esp, 4
xor ebp, ebp
mov eax, dword [esp + 0x18]
push eax
push edi
push str.RemovePrinterInfs_____s___s__n
call fcn.004454c0
add esp, 0xc
cmp edi, ebp
mov ebp, dword [sym.imp.USER32.dll_wsprintfW]
je 0x4164e2
cmp word [edi], 0
je 0x4164e2
push edi
lea ecx, [esp + 0x900]
push str._s_admin_
push ecx
call ebp
add esp, 0xc
jmp 0x4164f5
push 0x104
lea edx, [esp + 0x900]
push edx
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryW]
lea eax, [esp + 0x8fc]
push eax
lea ecx, [esp + 0x6f8]
push str._sinfoem.inf
push ecx
call ebp
add esp, 0xc
lea edx, [esp + 0x94]
push edx
lea eax, [esp + 0x6f8]
push eax
call dword [sym.imp.KERNEL32.dll_FindFirstFileW]
mov edi, eax
mov dword [esp + 0x30], edi
cmp edi, 0xffffffff
je 0x4167c9
lea ecx, [esp + 0xc0]
push ecx
lea edx, [esp + 0x900]
push edx
lea eax, [esp + 0x6fc]
push str._sinf_s
push eax
call ebp
push 0x4fc8
call fcn.004534f0
add esp, 0x14
mov dword [esp + 0x14], eax
mov byte [esp + 0xd18], 2
test eax, eax
je 0x416589
push 0
lea ecx, [esp + 0x6f8]
push ecx
mov ecx, eax
call fcn.00446910
mov esi, eax
mov dword [esp + 0x14], eax
jmp 0x41658f
xor esi, esi
mov dword [esp + 0x14], esi
mov edx, dword [esp + 0x18]
mov ecx, dword [esp + 0x24]
mov ecx, dword [ecx + 4]
push edx
lea eax, [esp + 0x6f8]
push eax
mov byte [esp + 0xd20], 1
call fcn.00449760
test al, al
je 0x416797
push str.Printer
mov ecx, esi
call fcn.00445ce0
push eax
call fcn.00453ad3
add esp, 8
test eax, eax
jne 0x416797
lea ecx, [esp + 0x7c]
xor bl, bl
call fcn.00407e20
lea edx, [esp + 0x7c]
push edx
mov ecx, esi
mov byte [esp + 0xd1c], 3
call fcn.00446b20
test eax, eax
je 0x416786
lea ecx, [esp + 0x34]
call fcn.00407e20
mov eax, dword [esp + 0x7c]
mov eax, dword [eax]
lea ecx, [esp + 0x34]
push ecx
mov ecx, dword [esp + 0x18]
push eax
mov byte [esp + 0xd20], 4
call fcn.00446c10
mov edi, dword [esp + 0x18]
push edi
push str.wszPrinterDriver____s__n
mov ebp, eax
call fcn.004454c0
add esp, 8
xor esi, esi
test ebp, ebp
jle 0x41675d
mov edx, dword [esp + 0x34]
mov eax, dword [edx + esi*8]
push eax
push str.___Model_in_INF_file___s__n
call fcn.004454c0
mov eax, dword [esp + 0x3c]
mov eax, dword [eax + esi*8]
push edi
push eax
call fcn.00453ad3
add esp, 0x10
test eax, eax
jne 0x416676
push str.______Found_n
call fcn.004454c0
add esp, 4
mov bl, 1
inc esi
cmp esi, ebp
jl 0x416640
test bl, bl
je 0x41675d
xor bl, bl
xor edi, edi
mov ecx, dword [esp + 0x34]
mov eax, dword [ecx + edi*8]
push eax
push str.Model_in_INF_file___s__n
call fcn.004454c0
xor esi, esi
add esp, 8
cmp dword [esp + 0x68], esi
jle 0x416715
jmp 0x4166b0
mov edx, dword [esp + 0x64]
mov ecx, dword [edx + esi*8]
lea edx, [esp + 0x2e4]
mov edi, edi
movzx eax, word [ecx]
mov word [edx], ax
add ecx, 2
add edx, 2
test ax, ax
jne 0x4166c0
lea eax, [esp + 0x2e4]
push eax
push str.___Still_Installed_Model___s__n
call fcn.004454c0
mov ecx, dword [esp + 0x3c]
mov eax, dword [ecx + edi*8]
lea edx, [esp + 0x2ec]
push edx
push eax
call fcn.00453ad3
add esp, 0x10
test eax, eax
jne 0x41670e
push str.______Shared_n
call fcn.004454c0
add esp, 4
mov bl, 1
inc esi
cmp esi, dword [esp + 0x68]
jl 0x4166b0
inc edi
cmp edi, ebp
jl 0x416687
test bl, bl
jne 0x41675d
push 0x208
call fcn.00453c61
lea ecx, [esp + 0x6f8]
mov esi, eax
mov edx, ecx
add esp, 4
sub esi, edx
lea esp, [esp]
movzx edx, word [ecx]
mov word [esi + ecx], dx
add ecx, 2
test dx, dx
jne 0x416740
push 0xffffffffffffffff
push 1
push eax
lea ecx, [esp + 0x58]
call fcn.00403750
lea ecx, [esp + 0x34]
call fcn.00401b40
lea ecx, [esp + 0x7c]
call fcn.00401b40
lea ecx, [esp + 0x34]
call fcn.00405350
mov esi, dword [esp + 0x14]
mov edi, dword [esp + 0x30]
mov ebp, dword [sym.imp.USER32.dll_wsprintfW]
lea ecx, [esp + 0x7c]
mov byte [esp + 0xd18], 1
call fcn.00405350
test esi, esi
je 0x4167ab
mov ecx, esi
call fcn.00447670
push esi
call fcn.004534ca
add esp, 4
lea eax, [esp + 0x94]
push eax
push edi
call dword [sym.imp.KERNEL32.dll_FindNextFileW]
test eax, eax
jne 0x416534
push edi
call dword [sym.imp.KERNEL32.dll_FindClose]
lea ecx, [esp + 0x64]
call fcn.00401b40
mov edi, dword [esp + 0x50]
mov ebx, dword [esp + 0x4c]
xor esi, esi
test edi, edi
jle 0x4167f6
mov eax, dword [ebx + esi*8]
push eax
push str.___INF_can_be_deleted___s__n
call fcn.004454c0
inc esi
add esp, 8
cmp esi, edi
jl 0x4167e0
mov dword [esp + 0x14], 0
test edi, edi
jle 0x416ab4
mov dword [esp + 0x28], 1
jmp 0x416814
mov ebx, dword [esp + 0x4c]
mov ecx, dword [esp + 0x14]
mov ecx, dword [ebx + ecx*8]
lea edx, [esp + 0xb04]
movzx eax, word [ecx]
mov word [edx], ax
add ecx, 2
add edx, 2
test ax, ax
jne 0x416822
push 0x4fc8
call fcn.004534f0
add esp, 4
mov dword [esp + 0x30], eax
mov byte [esp + 0xd18], 5
test eax, eax
je 0x416865
push 0
lea edx, [esp + 0xb08]
push edx
mov ecx, eax
call fcn.00446910
mov ebp, eax
jmp 0x416867
xor ebp, ebp
push 0x1f34
mov byte [esp + 0xd1c], 1
call fcn.004534f0
add esp, 4
test eax, eax
je 0x41688b
mov ecx, eax
call fcn.00405360
mov edi, eax
jmp 0x41688d
xor edi, edi
push 0x1f34
push 0
push edi
call fcn.00453450
mov eax, dword [esp + 0x38]
add esp, 0xc
test eax, eax
je 0x4168af
cmp word [eax], 0
jne 0x416a79
mov ebx, dword [esp + 0x18]
push edi
push ebx
mov ecx, ebp
call fcn.00448670
cmp word [edi + 0xe78], 0
lea esi, [edi + 0xe78]
je 0x4168ff
push esi
push 0
push 0
call sub.WINSPOOL.DRV_DeleteMonitorW
test eax, eax
je 0x4168ea
push esi
push str.PortMonitor___s__removed._n
call fcn.004454c0
add esp, 8
jmp 0x4168ff
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push esi
push str.Failed_to_remove_PortMonitor___s_____ld_n
call fcn.004454c0
add esp, 0xc
mov eax, dword [esp + 0x24]
mov ecx, dword [eax + 4]
mov eax, dword [ecx]
cmp eax, 1
je 0x416a39
cmp eax, 0x11
je 0x416a39
push 2
lea edx, [esp + 0x4f0]
push edx
push 0
push ebx
mov ecx, ebp
call fcn.00447680
test eax, eax
je 0x4169bd
lea eax, [esp + 0x4ec]
lea edx, [eax + 2]
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x416940
sub eax, edx
lea edx, [esp + 0x4ec]
push edx
sar eax, 1
xor ecx, ecx
push str.wszHardwareId____s__n
mov word [esp + eax*2 + 0x4ec], cx
call fcn.004454c0
lea eax, [esp + 0x4f4]
push eax
push str.SYSTEMCurrentControlSetEnum
lea ecx, [esp + 0x2f4]
push 0x46ab98
push ecx
call dword [sym.imp.USER32.dll_wsprintfW]
lea edx, [esp + 0x2fc]
push edx
push reloc.OLEAUT32.dll_SysReAllocString
call fcn.00451ca0
add esp, 0x20
test eax, eax
je 0x4169bd
push 0
push 1
lea eax, [esp + 0x2ec]
push eax
push reloc.OLEAUT32.dll_SysReAllocString
call fcn.00451c80
add esp, 0x10
push 2
lea ecx, [esp + 0x4f0]
push ecx
push 1
push ebx
mov ecx, ebp
call fcn.00447680
test eax, eax
je 0x416a39
lea edx, [esp + 0x4ec]
push edx
push str.wszHardwareId____s__n
call fcn.004454c0
lea eax, [esp + 0x4f4]
push eax
push str.SYSTEMCurrentControlSetEnum
lea ecx, [esp + 0x2f4]
push 0x46ab98
push ecx
call dword [sym.imp.USER32.dll_wsprintfW]
lea edx, [esp + 0x2fc]
push edx
push reloc.OLEAUT32.dll_SysReAllocString
call fcn.00451ca0
add esp, 0x20
test eax, eax
je 0x416a39
push 0
push 1
lea eax, [esp + 0x2ec]
push eax
push reloc.OLEAUT32.dll_SysReAllocString
call fcn.00451c80
add esp, 0x10
lea ecx, [edi + 0x1f1c]
call fcn.00405350
lea ecx, [edi + 0x1f04]
call fcn.00405350
lea ecx, [edi + 0x1eec]
call fcn.00405350
lea ecx, [edi + 0x1ed4]
call fcn.00405350
lea ecx, [edi + 0x1ebc]
call fcn.00405350
push edi
call fcn.004534ca
add esp, 4
mov edx, dword [esp + 0x24]
lea ecx, [esp + 0xb04]
push ecx
mov ecx, dword [edx + 4]
call fcn.0044a070
test ebp, ebp
je 0x416aa1
mov ecx, ebp
call fcn.00447670
push ebp
call fcn.004534ca
add esp, 4
mov eax, dword [esp + 0x14]
inc eax
cmp eax, dword [esp + 0x50]
mov dword [esp + 0x14], eax
jl 0x416810
lea ecx, [esp + 0x4c]
call fcn.00401b40
lea ecx, [esp + 0x64]
call fcn.00405350
lea ecx, [esp + 0x4c]
call fcn.00405350
mov eax, dword [esp + 0x28]
mov ecx, dword [esp + 0xd10]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0xcf8]
xor ecx, esp
call fcn.00453432
add esp, 0xd08
ret 8