Function at 0x401890
Capabilities:
Get disk information
Write file on windows

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0xe54
mov eax, dword [0x422004]
xor eax, esp
mov dword [esp + 0xe50], eax
mov eax, dword [ebp + 0xc]
push ebx
mov ebx, dword [ebp + 8]
push esi
push edi
push 0x58
mov dword [esp + 0x1c], eax
mov edi, ecx
lea eax, [esp + 0x3c]
mov dword [esp + 0x14], 0
push 0
push eax
call fcn.00403ee0
add esp, 0xc
lea eax, [esp + 0x140]
push 0x208
push 0
push eax
call fcn.00403ee0
add esp, 0xc
lea eax, [esp + 0x100]
xorps xmm0, xmm0
movlpd qword [esp + 0xf8], xmm0
movlpd qword [esp + 0xf0], xmm0
push 0x40
push 0
push eax
call fcn.00403ee0
add esp, 0xc
lea eax, [esp + 0x140]
xor esi, esi
test ebx, ebx
je 0x401930
push ebx
push 0x104
push eax
call fcn.00407e46
add esp, 0xc
jmp 0x401980
mov dword [esp + 0x54], eax
lea eax, [esp + 0x38]
push eax
mov dword [esp + 0x3c], 0x58
mov dword [esp + 0x40], edi
mov dword [esp + 0x5c], 0x208
mov dword [esp + 0x48], str.Vlnk_Source_File
mov dword [esp + 0x54], 1
mov dword [esp + 0x60], esi
mov dword [esp + 0x64], esi
mov dword [esp + 0x68], esi
mov dword [esp + 0x70], 0x1800
call dword [sym.imp.COMDLG32.dll_GetOpenFileNameW]
cmp eax, 1
jne 0x40216c
lea eax, [esp + 0x140]
push eax
push str.Create_vlnk_for___ls__n
call fcn.00401270
add esp, 8
lea eax, [esp + 0x140]
push eax
mov eax, dword [sym.imp.KERNEL32.dll_lstrlenW]
mov dword [esp + 0x20], eax
call eax
mov dword [esp + 0xc], eax
cmp eax, 5
jl 0x402147
mov ax, word [esp + 0x140]
cmp ax, 0x2e
je 0x402147
cmp word [esp + 0x142], 0x3a
jne 0x402147
push 0x3f
mov byte [esp + 0xf4], al
lea eax, [esp + 0x104]
push eax
push 0
push 0
push 0
push 0
push 0
lea eax, [esp + 0x10c]
mov word [esp + 0x10d], 0x5c3a
push eax
call dword [sym.imp.KERNEL32.dll_GetVolumeInformationA]
test eax, eax
jne 0x401a26
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.GetVolumeInformationA_failed__u_n
call fcn.00401370
add esp, 8
jmp 0x40216c
lea eax, [esp + 0x100]
push eax
lea eax, [esp + 0xf4]
push eax
push str.Partition_filesystem_of___s__is___s__n
call fcn.00401370
add esp, 0xc
lea eax, [esp + 0x100]
push str.NTFS
push eax
call fcn.00407fe1
add esp, 8
test eax, eax
je 0x401b25
lea eax, [esp + 0x100]
push str.exFAT
push eax
call fcn.00407fe1
add esp, 8
test eax, eax
je 0x401b25
lea eax, [esp + 0x100]
push 0x41f8e4
push eax
call fcn.00407fe1
add esp, 8
test eax, eax
je 0x401b25
lea eax, [esp + 0x100]
push str.FAT32
push eax
call fcn.00407fe1
add esp, 8
test eax, eax
je 0x401b25
lea eax, [esp + 0x100]
push str.FAT16
push eax
call fcn.00407fe1
add esp, 8
test eax, eax
je 0x401b25
lea eax, [esp + 0x100]
push str.FAT12
push eax
call fcn.00407fe1
add esp, 8
test eax, eax
je 0x401b25
lea eax, [esp + 0x100]
push 0x41f900
push eax
call fcn.00407fe1
add esp, 8
test eax, eax
je 0x401b25
mov eax, dword [0x423640]
cmp word [0x423d58], si
je 0x401b19
cmp word [0x423f68], si
jne 0x40216c
push 0x10
push dword [eax]
push dword [eax + 0x18]
jmp 0x402165
push str.FS_Check_OK_n
call fcn.00401370
mov eax, dword [esp + 0x10]
lea edx, [esp + 0x144]
xor ebx, ebx
add esp, 4
cmp word [esp + eax*2 + 0x136], 0x2e
sete bl
xor ecx, ecx
add ebx, 4
sub eax, ebx
lea edx, [edx + eax*2]
nop word [eax + eax]
mov al, byte [edx]
lea edx, [edx + 2]
mov byte [esp + ecx + 0xf8], al
inc ecx
cmp ecx, ebx
jl 0x401b60
lea ecx, [esp + 0xf8]
call fcn.00402ac0
test eax, eax
jne 0x401ba8
mov eax, dword [0x423640]
cmp word [0x423d58], si
je 0x401b9c
cmp word [0x423f68], si
jne 0x40216c
push 0x10
push dword [eax]
push dword [eax + 0x1c]
jmp 0x402165
xor edx, edx
lea ecx, [esp + 0x140]
call fcn.00401660
test eax, eax
je 0x401be1
mov eax, dword [0x423640]
cmp word [0x423d58], si
je 0x401bd5
cmp word [0x423f68], si
jne 0x40216c
push 0x10
push dword [eax]
push dword [eax + 0x30]
jmp 0x402165
xor edx, edx
lea eax, [esp + 0x140]
nop word [eax + eax]
movzx ecx, word [eax]
test cx, cx
je 0x401c10
cmp ecx, 0x5c
je 0x401c02
cmp ecx, 0x2f
jne 0x401c04
mov esi, eax
inc edx
add eax, 2
cmp edx, 0x104
jl 0x401bf0
mov dword [esp + 0xc], esi
test esi, esi
jne 0x401c2a
push str.name_part_not_found_n
call fcn.00401370
add esp, 4
jmp 0x40216c
add esi, 2
push esi
push str.File_Name_is___ls__n
mov dword [esp + 0xf4], esi
call fcn.00401270
push 0x104
lea eax, [esp + 0x354]
push 0
push eax
call fcn.00403ee0
add esp, 0x14
lea eax, [esp + 0x348]
push 0
push 0
push 0x104
push eax
push 0xffffffffffffffff
lea eax, [esp + 0x158]
push eax
push 0
push 0xfde9
call dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
xor eax, eax
mov cl, byte [esp + eax + 0x348]
test cl, cl
je 0x401ca0
cmp cl, 0x5c
jne 0x401c98
mov byte [esp + eax + 0x348], 0x2f
inc eax
cmp eax, 0x104
jl 0x401c80
lea ecx, [esp + 0x348]
lea edx, [ecx + 1]
nop word [eax + eax]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x401cb0
sub ecx, edx
cmp ecx, 0x180
jl 0x401cf8
push ecx
push str.File_name_length__d_overflow_n
call fcn.00401370
mov eax, dword [0x423640]
add esp, 8
cmp word [0x423d58], 0
je 0x401cec
cmp word [0x423f68], 0
jne 0x40216c
push 0x10
push dword [eax]
push dword [eax + 0x40]
jmp 0x402165
mov cl, byte [esp + 0x140]
lea eax, [esp + 0x20]
xorps xmm0, xmm0
lea edx, [esp + 0x14]
push eax
movlpd qword [esp + 0x2c], xmm0
call fcn.00401450
add esp, 4
test eax, eax
je 0x401d46
cmp word [0x423d58], 0
mov eax, dword [0x423640]
je 0x401d3a
cmp word [0x423f68], 0
jne 0x40216c
push 0x10
push dword [eax]
push dword [eax + 0x20]
jmp 0x402165
push 0x8000
call fcn.00408131
mov ebx, eax
add esp, 4
test ebx, ebx
je 0x402130
push 0x7fe0
lea ecx, [ebx + 0x20]
mov dword [ebx + 0x10], 0
push 0
push ecx
call fcn.00403ee0
mov dword [ebx], 0x77772020
add esp, 0xc
mov dword [ebx + 4], 0x65762e77
mov dword [ebx + 8], 0x796f746e
mov dword [ebx + 0xc], 0x74656e2e
mov eax, dword [esp + 0x14]
mov ecx, dword [esp + 0x2c]
mov dword [ebx + 0x14], eax
mov eax, dword [esp + 0x28]
mov dword [ebx + 0x18], eax
lea eax, [esp + 0x348]
push eax
lea eax, [ebx + 0x20]
mov dword [ebx + 0x1c], ecx
push 0x17f
push eax
call fcn.0040813c
add esp, 8
mov edx, ebx
call fcn.00401130
mov dword [ebx + 0x10], eax
add esp, 4
mov eax, dword [esp + 0x18]
test eax, eax
jne 0x401f69
push esi
call dword [esp + 0x20]
mov dword [esp + 0x18], eax
lea esi, [eax - 1]
test esi, esi
js 0x401e91
mov edx, dword [esp + 0xec]
nop dword [eax]
nop dword [eax + eax]
movzx ecx, word [edx + esi*2]
mov eax, ecx
mov dword [esp + 0xec], eax
cmp ecx, 0x2e
je 0x401e19
sub esi, 1
jns 0x401e00
jmp 0x401e91
xor eax, eax
mov word [edx + esi*2], ax
lea eax, [edx + 2]
lea eax, [eax + esi*2]
push eax
push edx
push 0x423a48
push str._ls_ls.vlnk._ls
lea eax, [esp + 0x460]
push 0x104
push eax
call fcn.004011c0
mov ecx, dword [esp + 0x24]
add esp, 0x18
mov edx, dword [esp + 0xec]
mov dword [esp + 0x14], eax
mov word [ecx + esi*2 + 2], dx
mov ecx, eax
sub ecx, dword [esp + 0x18]
add ecx, esi
mov esi, eax
cmp ecx, esi
jge 0x401e91
nop dword [eax + eax]
movzx edx, word [esp + ecx*2 + 0x450]
lea eax, [edx - 0x41]
cmp ax, 0x19
ja 0x401e8c
lea eax, [edx + 0x20]
mov word [esp + ecx*2 + 0x450], ax
inc ecx
cmp ecx, esi
jl 0x401e70
cmp dword [0x423f60], 0
je 0x401fea
lea eax, [esp + 0x450]
push eax
lea eax, [esp + 0x144]
push 0x104
push eax
call fcn.00407e46
add esp, 0xc
lea eax, [esp + 0x90]
push 0x58
push 0
push eax
call fcn.00403ee0
add esp, 0xc
mov dword [esp + 0x90], 0x58
lea eax, [esp + 0x140]
mov dword [esp + 0x94], edi
mov dword [esp + 0xac], eax
lea eax, [esp + 0x90]
mov dword [esp + 0x9c], str.Vlnk_File
push eax
mov dword [esp + 0xac], 1
mov dword [esp + 0xb4], 0x104
mov dword [esp + 0xc8], 0x80806
mov dword [esp + 0xb8], 0
mov dword [esp + 0xbc], 0
mov dword [esp + 0xc0], 0
call dword [sym.imp.COMDLG32.dll_GetSaveFileNameW]
test eax, eax
je 0x401fdd
lea ecx, [esp + 0x140]
call fcn.004017e0
test eax, eax
je 0x401f89
lea eax, [esp + 0x140]
push eax
lea eax, [esp + 0x454]
push 0x104
push eax
call fcn.00407e46
add esp, 0xc
mov dword [esp + 0x10], 1
jmp 0x401fea
cmp word [0x423d58], 0
mov eax, dword [0x423640]
je 0x401fa2
cmp word [0x423f68], 0
jne 0x401fb0
push 0x10
push dword [eax]
push dword [eax + 0x44]
push edi
call dword [sym.imp.USER32.dll_MessageBoxW]
push str.Invalid_vlnk_suffix_n
call fcn.00401370
add esp, 4
push ebx
call fcn.00408116
add esp, 4
xor eax, eax
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0xe50]
xor ecx, esp
call fcn.00403088
mov esp, ebp
pop ebp
ret
push str.User_cancel_the_save_as_diaglog__use_default_name_n
call fcn.00401370
add esp, 4
lea eax, [esp + 0x450]
push eax
push str.vlnk_output_file_path_is___ls__n
call fcn.00401270
push 0x8000
lea eax, [esp + 0x45c]
push eax
push str.SaveBuffer2File___ls__len:_u_n
call fcn.00401270
add esp, 0x14
lea eax, [esp + 0x450]
push 0
push 0
push 2
push 0
push 3
push 0xc0000000
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov esi, eax
cmp esi, 0xffffffff
jne 0x402081
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.Could_not_create_new_file__error:_u_n
call fcn.00401370
push str.Vlnk_file_save_failed_n
call fcn.00401370
mov eax, dword [0x423640]
add esp, 0xc
cmp word [0x423d58], 0
je 0x402075
cmp word [0x423f68], 0
jne 0x402127
push 0x10
push dword [eax]
push dword [eax + 0x2c]
jmp 0x402120
push 0
lea eax, [esp + 0xf0]
push eax
push 0x8000
push ebx
push esi
call dword [sym.imp.KERNEL32.dll_WriteFile]
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
lea eax, [esp + 0x450]
push eax
push str.Vlnk_file_create_success___ls__n
call fcn.00401270
add esp, 8
cmp dword [esp + 0x10], 0
je 0x4020c4
lea eax, [esp + 0x450]
jmp 0x4020d7
push 0x423a48
call dword [esp + 0x20]
lea ecx, [esp + 0x452]
lea eax, [ecx + eax*2]
push eax
mov eax, dword [0x423640]
push dword [eax + 0x24]
lea eax, [esp + 0x660]
push str._ls_r_n_r_n_ls
push 0x400
push eax
call fcn.004011c0
mov eax, dword [0x423640]
add esp, 0x14
cmp word [0x423d58], 0
je 0x402113
cmp word [0x423f68], 0
jne 0x402127
push 0x40
push dword [eax + 4]
lea eax, [esp + 0x660]
push eax
push edi
call dword [sym.imp.USER32.dll_MessageBoxW]
push ebx
call fcn.00408116
add esp, 4
xor eax, eax
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0xe50]
xor ecx, esp
call fcn.00403088
mov esp, ebp
pop ebp
ret
mov eax, dword [0x423640]
cmp word [0x423d58], si
je 0x40215e
cmp word [0x423f68], si
jne 0x40216c
push 0x10
push dword [eax]
push dword [eax + 0x14]
push edi
call dword [sym.imp.USER32.dll_MessageBoxW]
mov ecx, dword [esp + 0xe5c]
mov eax, 1
pop edi
pop esi
pop ebx
xor ecx, esp
call fcn.00403088
mov esp, ebp
pop ebp
ret