Function at 0x408040
Capabilities:
Enumerate files on windows
Get number of processors
Read .ini file
Resolve function by parsing pe exports

Disassembly:
push 0xffffffffffffffff
push 0x417db3
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x464
mov al, byte [esp + 3]
push ebx
push ebp
push esi
xor ebp, ebp
push edi
push ebp
lea ecx, [esp + 0x24]
mov dword [esp + 0x34], ebp
mov dword [esp + 0x1c], ebp
mov byte [esp + 0x24], al
call fcn.00401d10
mov edi, str.GetInfFile____key:__
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
push ecx
push str.GetInfFile____key:__
lea ecx, [esp + 0x28]
call fcn.00402330
mov edx, dword [esp + 0x484]
or ecx, 0xffffffff
mov edi, edx
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
mov dword [esp + 0x47c], ebp
push ecx
push edx
lea ecx, [esp + 0x28]
call fcn.0040f3d0
mov edi, str.____dir:
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
push ecx
push str.____dir:
lea ecx, [esp + 0x28]
call fcn.0040f3d0
mov ebx, dword [esp + 0x488]
or ecx, 0xffffffff
mov edi, ebx
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
push ecx
push ebx
lea ecx, [esp + 0x28]
call fcn.0040f3d0
mov edi, 0x41c2dc
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
push ecx
push 0x41c2dc
lea ecx, [esp + 0x28]
call fcn.0040f3d0
mov cl, byte [esp + 0x20]
sub esp, 0x10
mov esi, esp
mov dword [esp + 0x2c], esp
push ebp
mov byte [esi], cl
mov ecx, esi
call fcn.00401d10
mov edx, dword [0x419218]
lea eax, [esp + 0x30]
push edx
push ebp
push eax
mov ecx, esi
call fcn.00401b10
call fcn.004051f0
add esp, 0x10
lea ecx, [esp + 0x20]
mov dword [esp + 0x47c], 0xffffffff
push 1
call fcn.00401d10
mov ecx, 0xd
xor eax, eax
lea edi, [esp + 0xa5]
mov byte [esp + 0xa4], 0
rep stosd dword es:[edi], eax
mov ebp, dword [esp + 0x48c]
push str.Windows_Millenium
stosw word es:[edi], ax
push ebp
stosb byte es:[edi], al
call fcn.004104a7
add esp, 8
test eax, eax
je 0x4081a7
push str.Windows_98
push ebp
call fcn.004104a7
add esp, 8
test eax, eax
jne 0x4081d0
mov edi, str._Chicago_
or ecx, 0xffffffff
xor eax, eax
lea edx, [esp + 0xa4]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
mov esi, edi
mov edi, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
push str.Windows_Whistler
push ebp
call fcn.004104a7
add esp, 8
test eax, eax
je 0x4081f4
push str.Windows_2000
push ebp
call fcn.004104a7
add esp, 8
test eax, eax
jne 0x40821d
mov edi, str._Windows_NT_
or ecx, 0xffffffff
xor eax, eax
lea edx, [esp + 0xa4]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
mov esi, edi
mov edi, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov cl, byte [esp + 0x13]
push 0
mov byte [esp + 0x58], cl
lea ecx, [esp + 0x58]
call fcn.00401d10
mov edi, ebx
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
push ecx
push ebx
lea ecx, [esp + 0x5c]
call fcn.00402330
mov eax, dword [esp + 0x5c]
mov dword [esp + 0x47c], 1
lea esi, [eax - 1]
cmp eax, esi
jb 0x408276
mov eax, dword [esp + 0x58]
test eax, eax
je 0x408276
lea ecx, [esp + 0x54]
call fcn.0040f150
mov edx, dword [esp + 0x58]
add esi, edx
jmp 0x40827b
mov esi, 0x41921c
cmp byte [esi], 0x5c
je 0x40829e
mov edi, 0x41c1cc
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
push ecx
push 0x41c1cc
lea ecx, [esp + 0x5c]
call fcn.0040f3d0
lea eax, [esp + 0x54]
push str..inf
lea ecx, [esp + 0x98]
push eax
push ecx
call fcn.0040f530
add esp, 0xc
mov eax, dword [esp + 0x98]
mov byte [esp + 0x47c], 2
test eax, eax
jne 0x4082d0
mov eax, 0x41921c
lea edx, [esp + 0x140]
push edx
push eax
call dword [sym.imp.KERNEL32.dll_FindFirstFileA]
cmp eax, 0xffffffff
mov dword [esp + 0x1c], eax
je 0x40891c
mov bl, byte [esp + 0x13]
mov eax, dword [esp + 0x18]
test eax, eax
jne 0x40891c
mov al, byte [esp + 0x13]
push 0
lea ecx, [esp + 0x24]
mov byte [esp + 0x24], al
call fcn.00401d10
mov edi, str.processing:
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
push ecx
push str.processing:
lea ecx, [esp + 0x28]
call fcn.00402330
lea edi, [esp + 0x16c]
or ecx, 0xffffffff
xor eax, eax
mov byte [esp + 0x47c], 3
repne scasb al, byte es:[edi]
not ecx
dec ecx
push ecx
lea ecx, [esp + 0x170]
push ecx
lea ecx, [esp + 0x28]
call fcn.0040f3d0
mov edi, 0x41c2dc
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
push ecx
push 0x41c2dc
lea ecx, [esp + 0x28]
call fcn.0040f3d0
mov dl, byte [esp + 0x20]
sub esp, 0x10
mov esi, esp
mov dword [esp + 0x24], esp
push 0
mov ecx, esi
mov byte [esi], dl
call fcn.00401d10
mov eax, dword [0x419218]
lea ecx, [esp + 0x30]
push eax
push 0
push ecx
mov ecx, esi
call fcn.00401b10
call fcn.004051f0
add esp, 0x10
lea ecx, [esp + 0x20]
mov byte [esp + 0x47c], 2
push 1
call fcn.00401d10
mov eax, dword [0x41fb8c]
test eax, eax
jne 0x4084ab
mov ebp, dword [esp + 0x494]
mov esi, dword [ebp + 4]
mov eax, dword [ebp + 8]
cmp esi, eax
jae 0x4084ab
mov dl, byte [esi]
push 0
lea ecx, [esp + 0x88]
mov byte [esp + 0x88], dl
call fcn.00401d10
mov eax, dword [0x419218]
lea ecx, [esp + 0x84]
push eax
push 0
push esi
call fcn.00401b10
push 0
lea ecx, [esp + 0x78]
mov byte [esp + 0x480], 4
mov byte [esp + 0x78], bl
call fcn.00401d10
lea edi, [esp + 0x16c]
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
push ecx
lea ecx, [esp + 0x170]
push ecx
lea ecx, [esp + 0x7c]
call fcn.00402330
mov eax, dword [esp + 0x88]
test eax, eax
jne 0x408455
mov eax, 0x41921c
mov ecx, dword [esp + 0x78]
test ecx, ecx
jne 0x408462
mov ecx, 0x41921c
push eax
push ecx
call fcn.004106ff
add esp, 8
mov byte [esp + 0x47c], 4
test eax, eax
push 1
lea ecx, [esp + 0x78]
je 0x40864c
call fcn.00401d10
push 1
lea ecx, [esp + 0x88]
mov byte [esp + 0x480], 2
call fcn.00401d10
mov eax, dword [ebp + 8]
add esi, 0x10
cmp esi, eax
jb 0x4083df
lea ecx, [esp + 0x16c]
lea edx, [esp + 0x54]
push ecx
lea eax, [esp + 0x38]
push edx
push eax
call fcn.0040f530
push ecx
mov cl, byte [esp + 0x44]
mov esi, esp
mov dword [esp + 0x24], esp
push 0
mov byte [esp + 0x490], 6
mov byte [esi], cl
mov ecx, esi
call fcn.00401d10
mov edx, dword [0x419218]
lea eax, [esp + 0x44]
push edx
push 0
push eax
mov ecx, esi
call fcn.00401b10
call fcn.0040e360
add esp, 0x10
test eax, eax
je 0x408509
mov dword [esp + 0x30], 1
mov ecx, 0x18
xor eax, eax
lea edi, [esp + 0xdd]
mov byte [esp + 0xdc], 0
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
mov eax, dword [esp + 0x38]
test eax, eax
jne 0x408531
mov eax, 0x41921c
mov esi, dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
push eax
lea ecx, [esp + 0xe0]
push 0x64
push ecx
push 0x41fa60
push str.Signature
push str.Version
call esi
lea edx, [esp + 0xa4]
lea eax, [esp + 0xdc]
push edx
push eax
call fcn.004104a7
add esp, 8
test eax, eax
jne 0x40883a
mov eax, dword [esp + 0x38]
test eax, eax
jne 0x408580
mov eax, 0x41921c
push eax
lea ecx, [esp + 0xe0]
push 0x64
push ecx
push str.Manufacturer
push 0
push str.Manufacturer
call esi
lea edx, [esp + 0xdc]
mov dword [esp + 0x14], 0
test edx, edx
lea ebx, [esp + 0xdc]
je 0x40889a
xor ebp, ebp
cmp dword [esp + 0x14], ebp
jne 0x4086b8
mov eax, dword [esp + 0x38]
cmp eax, ebp
jne 0x4085d0
mov eax, 0x41921c
push eax
lea eax, [esp + 0x284]
push 0x1f4
push eax
push 0x41fa60
push ebx
push str.Manufacturer
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
lea ecx, [esp + 0x280]
push 0x41c794
push ecx
call fcn.00410630
mov esi, eax
add esp, 8
cmp esi, ebp
je 0x408694
mov edi, dword [esp + 0x14]
cmp edi, ebp
jne 0x408690
push str.Intel
push esi
call fcn.004104a7
add esp, 8
test eax, eax
je 0x408687
push str.INTEL
push esi
call fcn.004104a7
add esp, 8
test eax, eax
je 0x408687
push 0x41c794
push ebp
call fcn.00410630
add esp, 8
mov esi, eax
jmp 0x40868c
call fcn.00401d10
push 1
lea ecx, [esp + 0x88]
mov byte [esp + 0x480], 2
call fcn.00401d10
mov eax, dword [esp + 0x1c]
lea edx, [esp + 0x140]
push edx
push eax
call dword [sym.imp.KERNEL32.dll_FindNextFileA]
test eax, eax
je 0x40891c
jmp 0x4082f0
mov edi, 1
cmp esi, ebp
jne 0x408612
mov dword [esp + 0x14], edi
mov edi, ebx
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
lea ebx, [ebx + ecx + 1]
cmp ebx, ebp
jne 0x4085b9
cmp dword [esp + 0x14], ebp
je 0x40889a
xor ebp, ebp
mov ecx, dword [esp + 0x58]
cmp ecx, ebp
jne 0x4086c5
mov ecx, 0x41921c
mov eax, dword [esp + 0x38]
cmp eax, ebp
jne 0x4086d2
mov eax, 0x41921c
push ecx
push eax
call fcn.00407d20
mov dl, byte [esp + 0x1b]
mov dword [esp + 0x50], ebp
mov byte [esp + 0x4c], dl
mov dword [esp + 0x54], ebp
mov dword [esp + 0x58], ebp
lea eax, [esp + 0x4c]
mov byte [esp + 0x484], 7
push eax
call fcn.00405e80
mov ebp, dword [esp + 0x54]
mov eax, dword [esp + 0x58]
add esp, 0xc
cmp ebp, eax
mov esi, 1
jae 0x4087fb
xor ebx, ebx
cmp esi, ebx
je 0x4087fb
mov edx, dword [0x419218]
mov cl, byte [ebp]
push edx
mov byte [esp + 0x68], cl
push ebx
push ebp
lea ecx, [esp + 0x70]
mov dword [esp + 0x74], ebx
mov dword [esp + 0x78], ebx
mov dword [esp + 0x7c], ebx
call fcn.00401b10
mov ecx, dword [esp + 0x38]
mov byte [esp + 0x47c], 8
cmp ecx, ebx
jne 0x40875b
mov ecx, 0x41921c
mov eax, dword [esp + 0x68]
cmp eax, ebx
jne 0x408768
mov eax, 0x41921c
push ecx
push eax
mov eax, dword [esp + 0x48c]
push eax
call fcn.004076b0
add esp, 0xc
cmp eax, ebx
mov dword [esp + 0x18], eax
je 0x4087b3
mov edi, dword [esp + 0x38]
cmp edi, ebx
jne 0x40878f
mov edi, 0x41921c
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov edx, ecx
mov esi, edi
mov edi, dword [esp + 0x490]
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
xor esi, esi
mov eax, dword [esp + 0x68]
mov byte [esp + 0x47c], 7
cmp eax, ebx
je 0x4087e0
lea ecx, [eax - 1]
mov al, byte [eax - 1]
test al, al
je 0x4087d7
cmp al, 0xff
je 0x4087d7
dec al
mov byte [ecx], al
jmp 0x4087e0
push ecx
call fcn.0040f86e
add esp, 4
mov eax, dword [esp + 0x4c]
add ebp, 0x10
cmp ebp, eax
mov dword [esp + 0x68], ebx
mov dword [esp + 0x6c], ebx
mov dword [esp + 0x70], ebx
jb 0x408719
mov esi, dword [esp + 0x48]
mov byte [esp + 0x47c], 6
cmp esi, eax
mov edi, eax
je 0x40881d
push 1
mov ecx, esi
call fcn.00401d10
add esi, 0x10
cmp esi, edi
jne 0x40880d
mov eax, dword [esp + 0x48]
push eax
call fcn.0040f86e
add esp, 4
xor eax, eax
mov dword [esp + 0x48], eax
mov dword [esp + 0x4c], eax
mov dword [esp + 0x50], eax
jmp 0x40889a
mov cl, byte [esp + 0x13]
sub esp, 0x10
mov ebp, esp
xor eax, eax
mov edi, str.signature_section_match_for_this_OS_not_found_n
mov dword [esp + 0x24], esp
mov byte [ebp], cl
or ecx, 0xffffffff
mov dword [ebp + 4], eax
mov dword [ebp + 8], eax
mov dword [ebp + 0xc], eax
push 1
repne scasb al, byte es:[edi]
not ecx
dec ecx
mov ebx, ecx
mov ecx, ebp
push ebx
call fcn.00402510
test al, al
je 0x408892
mov edi, dword [ebp + 4]
mov ecx, ebx
mov edx, ecx
mov esi, str.signature_section_match_for_this_OS_not_found_n
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
push ebx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov ecx, ebp
call fcn.004024f0
call fcn.004051f0
add esp, 0x10
mov eax, dword [esp + 0x30]
xor esi, esi
cmp eax, esi
je 0x4088a8
mov dword [esp + 0x30], esi
mov ecx, dword [esp + 0x1c]
lea eax, [esp + 0x140]
push eax
push ecx
call dword [sym.imp.KERNEL32.dll_FindNextFileA]
mov ecx, dword [esp + 0x38]
cmp eax, esi
mov byte [esp + 0x47c], 2
je 0x4088fc
cmp ecx, esi
je 0x4088eb
mov al, byte [ecx - 1]
test al, al
je 0x4088e1
cmp al, 0xff
je 0x4088e1
dec al
mov byte [ecx - 1], al
jmp 0x4088eb
dec ecx
push ecx
call fcn.0040f86e
add esp, 4
mov dword [esp + 0x38], esi
mov dword [esp + 0x3c], esi
mov dword [esp + 0x40], esi
jmp 0x4082ec
cmp ecx, esi
je 0x40891c
mov al, byte [ecx - 1]
test al, al
je 0x408912
cmp al, 0xff
je 0x408912
dec al
mov byte [ecx - 1], al
jmp 0x40891c
dec ecx
push ecx
call fcn.0040f86e
add esp, 4
mov dl, byte [esp + 0x13]
sub esp, 0x10
mov ebx, esp
xor esi, esi
mov edi, str.done_processing_infs_in_this_directory_n
or ecx, 0xffffffff
xor eax, eax
mov byte [ebx], dl
mov dword [ebx + 4], esi
mov dword [ebx + 8], esi
mov dword [ebx + 0xc], esi
mov dword [esp + 0x2c], esp
repne scasb al, byte es:[edi]
not ecx
dec ecx
push 1
mov ebp, ecx
mov ecx, ebx
push ebp
call fcn.00402510
test al, al
je 0x408977
mov edi, dword [ebx + 4]
mov ecx, ebp
mov eax, ecx
mov esi, str.done_processing_infs_in_this_directory_n
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
push ebp
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov ecx, ebx
call fcn.004024f0
xor esi, esi
call fcn.004051f0
mov ecx, dword [esp + 0xa8]
add esp, 0x10
cmp ecx, esi
je 0x4089a6
mov al, byte [ecx - 1]
test al, al
je 0x40899c
cmp al, 0xff
je 0x40899c
dec al
mov byte [ecx - 1], al
jmp 0x4089a6
dec ecx
push ecx
call fcn.0040f86e
add esp, 4
mov ecx, dword [esp + 0x58]
mov dword [esp + 0x98], esi
cmp ecx, esi
mov dword [esp + 0x9c], esi
mov dword [esp + 0xa0], esi
je 0x4089df
mov al, byte [ecx - 1]
test al, al
je 0x4089d5
cmp al, 0xff
je 0x4089d5
dec al
mov byte [ecx - 1], al
jmp 0x4089df
dec ecx
push ecx
call fcn.0040f86e
add esp, 4
mov ecx, dword [esp + 0x474]
mov eax, dword [esp + 0x18]
pop edi
pop esi
pop ebp
mov dword fs:[0], ecx
pop ebx
add esp, 0x470
ret