Function at 0x40c120
Capabilities:
Get disk information
Get disk size

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x51e69d
mov eax, dword fs:[0]
push eax
sub esp, 0x874
mov eax, dword [0x562904]
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 dword [ebp - 0x864], edx
mov esi, ecx
mov dword [ebp - 0x85c], 0
xor eax, eax
mov ecx, 3
mov dword [ebp - 0x838], 0
cmp dword [esi + 0x10], ecx
mov word [ebp - 0x838], ax
mov eax, esi
cmovb ecx, dword [esi + 0x10]
cmp dword [esi + 0x14], 8
mov dword [ebp - 0x828], 0
mov dword [ebp - 0x824], 7
jb 0x40c19d
mov eax, dword [esi]
push ecx
push eax
lea ecx, [ebp - 0x838]
call fcn.004046e0
mov eax, 4
mov dword [ebp - 0x840], eax
mov dword [ebp - 4], 0
lea ecx, [ebp - 0x820]
cmp dword [ebp - 0x824], 8
lea eax, [ebp - 0x838]
push 0
cmovae eax, dword [ebp - 0x838]
xorps xmm0, xmm0
push 0
push ecx
push eax
movq qword [ebp - 0x820], xmm0
call dword [sym.imp.KERNEL32.dll_GetDiskFreeSpaceExW]
test eax, eax
je 0x40c549
push 0x800
lea eax, [ebp - 0x810]
mov dword [ebp - 0x814], 1
push 0
push eax
call fcn.004f3680
add esp, 0xc
mov eax, esi
cmp dword [esi + 0x14], 8
jb 0x40c21f
mov eax, dword [esi]
push 0x400
lea ecx, [ebp - 0x810]
push ecx
lea ecx, [ebp - 0x814]
push ecx
push 0
push 0
push 0
push 0
push eax
call dword [sym.imp.KERNEL32.dll_GetVolumeInformationW]
test eax, eax
je 0x40c2f5
xor eax, eax
mov dword [ebp - 0x87c], 0
lea ecx, [ebp - 0x810]
mov dword [ebp - 0x86c], 0
mov dword [ebp - 0x868], 7
lea edx, [ecx + 2]
mov word [ebp - 0x87c], ax
nop dword [eax]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x40c280
sub ecx, edx
lea eax, [ebp - 0x810]
sar ecx, 1
push ecx
push eax
lea ecx, [ebp - 0x87c]
call fcn.004046e0
mov byte [ebp - 4], 1
lea edi, [ebp - 0x87c]
cmp dword [ebp - 0x868], 8
mov eax, 5
mov dword [ebp - 0x840], eax
cmovae edi, dword [ebp - 0x87c]
mov dword [ebp - 0x85c], eax
cmp dword [ebp - 0x86c], eax
jne 0x40c4aa
mov ecx, str.FAT32
mov edx, eax
sub edi, ecx
mov ax, word [edi + ecx]
cmp ax, word [ecx]
jne 0x40c4aa
add ecx, 2
sub edx, 1
jne 0x40c2e0
mov ebx, dword [ebp - 0x858]
mov byte [ebp - 0x839], 0
mov ecx, dword [ebp - 0x840]
test cl, 2
je 0x40c356
mov eax, dword [ebp - 0x844]
and ecx, 0xfffffffd
mov dword [ebp - 0x840], ecx
cmp eax, 8
jb 0x40c356
lea ecx, [eax*2 + 2]
mov eax, ebx
cmp ecx, 0x1000
jb 0x40c346
mov ebx, dword [ebx - 4]
add ecx, 0x23
sub eax, ebx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40c5b4
push ecx
push ebx
call fcn.004f19ca
mov ecx, dword [ebp - 0x840]
add esp, 8
mov dword [ebp - 4], 0
test cl, 1
je 0x40c3a2
mov eax, dword [ebp - 0x868]
cmp eax, 8
jb 0x40c3a2
mov edx, dword [ebp - 0x87c]
lea ecx, [eax*2 + 2]
mov eax, edx
cmp ecx, 0x1000
jb 0x40c398
mov edx, dword [edx - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40c5b4
push ecx
push edx
call fcn.004f19ca
add esp, 8
cmp byte [ebp - 0x839], 0
jne 0x40c549
mov edx, dword [ebp - 0x81c]
mov ecx, dword [ebp - 0x820]
call fcn.004f1f50
mulsd xmm0, qword [0x552ef8]
xor eax, eax
mov ecx, 2
mov dword [ebp - 0x858], 0
cmp dword [esi + 0x10], ecx
mov dword [ebp - 0x848], 0
cmovb ecx, dword [esi + 0x10]
cmp dword [esi + 0x14], 8
movsd qword [ebp - 0x860], xmm0
mov dword [ebp - 0x844], 7
mov word [ebp - 0x858], ax
jb 0x40c40b
mov esi, dword [esi]
push ecx
push esi
lea ecx, [ebp - 0x858]
call fcn.004046e0
mov byte [ebp - 4], 2
lea ecx, [ebp - 0x858]
cmp dword [ebp - 0x844], 8
cmovae ecx, dword [ebp - 0x858]
call fcn.0040b510
mov esi, dword [ebp - 0x864]
mov edx, dword [ebp - 0x844]
mov byte [esi], al
cmp edx, 8
jb 0x40c47d
mov ecx, dword [ebp - 0x858]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x40c473
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40c5b4
push edx
push ecx
call fcn.004f19ca
add esp, 8
cmp byte [esi], 0
je 0x40c554
movsd xmm0, qword [ebp - 0x860]
cvttsd2si eax, xmm0
cmp eax, 0x4400
jle 0x40c554
mulsd xmm0, qword [0x552f40]
jmp 0x40c54c
lea ecx, [ebp - 0x810]
mov dword [ebp - 0x858], 0
mov dword [ebp - 0x848], 0
lea edx, [ecx + 2]
mov dword [ebp - 0x844], 7
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x40c4d1
sub ecx, edx
lea eax, [ebp - 0x810]
sar ecx, 1
push ecx
push eax
lea ecx, [ebp - 0x858]
call fcn.004046e0
cmp dword [ebp - 0x844], 8
lea edi, [ebp - 0x858]
mov ebx, dword [ebp - 0x858]
mov eax, 7
cmovae edi, ebx
mov dword [ebp - 0x840], eax
cmp dword [ebp - 0x848], 4
jne 0x40c53d
mov ecx, str.NTFS
lea edx, [eax - 3]
sub edi, ecx
mov ax, word [edi + ecx]
cmp ax, word [ecx]
jne 0x40c53d
add ecx, 2
sub edx, 1
jne 0x40c527
jmp 0x40c2fb
mov byte [ebp - 0x839], 1
jmp 0x40c302
xorps xmm0, xmm0
movsd qword [ebp - 0x860], xmm0
mov edx, dword [ebp - 0x824]
cmp edx, 8
jb 0x40c590
mov ecx, dword [ebp - 0x838]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x40c586
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40c5b4
push edx
push ecx
call fcn.004f19ca
add esp, 8
movsd xmm0, qword [ebp - 0x860]
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.004f1532
mov esp, ebp
pop ebp
ret
call fcn.004fbf0c
int3