EldoS | Feel safer!

Software components for data protection, secure storage and transfer

Creating Device Handle: THE PARAMETER IS INCORRECT

Also by EldoS: SecureBlackbox
200+ components and classes for digital security, signing, encryption and secure networking.
#20894
Posted: 07/26/2012 10:15:59
by Ali Malik (Basic support level)
Joined: 07/26/2012
Posts: 3

Hi,

I've installed the drivers successfully and I could verify it using GetDriverStatus() function. But, I've problem in creating device handle. The device handle always returns
Quote
FFFFFFFF
and through GetLastError(), I receive
Quote
The parameter is incorrect
.
I tried all three functions: Open, OpenEx and CreateFile. That's why I'm unable to use it in DeviceIoControl, ReadFile and WriteFile function.

Code
#define SEL_DRIVE L"\??\PhysicalDrive0" // also checked with L"\??\C:"

status   = CRawDisk::GetDriverStatus("ElRawDisk", rawdisk_status, &dfile_v1, &dfile_v2, NULL);

DeviceHandle = CRawDisk::Open(SEL_DRIVE, GENERIC_READ | GENERIC_WRITE, RAWDISK_LICENSE_KEY); // also checked with openex and creatfile functions
#20895
Posted: 07/26/2012 10:20:15
by Ali Malik (Basic support level)
Joined: 07/26/2012
Posts: 3

Is it due to wrong license key or Devicename? But, I double checked the license key and also device name is according to the documentation.
#20896
Posted: 07/26/2012 10:34:47
by Volodymyr Zinin (EldoS Corp.)

> #define SEL_DRIVE L"\??\PhysicalDrive0"
Use the double backslash:
#define SEL_DRIVE L"\\??\\PhysicalDrive0"
#20897
Posted: 07/26/2012 10:50:19
by Ali Malik (Basic support level)
Joined: 07/26/2012
Posts: 3

Thanks.
It works!

Reply

Statistics

Topic viewed 4061 times

Number of guests: 1, registered members: 0, in total hidden: 0




|

Back to top

As of July 15, 2016 EldoS Corporation will operate as a division of /n software inc. For more information, please read the announcement.

Got it!