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

Disassembly:
push 0xffffffffffffffff
mov eax, dword fs:[0]
push 0x41ed96
push eax
mov eax, 0x4978
mov dword fs:[0], esp
call fcn.0041e190
mov al, byte [ecx + 4]
push ebx
push ebp
push esi
test al, al
push edi
mov dword [esp + 0x24], ecx
jne 0x40de8e
cmp byte [ecx + 6], 1
jne 0x40d7c2
cmp byte [ecx + 7], 0x10
jb 0x40de8e
mov ecx, dword [ecx + 0x84d]
test ecx, ecx
mov dword [esp + 0x30], ecx
je 0x40de8e
mov ecx, dword [esp + 0x4998]
xor eax, eax
mov esi, ecx
shl esi, 0x10
or esi, ecx
add ecx, 0xffffecff
xor esi, 0x23f7e1d3
cmp ecx, 0xc
mov dword [esp + 0x20], esi
ja case.0x40d7f9.4875
jmp dword [ecx*4 + 0x40deac]
mov eax, 0x1244
jmp case.0x40d7f9.4875
mov eax, 0x1240
jmp case.0x40d7f9.4875
mov eax, 0x1247
jmp case.0x40d7f9.4875
mov eax, 0x1238
jmp case.0x40d7f9.4875
mov eax, 0x1236
jmp case.0x40d7f9.4875
mov eax, 0x1239
jmp case.0x40d7f9.4875
mov eax, 0x1241
jmp case.0x40d7f9.4875
mov eax, 0x1245
jmp case.0x40d7f9.4875
mov eax, 0x1246
jmp case.0x40d7f9.4875
mov eax, 0x1248
mov edi, eax
mov ebp, dword [sym.imp.MSVCRT.dll_sprintf]
shl edi, 0x10
or edi, eax
mov dword [esp + 0x14], esi
xor edi, 0x23f7e1d3
mov dword [esp + 0x10], 0
mov dword [esp + 0x28], edi
mov ebx, 0x62
cmp ebx, 0x62
jne 0x40d88b
mov eax, dword [esp + 0x499c]
lea edx, [esp + 0x1988]
movsx ecx, byte [eax]
push ecx
push str._c:_
push edx
jmp 0x40d899
push ebx
lea eax, [esp + 0x198c]
push str._c:_
push eax
call ebp
add esp, 0xc
lea ecx, [esp + 0x1988]
push ecx
call dword [sym.imp.KERNEL32.dll_GetDriveTypeA]
cmp eax, 3
jne 0x40d8ec
lea edx, [esp + 0x2988]
push 0x800
lea eax, [esp + 0x40]
push edx
lea ecx, [esp + 0x48]
push eax
lea edx, [esp + 0x44]
push ecx
push edx
lea eax, [esp + 0x319c]
push 0x800
lea ecx, [esp + 0x19a0]
push eax
push ecx
call dword [sym.imp.KERNEL32.dll_GetVolumeInformationA]
test eax, eax
jne 0x40d8ff
inc ebx
cmp ebx, 0x7a
jle 0x40d86c
mov ebx, dword [esp + 0x20]
jmp 0x40d983
lea edx, [esp + 0x34]
lea eax, [esp + 0x18]
push edx
lea ecx, [esp + 0x30]
push eax
lea edx, [esp + 0x1c]
push ecx
lea eax, [esp + 0x1994]
push edx
push eax
mov esi, 0xbc614e
call dword [sym.imp.KERNEL32.dll_GetDiskFreeSpaceA]
test eax, eax
je 0x40d96d
mov ecx, dword [esp + 0x14]
mov edx, dword [esp + 0x2c]
xor eax, eax
mov dword [esp + 0x18], ecx
mov ecx, dword [esp + 0x34]
mov dword [esp + 0x1c], eax
fild qword [esp + 0x18]
mov dword [esp + 0x18], edx
mov dword [esp + 0x1c], eax
fild qword [esp + 0x18]
mov dword [esp + 0x18], ecx
mov dword [esp + 0x1c], eax
fmulp st(1)
fild qword [esp + 0x18]
fmulp st(1)
fmul qword [0x420b20]
call sub.MSVCRT.dll__ftol
mov esi, eax
mov edx, dword [esp + 0x38]
mov ebx, dword [esp + 0x20]
xor esi, edx
xor esi, ebx
xor esi, 0x65f3a713
mov dword [esp + 0x14], esi
xor eax, eax
mov dword [esp + 0x18], eax
push ebx
lea edx, [esp + 0x198c]
push str._08X
push edx
mov dword [esp + 0x499c], eax
call ebp
add esp, 0xc
lea eax, [esp + 0x1988]
push ebx
push str.HKEY_LOCAL_MACHINESOFTWARECIMCO_SoftwareSerial_08X
push eax
call ebp
lea ecx, [esp + 0x3994]
push 0x1000
lea edx, [esp + 0x1998]
push ecx
push edx
call fcn.00417880
add esp, 0x18
lea eax, [esp + 0x3988]
push str.0123456789ABCDEF
push eax
call fcn.00412070
push eax
call fcn.004122a0
add esp, 8
push eax
call dword [sym.imp.MSVCRT.dll_strspn]
add esp, 8
cmp eax, 8
jne 0x40da1a
lea ecx, [esp + 0x10]
lea edx, [esp + 0x3988]
push ecx
push str._08X
push edx
call dword [sym.imp.MSVCRT.dll_sscanf]
add esp, 0xc
jmp 0x40dada
lea eax, [esp + 0x584]
push 0x42503c
push eax
call fcn.00414e90
mov edx, eax
mov edi, str._serial.txt
or ecx, 0xffffffff
xor eax, eax
add esp, 4
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
push edx
mov esi, edi
mov ebx, ecx
mov edi, edx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, ebx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, ebx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
call dword [sym.imp.MSVCRT.dll_fopen]
mov esi, eax
add esp, 8
test esi, esi
je 0x40dad2
push esi
lea eax, [esp + 0x588]
push 9
push eax
call dword [sym.imp.MSVCRT.dll_fgets]
add esp, 0xc
test eax, eax
je 0x40dac8
lea ecx, [esp + 0x584]
push str.0123456789ABCDEF
push ecx
call fcn.00412070
push eax
call fcn.004122a0
add esp, 8
push eax
call dword [sym.imp.MSVCRT.dll_strspn]
add esp, 8
cmp eax, 8
jne 0x40dac8
lea edx, [esp + 0x10]
lea eax, [esp + 0x584]
push edx
push str._08X
push eax
call dword [sym.imp.MSVCRT.dll_sscanf]
add esp, 0xc
push esi
call dword [sym.imp.MSVCRT.dll_fclose]
add esp, 4
mov esi, dword [esp + 0x14]
mov edi, dword [esp + 0x28]
mov eax, dword [esp + 0x10]
mov ebx, dword [esp + 0x30]
mov ecx, eax
xor ecx, ebx
cmp ecx, edi
mov edi, dword [esp + 0x24]
jne 0x40db01
mov ecx, edi
call fcn.0040cf60
test eax, eax
jne 0x40de8e
mov eax, dword [esp + 0x10]
xor eax, ebx
cmp eax, esi
je 0x40de8e
mov edx, dword [esp + 0x49a0]
test edx, edx
jne 0x40dcfe
lea edx, [esp + 0x44]
push 0x20
push edx
mov ecx, edi
call fcn.0040d300
mov eax, esi
mov edx, esi
shr eax, 0x10
lea ecx, [esp + 0x49]
push eax
and edx, 0xffff
push ecx
lea eax, [esp + 0x4c]
push edx
push eax
lea ecx, [esp + 0x74]
push str._4s__04X__4s__04X
push ecx
mov byte [esp + 0x65], 0
mov byte [esp + 0x60], 0
call ebp
mov edx, dword [esp + 0x49b4]
add esp, 0x18
lea ecx, [esp + 0x988]
push 1
push edx
push str.AboutBox.dll
call fcn.00408230
push str.GetSerialNo
lea ecx, [esp + 0x98c]
mov byte [esp + 0x4994], 1
call fcn.00408300
test eax, eax
je 0x40dd2b
mov eax, dword [esp + 0x4998]
lea ecx, [esp + 0x64]
push eax
push edi
push ecx
push str.GetSerialNo
lea ecx, [esp + 0x998]
call fcn.00408300
call eax
add esp, 0xc
cmp eax, 0xffffffff
je 0x40dd2b
test eax, eax
je 0x40dd2b
mov edx, eax
xor edx, ebx
cmp edx, esi
je 0x40dbf5
mov eax, dword [0x42b01c]
push 0x2010
mov ecx, dword [eax + 0x508]
mov edx, dword [eax + 0xa5c]
push ecx
push edx
push 0
call dword [sym.imp.USER32.dll_MessageBoxA]
jmp 0x40dbf9
mov dword [esp + 0x10], eax
lea ecx, [esp + 0x988]
mov byte [esp + 0x4990], 0
call fcn.004082e0
mov eax, dword [esp + 0x10]
xor eax, ebx
cmp eax, esi
jne 0x40db0b
mov ecx, dword [esp + 0x20]
lea edx, [esp + 0x484]
push ecx
push str.HKEY_LOCAL_MACHINESOFTWARECIMCO_SoftwareSerial_08X
push edx
call ebp
mov eax, dword [esp + 0x1c]
add esp, 0xc
lea ecx, [esp + 0x84]
push eax
push str._08X
push ecx
call ebp
lea edx, [esp + 0x90]
lea eax, [esp + 0x490]
push edx
push eax
call fcn.00417ae0
mov cl, byte [0x42a800]
xor eax, eax
mov byte [esp + 0x198], cl
mov ecx, 0x3f
lea edi, [esp + 0x199]
lea edx, [esp + 0x198]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
push 0xffffffffffffffff
lea eax, [esp + 0x49c]
push edx
push eax
call fcn.00417880
lea ecx, [esp + 0xa4]
lea edx, [esp + 0x1a4]
push ecx
push edx
call dword [sym.imp.MSVCRT.dll__stricmp]
add esp, 0x28
test eax, eax
je 0x40dd46
mov ecx, dword [0x42b01c]
lea eax, [esp + 0x84]
push eax
lea eax, [esp + 0x98c]
mov edx, dword [ecx + 0xa60]
push edx
push eax
call ebp
mov ecx, dword [0x42b01c]
add esp, 0xc
lea eax, [esp + 0x988]
mov edx, dword [ecx + 0x508]
push 0x2010
push edx
push eax
push 0
call dword [sym.imp.USER32.dll_MessageBoxA]
xor al, al
jmp 0x40de90
mov ecx, dword [0x42b01c]
mov edi, edx
mov eax, dword [ecx + 0xa3c]
or ecx, 0xffffffff
push eax
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
push 0x424f84
add ecx, edx
push ecx
call ebp
add esp, 0xc
xor al, al
jmp 0x40de90
lea ecx, [esp + 0x988]
mov byte [esp + 0x4990], 0
call fcn.004082e0
xor al, al
jmp 0x40de90
lea ecx, [esp + 0x584]
push 0x20
push ecx
call fcn.00418c00
add esp, 8
lea edx, [esp + 0x584]
push 0x42500c
push edx
call fcn.00414e90
mov edx, eax
mov edi, str._serial.txt
or ecx, 0xffffffff
xor eax, eax
add esp, 4
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
push edx
mov esi, edi
mov ebx, ecx
mov edi, edx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, ebx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, ebx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edi, dword [sym.imp.MSVCRT.dll_fopen]
call edi
mov esi, eax
add esp, 8
xor bl, bl
test esi, esi
je 0x40de46
mov eax, dword [esp + 0x10]
lea ecx, [esp + 0x284]
push eax
push str._08X_n
push ecx
call ebp
add esp, 0xc
lea edx, [esp + 0x284]
push edx
push esi
call dword [sym.imp.MSVCRT.dll_fprintf]
push esi
call dword [sym.imp.MSVCRT.dll_fclose]
lea eax, [esp + 0x590]
push 0x42503c
push eax
call edi
mov esi, eax
add esp, 0x14
test esi, esi
je 0x40de46
push esi
lea ecx, [esp + 0x388]
push 0x100
push ecx
call dword [sym.imp.MSVCRT.dll_fgets]
add esp, 0xc
test eax, eax
je 0x40de38
lea edx, [esp + 0x384]
push 8
lea eax, [esp + 0x288]
push edx
push eax
mov byte [esp + 0x398], bl
call dword [sym.imp.MSVCRT.dll_strncmp]
add esp, 0xc
test eax, eax
sete bl
push esi
call dword [sym.imp.MSVCRT.dll_fclose]
add esp, 4
test bl, bl
jne 0x40de8e
mov edx, dword [0x42b01c]
lea ecx, [esp + 0x84]
push ecx
lea ecx, [esp + 0x98c]
mov eax, dword [edx + 0xa60]
push eax
push ecx
call ebp
mov edx, dword [0x42b01c]
add esp, 0xc
lea ecx, [esp + 0x988]
mov eax, dword [edx + 0x508]
push 0x2010
push eax
push ecx
push 0
call dword [sym.imp.USER32.dll_MessageBoxA]
xor al, al
jmp 0x40de90
mov al, 1
mov ecx, dword [esp + 0x4988]
pop edi
pop esi
pop ebp
pop ebx
mov dword fs:[0], ecx
add esp, 0x4984
ret 0xc