Function at 0x51dac0
Capabilities:
Get disk information
Get disk size
Resolve function by parsing pe exports

Disassembly:
mov eax, dword fs:[0]
push 0xffffffffffffffff
push 0x59a546
push eax
mov eax, 0x10a4
mov dword fs:[0], esp
call fcn.00413cb0
push ebx
push esi
mov esi, ecx
xor ebx, ebx
mov ecx, dword [esp + 0x10bc]
push 0xffffffffffffffff
push ebx
call fcn.0051e3f0
mov al, byte [0x5f4564]
test al, 1
jne 0x51db20
or al, 1
push str.GetDiskFreeSpaceExA
push 0x5d335c
mov byte [0x5f4564], al
call dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov dword [0x5f4560], eax
call dword [sym.imp.KERNEL32.dll_GetLogicalDrives]
cmp eax, ebx
mov dword [esp + 0x58], eax
jne 0x51db35
xor eax, eax
jmp 0x51dfe4
push ebp
xor ebp, ebp
xor edx, edx
mov dword [esp + 0x2c], 0x5a57d4
mov dword [esp + 0x30], ebp
mov dword [esp + 0x3c], ebx
mov dword [esp + 0x38], ebx
mov dword [esp + 0x34], edx
mov eax, dword [esi + 0x98]
mov dword [esp + 0x10b8], ebx
cmp eax, ebx
je 0x51db92
mov eax, dword [esi + 0x14]
cmp eax, 2
je 0x51db7e
cmp eax, 1
jne 0x51db7e
lea eax, [esp + 0x2c]
mov ecx, esi
push eax
call fcn.0051b0d0
jmp 0x51db8a
lea ecx, [esp + 0x2c]
push ecx
mov ecx, esi
call fcn.0051b380
mov edx, dword [esp + 0x34]
mov ebp, dword [esp + 0x30]
push edi
mov ecx, 0xff
xor eax, eax
lea edi, [esp + 0x8b5]
mov byte [esp + 0x8b4], bl
mov byte [esp + 0xcb4], bl
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
mov ecx, 0xff
xor eax, eax
lea edi, [esp + 0xcb5]
mov dword [esp + 0x28], ebx
rep stosd dword es:[edi], eax
mov cx, word [0x5e5eb8]
mov dword [esp + 0x44], ebx
stosw word es:[edi], ax
stosb byte es:[edi], al
mov eax, dword [0x5d66d0]
mov dword [esp + 0x50], ebx
mov dword [esp + 0x14], eax
mov word [esp + 0x12], cx
mov eax, 1
mov dword [esp + 0x18], ebx
mov ecx, dword [esp + 0x60]
mov esi, eax
shl eax, 1
test ecx, esi
mov dword [esp + 0x5c], eax
je 0x51df9b
mov ecx, 0x20d
xor eax, eax
lea edi, [esp + 0x7d]
mov byte [esp + 0x7c], bl
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
xor eax, eax
cmp edx, ebx
jle 0x51dd86
lea ecx, [ebp + 8]
test dword [ecx], esi
jne 0x51dc3a
inc eax
add ecx, 0x2b4
cmp eax, edx
jl 0x51dc26
jmp 0x51dd86
lea ecx, [eax*8]
sub ecx, eax
lea edx, [ecx + ecx*2]
lea ecx, [eax + edx*2]
lea edx, [eax + ecx*4]
mov eax, dword [ebp + edx*4 + 4]
dec eax
cmp eax, 4
ja case.default.0x51dc5a
jmp dword [eax*4 + 0x51e000]
mov edi, str.Compact_Disc
or ecx, 0xffffffff
xor eax, eax
lea edx, [esp + 0x180]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
mov esi, edi
mov edi, edx
lea edx, [esp + 0x7c]
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edi, str.Removable_media_other_than_floppy
jmp 0x51dd69
mov edi, str.Local_Disk
or ecx, 0xffffffff
xor eax, eax
lea edx, [esp + 0x180]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
mov esi, edi
mov edi, edx
lea edx, [esp + 0x7c]
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edi, str.Floppy
jmp 0x51dd69
mov edi, str.Local_Disk
or ecx, 0xffffffff
xor eax, eax
lea edx, [esp + 0x180]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
mov esi, edi
mov edi, edx
lea edx, [esp + 0x7c]
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edi, str.Fixed_hard_disk_media
jmp 0x51dd69
mov edi, str.Removable_Disk
or ecx, 0xffffffff
xor eax, eax
lea edx, [esp + 0x180]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
mov esi, edi
mov edi, edx
lea edx, [esp + 0x7c]
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edi, str.Removable_media_other_than_floppy
jmp 0x51dd69
mov edi, str.Unknown
or ecx, 0xffffffff
xor eax, eax
lea edx, [esp + 0x180]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
mov esi, edi
mov edi, edx
lea edx, [esp + 0x7c]
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edi, str.Unknown
or ecx, 0xffffffff
xor eax, eax
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 dl, byte [esp + 0x18]
lea edi, [esp + 0x12]
add dl, 0x41
or ecx, 0xffffffff
xor eax, eax
mov byte [esp + 0x12], dl
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
lea ebp, [esp + 0x48c]
mov eax, ecx
mov esi, edi
mov edi, ebp
mov byte [esp + 0x14], dl
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
push 0x400
and ecx, 3
lea edx, [esp + 0x54]
rep movsb byte es:[edi], byte [esi]
lea ecx, [esp + 0xcb8]
lea eax, [esp + 0x48]
push ecx
push edx
lea ecx, [esp + 0x34]
push eax
push ecx
lea edx, [esp + 0x8c8]
push 0x400
lea eax, [esp + 0x2c]
push edx
push eax
call dword [sym.imp.KERNEL32.dll_GetVolumeInformationA]
test eax, eax
je 0x51de62
lea edi, [esp + 0x8b4]
or ecx, 0xffffffff
xor eax, eax
lea edx, [esp + 0x284]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
push 0xa
mov eax, ecx
mov esi, edi
mov edi, edx
mov edx, dword [esp + 0x2c]
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea ecx, [esp + 0x698]
push ecx
push edx
call fcn.0041745c
lea edi, [esp + 0xcc0]
or ecx, 0xffffffff
xor eax, eax
add esp, 0xc
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
lea edx, [esp + 0x388]
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 eax, dword [0x5f4560]
cmp eax, ebx
je 0x51debe
lea ecx, [esp + 0x54]
lea edx, [esp + 0x48]
push ecx
push edx
lea ecx, [esp + 0x74]
lea edx, [esp + 0x1c]
push ecx
push edx
mov dword [esp + 0x7c], ebx
mov dword [esp + 0x80], ebx
mov dword [esp + 0x58], ebx
mov dword [esp + 0x5c], ebx
mov dword [esp + 0x64], ebx
mov dword [esp + 0x68], ebx
call eax
test eax, eax
je 0x51df5b
fild qword [esp + 0x48]
fmul qword [0x5a5828]
fstp qword [esp + 0x79c]
fild qword [esp + 0x54]
jmp 0x51df4e
lea eax, [esp + 0x20]
lea ecx, [esp + 0x2c]
push eax
lea edx, [esp + 0x20]
push ecx
lea eax, [esp + 0x2c]
push edx
lea ecx, [esp + 0x20]
push eax
push ecx
mov dword [esp + 0x38], ebx
mov dword [esp + 0x30], ebx
mov dword [esp + 0x40], ebx
mov dword [esp + 0x34], ebx
call dword [sym.imp.KERNEL32.dll_GetDiskFreeSpaceA]
test eax, eax
je 0x51df5b
mov ebp, dword [esp + 0x24]
mov edx, dword [esp + 0x20]
mov esi, dword [esp + 0x1c]
push ebx
push ebp
push ebx
push edx
xor edi, edi
call fcn.004149b0
push edi
push esi
push edx
push eax
call fcn.004149b0
push ebx
mov dword [esp + 0x68], eax
mov eax, dword [esp + 0x30]
xor ebx, ebx
push ebp
push ebx
push eax
mov dword [esp + 0x78], edx
call fcn.004149b0
push edi
push esi
push edx
push eax
call fcn.004149b0
fild qword [esp + 0x64]
mov dword [esp + 0x74], eax
mov dword [esp + 0x78], edx
fmul qword [0x5a5828]
fstp qword [esp + 0x79c]
fild qword [esp + 0x74]
fmul qword [0x5a5828]
fstp qword [esp + 0x7a4]
mov edi, dword [esp + 0x10c4]
push 0xffffffffffffffff
mov esi, dword [edi + 8]
lea ecx, [esi + 1]
push ecx
mov ecx, edi
call fcn.0051e3f0
mov edx, esi
mov eax, dword [edi + 4]
shl edx, 5
add edx, esi
mov ecx, 0x20e
shl edx, 3
sub edx, esi
lea esi, [esp + 0x7c]
lea edi, [eax + edx*8]
mov eax, dword [esp + 0x5c]
rep movsd dword es:[edi], dword [esi]
mov edx, dword [esp + 0x38]
mov ebp, dword [esp + 0x34]
mov ecx, dword [esp + 0x18]
inc ecx
cmp ecx, 0x1a
mov dword [esp + 0x18], ecx
jl 0x51dbf1
mov ecx, dword [esp + 0x10c4]
xor edx, edx
mov dword [esp + 0x30], 0x5a57d4
mov eax, dword [ecx + 8]
cmp eax, ebx
setne dl
mov esi, edx
cmp ebp, ebx
mov dword [esp + 0x10bc], 1
pop edi
je 0x51dfe1
push ebp
call fcn.00579886
add esp, 4
mov eax, esi
pop ebp
mov ecx, dword [esp + 0x10ac]
pop esi
pop ebx
mov dword fs:[0], ecx
add esp, 0x10b0
ret 4