Get drive information volume device &&ring3 get Disk File system (NTFS WIN10)

Source: Internet
Author: User

1 //GetLogicalDriveStrings.cpp: Defines the entry point of the console application. 2 //3 4#include"stdafx.h"5#include <Windows.h>6#include <iostream>7 8 using namespacestd;9 Ten voidSub_1 ();//Enumerate Volumes---> Disks && NTFS (WIN10) for a computer One  A  - intMain () - { the  - sub_1 (); -  -     return 0; + } -  + voidsub_1 () A { at     Charvolumedevicestring[0x500] = {0 }; -     //The previous byte is a message type, and the following 52 bytes are drive-related properties -BYTE bufferdata[0x1000] = {0 }; -     CharFilesystem[max_path] = {0 }; -     Char*travel =NULL; -      inGetLogicalDriveStrings (sizeof(volumedevicestring), volumedevicestring); -  to  +     //Get drive Information -     /* the 0x001ff228 3a 5c (3a) 5c 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 The xx xx xx (c) xx xx xx at xx. E:\ ........ *     */ $ Panax Notoginseng     //0018f460 3 A 5C 3 a 5C 3 a 5C xx 3 a c \. D:\. E:\. F: -     //0018f46e 5C 3 A 5C 3 a 5C 4 a 3 a 5C 00 \. G:\. H:\. J:\. theTravel =volumedevicestring; +  ADWORD Offset =0; the      for(Offset =1; *travel! =' /'; Travel + = Lstrlen (travel) +1)//+1 here for the sake of. +     { -memset (FileSystem,0,sizeof(FileSystem));//File System NTFS $  $                                                     //get file system information and size -GetVolumeInformation (Travel, NULL,0, NULL, NULL, NULL, FileSystem, MAX_PATH); -ULONG filesystemlength = lstrlen (FileSystem) +1; the  -         intA =0;Wuyi     } the  -  Wu}

Get drive information volume device &&ring3 get Disk File system (NTFS WIN10)

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.