Function at 0x40e850
Capabilities:
Get disk information

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x5922a1
mov eax, dword fs:[0]
push eax
sub esp, 0x430
mov eax, dword [0x5fcffc]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov ebx, ecx
mov dword [ebp - 0x430], ebx
xor eax, eax
push 0x208
push eax
mov dword [ebp - 0x43c], eax
lea eax, [ebp - 0x218]
push eax
call fcn.005711a0
add esp, 0xc
call fcn.004255be
mov ecx, eax
test ecx, ecx
je 0x40ec67
mov eax, dword [ecx]
call dword [eax + 0xc]
add eax, 0x10
mov dword [ebp - 0x428], eax
push 0x5daa4c
lea ecx, [ebp - 0x428]
mov dword [ebp - 4], 0
call fcn.00402a50
test al, al
jne 0x40e8ed
push 0
push 0x5daa4c
lea ecx, [ebp - 0x428]
call fcn.00403260
mov dword [ebp - 4], 1
call fcn.004255be
mov ecx, eax
test ecx, ecx
je 0x40ec71
mov eax, dword [ecx]
call dword [eax + 0xc]
add eax, 0x10
mov dword [ebp - 0x424], eax
push 0x5daa4c
lea ecx, [ebp - 0x424]
mov byte [ebp - 4], 2
call fcn.00402a50
test al, al
jne 0x40e93b
push 0
push 0x5daa4c
lea ecx, [ebp - 0x424]
call fcn.00403260
push 0x208
lea eax, [ebp - 0x420]
mov byte [ebp - 4], 3
push 0
push eax
lea esi, [ebx + 0x380]
call fcn.005711a0
add esp, 0xc
mov ecx, esi
call fcn.004233a0
call dword [sym.imp.KERNEL32.dll_GetLogicalDrives]
mov ecx, eax
xor bl, bl
mov eax, 1
mov dword [ebp - 0x438], ecx
mov dword [ebp - 0x434], eax
and ecx, eax
lea edi, [eax + 0x40]
test ecx, ecx
je 0x40e9d3
push edi
lea eax, [ebp - 0x420]
push str._c:_
push eax
call dword [sym.imp.USER32.dll_wsprintfW]
add esp, 0xc
lea eax, [ebp - 0x420]
push eax
call dword [sym.imp.KERNEL32.dll_GetDriveTypeW]
cmp eax, 3
jne 0x40e9cd
mov al, bl
mov ecx, esi
sub al, 2
movzx eax, al
push eax
call fcn.00423400
test eax, eax
je 0x40e9c7
inc byte [esi + 0x80]
inc byte [esi + 0x81]
mov eax, dword [ebp - 0x434]
mov ecx, dword [ebp - 0x438]
add eax, eax
inc bl
mov dword [ebp - 0x434], eax
and ecx, eax
inc edi
cmp bl, 0x20
jb 0x40e982
mov edi, dword [ebp - 0x430]
xor al, al
mov byte [ebp - 0x429], al
cmp byte [edi + 0x400], al
jbe 0x40eb59
movzx eax, al
imul eax, eax, 0x1120
mov dword [ebp - 0x434], 0xff
add eax, 0x151d
add eax, edi
xor ebx, ebx
mov dword [ebp - 0x438], eax
nop word [eax + eax]
mov esi, dword [edi + 0x22814]
mov ecx, esi
mov al, byte [eax]
movzx edx, al
shl edx, 0x10
mov eax, dword [esi + 4]
or edx, ebx
cmp byte [eax + 0xd], 0
jne 0x40ea64
nop dword [eax + eax]
cmp dword [eax + 0x10], edx
jae 0x40ea5a
mov eax, dword [eax + 8]
jmp 0x40ea5e
mov ecx, eax
mov eax, dword [eax]
cmp byte [eax + 0xd], 0
je 0x40ea50
cmp byte [ecx + 0xd], 0
jne 0x40eb2b
cmp edx, dword [ecx + 0x10]
jb 0x40eb2b
cmp ecx, esi
je 0x40eb2b
mov esi, dword [ecx + 0x14]
test esi, esi
je 0x40eb2b
mov edi, dword [edi + 0x2281c]
mov ecx, edi
mov dl, byte [esi]
mov eax, dword [edi + 4]
cmp byte [eax + 0xd], 0
jne 0x40eab4
nop dword [eax]
cmp byte [eax + 0x10], dl
jae 0x40eaaa
mov eax, dword [eax + 8]
jmp 0x40eaae
mov ecx, eax
mov eax, dword [eax]
cmp byte [eax + 0xd], 0
je 0x40eaa0
cmp byte [ecx + 0xd], 0
jne 0x40eb25
cmp dl, byte [ecx + 0x10]
jb 0x40eb25
cmp ecx, edi
je 0x40eb25
lea eax, [ecx + 0x14]
test eax, eax
je 0x40eb25
push dword [esi + 4]
lea eax, [ebp - 0x218]
push 0x5daa50
push eax
call dword [sym.imp.USER32.dll_wsprintfW]
mov esi, dword [ebp - 0x43c]
add esp, 0xc
test esi, esi
jne 0x40eb05
lea eax, [ebp - 0x218]
mov dword [ebp - 0x43c], 1
push eax
lea eax, [ebp - 0x428]
jmp 0x40eb17
cmp esi, 1
jne 0x40eb25
lea eax, [ebp - 0x218]
push eax
lea eax, [ebp - 0x424]
push 0x5d9670
push eax
call fcn.00402d70
add esp, 0xc
mov edi, dword [ebp - 0x430]
mov eax, dword [ebp - 0x438]
inc ebx
sub dword [ebp - 0x434], 1
jne 0x40ea30
mov al, byte [ebp - 0x429]
inc al
mov byte [ebp - 0x429], al
cmp al, byte [edi + 0x400]
jb 0x40ea05
mov esi, dword [ebp - 0x424]
push esi
call fcn.00577b2d
mov edi, dword [ebp - 0x428]
mov ebx, eax
push edi
call fcn.00577b2d
add esp, 8
mov dword [ebp - 0x438], eax
cmp ebx, 0xa
mov ebx, dword [ebp - 0x430]
jg 0x40ebc7
mov ecx, dword [ebx + 0x22840]
mov edx, 0x5d8d04
mov ax, word [ecx]
cmp ax, word [edx]
jne 0x40ebb8
test ax, ax
je 0x40ebb4
mov ax, word [ecx + 2]
cmp ax, word [edx + 2]
jne 0x40ebb8
add ecx, 4
add edx, 4
test ax, ax
jne 0x40eb92
xor eax, eax
jmp 0x40ebbd
sbb eax, eax
or eax, 1
test eax, eax
jne 0x40ec06
mov eax, dword [ebp - 0x438]
cmp eax, 5
jg 0x40ec0d
mov eax, dword [ebx + 0x22844]
mov ecx, 0x5d8d04
mov dx, word [eax]
cmp dx, word [ecx]
jne 0x40ebfd
test dx, dx
je 0x40ebf9
mov dx, word [eax + 2]
cmp dx, word [ecx + 2]
jne 0x40ebfd
add eax, 4
add ecx, 4
test dx, dx
jne 0x40ebd7
xor eax, eax
jmp 0x40ec02
sbb eax, eax
or eax, 1
test eax, eax
je 0x40ec0d
mov ebx, 1
jmp 0x40ec0f
xor ebx, ebx
lea edx, [esi - 0x10]
mov byte [ebp - 4], 1
or esi, 0xffffffff
mov eax, esi
lock xadd dword [edx + 0xc], eax
dec eax
test eax, eax
jg 0x40ec2d
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov dword [ebp - 4], 0xffffffff
add edi, 0xfffffff0
lock xadd dword [edi + 0xc], esi
dec esi
test esi, esi
jg 0x40ec49
mov ecx, dword [edi]
push edi
mov edx, dword [ecx]
call dword [edx + 4]
mov eax, ebx
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.0056eb08
mov esp, ebp
pop ebp
ret
push 0x80004005
call fcn.004033d0
push 0x80004005
call fcn.004033d0
int3