Function at 0x401560
Capabilities:
Get disk information

Disassembly:
sub esp, 0x628
mov eax, dword [0x5954a0]
xor eax, esp
mov dword [esp + 0x624], eax
push ebx
mov ebx, dword [sym.imp.KERNEL32.dll_lstrcpyW]
push ebp
mov ebp, dword [esp + 0x638]
push esi
push edi
push 0x5668b0
lea eax, [esp + 0x1c]
mov edi, ecx
push eax
mov dword [esp + 0x1c], edi
call ebx
mov esi, dword [sym.imp.KERNEL32.dll_lstrlenW]
push ebp
call esi
cmp eax, 8
jle 0x4015bc
push 9
push ebp
lea ecx, [esp + 0x28]
push ecx
call dword [sym.imp.KERNEL32.dll_lstrcpynW]
xor edx, edx
mov word [esp + 0x30], dx
jmp 0x4015c8
push ebp
lea eax, [esp + 0x1c]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcatW]
mov ecx, 0x3a
cmp cx, word [esp + 0x22]
jne 0x4015db
xor edx, edx
mov word [esp + 0x24], dx
push ebp
call esi
cmp eax, 1
jne 0x4015f3
push 0x5668bc
lea eax, [esp + 0x1c]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcatW]
lea ecx, [esp + 0x20]
push ecx
add edi, 0x204
push edi
call ebx
push ebp
call esi
cmp eax, 1
je 0x401615
push 0x5668c0
push edi
call dword [sym.imp.KERNEL32.dll_lstrcatW]
push 0
push 0x20000000
push 3
push 0
push 3
push 0
lea edx, [esp + 0x30]
push edx
call dword [sym.imp.KERNEL32.dll_CreateFileW]
cmp eax, 0xffffffff
je 0x4016de
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov esi, dword [sym.imp.KERNEL32.dll_SetLastError]
push 0xaa
call esi
push 0x104
lea eax, [esp + 0x42c]
push eax
lea ecx, [esp + 0x28]
push ecx
call dword [sym.imp.KERNEL32.dll_QueryDosDeviceW]
test eax, eax
je 0x40173b
mov edi, dword [esp + 0x63c]
push edi
lea edx, [esp + 0x224]
push str.DeviceEsafenetEncryDisk_u
push edx
call fcn.004fbc08
add esp, 0xc
lea eax, [esp + 0x220]
push eax
lea ecx, [esp + 0x42c]
push ecx
call fcn.004fd061
add esp, 8
test eax, eax
jne 0x40173b
mov eax, edi
call fcn.00401dd0
push 0
test eax, eax
je 0x4016bd
call esi
jmp 0x401823
lea edx, [esp + 0x24]
push edx
push 2
call dword [0x5a22c0]
movzx esi, word [ebp]
shl esi, 0x10
or esi, 0x8004
call fcn.00401320
jmp 0x4016e5
mov edi, dword [esp + 0x63c]
push edi
call fcn.00401380
mov esi, eax
add esp, 4
cmp esi, 0xffffffff
je 0x40173b
mov ebx, dword [sym.imp.KERNEL32.dll_DeviceIoControl]
push 0
lea eax, [esp + 0x14]
push eax
mov eax, dword [esp + 0x1c]
movzx ecx, word [eax + 0x244]
push 0
push 0
add ecx, 0x660
push ecx
push eax
push 0x80002000
push esi
call ebx
test eax, eax
jne 0x401742
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov edi, eax
push esi
call dword [sym.imp.ntdll.dll_NtClose]
push edi
call dword [sym.imp.KERNEL32.dll_SetLastError]
xor eax, eax
jmp 0x401828
push 0
lea edx, [esp + 0x14]
push edx
push 0
push 0
push 0
push 0
push 0x800024d8
push esi
call ebx
push edi
lea eax, [esp + 0x224]
push str.DeviceEsafenetEncryDisk_u
push eax
call fcn.004fbc08
add esp, 0xc
lea ecx, [esp + 0x220]
push ecx
lea edx, [esp + 0x24]
push edx
push 1
call dword [0x5a22c0]
test eax, eax
jne 0x40179d
lea eax, [esp + 0x220]
push eax
lea ecx, [esp + 0x24]
push ecx
push 2
call dword [0x5a22c0]
lea edx, [esp + 0x220]
push edx
lea eax, [esp + 0x24]
push eax
push 1
call dword [0x5a22c0]
test eax, eax
jne 0x401800
call dword [sym.imp.KERNEL32.dll_GetLastError]
push 0
push 0x20000000
push 3
push 0
push 3
push 0
lea ecx, [esp + 0x30]
push ecx
mov edi, eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
cmp eax, 0xffffffff
jne 0x4017f9
push 0
lea edx, [esp + 0x14]
push edx
push 0
push 0
push 0
push 0
push 0x80002004
push esi
call ebx
jmp 0x40172d
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push esi
call dword [sym.imp.ntdll.dll_NtClose]
cmp dword [esp + 0x644], 0
je 0x401823
movzx esi, word [ebp]
shl esi, 0x10
or esi, 0x8000
call fcn.00401320
mov eax, 1
mov ecx, dword [esp + 0x634]
pop edi
pop esi
pop ebp
pop ebx
xor ecx, esp
call fcn.004f8124
add esp, 0x628
ret