Function at 0x402937
Capabilities:
Check if file exists
Get disk information
Get disk size

Disassembly:
push 0x280
mov eax, 0x46e3ed
call fcn.00431db0
mov eax, dword [ebp + 8]
xor ebx, ebx
inc ebx
mov dword [ebp - 0x280], eax
mov edi, 0x48d140
test byte [0x48d13c], bl
jne 0x402980
or dword [0x48d13c], ebx
and dword [ebp - 4], 0
push 0x478088
mov ecx, edi
call fcn.004036a3
push 0x47015a
call fcn.0042f0c5
pop ecx
test byte [0x48d13c], 2
jne 0x4029ad
or dword [0x48d13c], 2
push 0x477eb8
mov ecx, 0x48d120
mov dword [ebp - 4], ebx
call fcn.004036a3
push 0x47014b
call fcn.0042f0c5
pop ecx
push 0
lea ecx, [ebp - 0x270]
mov dword [ebp - 0x258], 7
call fcn.00403e67
lea esi, [ebp - 0x270]
mov dword [ebp - 4], 2
call fcn.00401596
cmp dword [ebp - 0x258], 8
mov eax, dword [ebp - 0x26c]
jae 0x4029eb
lea eax, [ebp - 0x26c]
add eax, 6
push eax
lea ecx, [ebp - 0x254]
call fcn.004036a3
lea ebx, [ebp - 0x254]
mov byte [ebp - 4], 3
call fcn.0040156c
push 0xffffffffffffffff
xor ebx, ebx
push ebx
push edi
lea ecx, [ebp - 0x254]
call fcn.00403b54
mov esi, dword [sym.imp.KERNEL32.dll_GetLogicalDriveStringsW]
push ebx
push ebx
call esi
mov edi, eax
mov dword [ebp - 0x274], ebx
cmp edi, ebx
jbe 0x402a8a
xor ecx, ecx
push 2
pop edx
lea eax, [edi + 1]
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.0042d95a
pop ecx
push eax
push edi
mov dword [ebp - 0x274], eax
call esi
mov edi, eax
cmp edi, ebx
jne 0x402a8a
xor esi, esi
push dword [ebp - 0x274]
call fcn.0042f2c4
pop ecx
push ebx
push 1
lea ecx, [ebp - 0x254]
call fcn.00403f22
push ebx
push 1
lea ecx, [ebp - 0x270]
call fcn.00403f22
mov eax, esi
call fcn.00431e33
ret
mov esi, dword [ebp - 0x274]
mov dword [ebp - 0x27c], ebx
mov dword [ebp - 0x278], ebx
cmp edi, ebx
jbe 0x402c17
push esi
call dword [sym.imp.KERNEL32.dll_GetDriveTypeW]
cmp eax, 3
jne 0x402baa
xor eax, eax
push 0x206
mov word [ebp - 0x21c], ax
lea eax, [ebp - 0x21a]
push ebx
push eax
call fcn.00431530
mov eax, dword [ebp - 0x250]
add esp, 0xc
cmp dword [ebp - 0x23c], 8
jae 0x402ae7
lea eax, [ebp - 0x250]
push eax
push esi
lea eax, [ebp - 0x21c]
push eax
call dword [sym.imp.SHLWAPI.dll_PathCombineW]
lea eax, [ebp - 0x21c]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x402baa
push ebx
push ebx
lea eax, [ebp - 0x28c]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_GetDiskFreeSpaceExW]
cmp dword [ebp - 0x288], ebx
ja 0x402b2f
cmp dword [ebp - 0x28c], 0x1400000
jb 0x402baa
lea eax, [ebp - 0x21c]
push eax
lea ecx, [ebp - 0x238]
call fcn.004036a3
lea ebx, [ebp - 0x238]
mov byte [ebp - 4], 4
call fcn.0040156c
push 0xffffffffffffffff
xor ebx, ebx
push ebx
push 0x48d120
lea ecx, [ebp - 0x238]
call fcn.00403b54
lea eax, [ebp - 0x238]
push eax
call fcn.004015da
pop ecx
test al, al
je 0x402b96
cmp dword [ebp - 0x220], 8
mov eax, dword [ebp - 0x234]
jae 0x402b8b
lea eax, [ebp - 0x234]
push eax
call fcn.00412e8e
pop ecx
test eax, eax
jne 0x402bd5
push ebx
push 1
lea ecx, [ebp - 0x238]
mov byte [ebp - 4], 3
call fcn.00403f22
xor ebx, ebx
mov eax, esi
lea edx, [eax + 2]
mov cx, word [eax]
inc eax
inc eax
cmp cx, bx
jne 0x402baf
sub eax, edx
sar eax, 1
inc eax
add dword [ebp - 0x278], eax
lea esi, [esi + eax*2]
cmp dword [ebp - 0x278], edi
jb 0x402aa4
jmp 0x402c17
cmp dword [ebp - 0x220], 8
mov ecx, dword [ebp - 0x234]
jae 0x402bea
lea ecx, [ebp - 0x234]
mov edx, dword [ebp - 0x280]
movzx eax, word [ecx]
inc ecx
mov word [edx], ax
inc ecx
inc edx
inc edx
cmp ax, bx
jne 0x402bf0
xor eax, eax
inc eax
push ebx
push eax
lea ecx, [ebp - 0x238]
mov dword [ebp - 0x27c], eax
call fcn.00403f22
xor ebx, ebx
mov esi, dword [ebp - 0x27c]
jmp 0x402a5a