Re: ObReferenceObjectByName

Hi all ‘smart’ guys !
I’ve try to get of the LanmanRedirector device object by call ObReferenceObjectByName.
My sake is getting device object of it and attach with netware drives.
The my code was looked at next manner:

WCHAR wszLinkPath = L"\Device\LanmanRedirector";
UNICODE_STRING szLinkPath;
PDRIVER_OBJECT lpDriverObject;
PDEVICE_OBJECT lpDeviceObject;
NTSTATUS Status;

RtlInitUnicodeString(&szLinkPath,wszLinkPath);
InitializeObjectAttributes( &ObjectAttributes,&szLinkPath,OBJ_CASE_INSENSITIVE,
NULL,NULL);
ObReferenceObjectByName(&szLinkPath, OBJ_CASE_INSENSITIVE, NULL, 0,
*IoDeviceObjectType, KernelMode, NULL, &lpDeviceObject);

The last of call always returns 0xC0000024L = STATUS_OBJECT_TYPE_MISMATCH
Changing of lpDeviceObject to lpDriverObject and of IoDeviceObjectType to IoDriverObjectType
was bring same result.

Do anybody can say to me, which POBJECT_TYPE i must use for mentioned call for succesfull
implement of attaching with netware drives. Waiting until Of oser Process context does occured
is unacceptable.

Lanman has nothing to do with NetWare.

Max

----- Original Message -----
From: Oleg Nikityenko
To: File Systems Developers
Sent: Monday, April 01, 2002 5:51 PM
Subject: [ntfsd] Re: ObReferenceObjectByName

Hi all ‘smart’ guys !
I’ve try to get of the LanmanRedirector device object by call ObReferenceObjectByName.
My sake is getting device object of it and attach with netware drives.
The my code was looked at next manner:

WCHAR wszLinkPath = L"\Device\LanmanRedirector";
UNICODE_STRING szLinkPath;
PDRIVER_OBJECT lpDriverObject;
PDEVICE_OBJECT lpDeviceObject;
NTSTATUS Status;

RtlInitUnicodeString(&szLinkPath,wszLinkPath);
InitializeObjectAttributes( &ObjectAttributes,&szLinkPath,OBJ_CASE_INSENSITIVE,
NULL,NULL);
ObReferenceObjectByName(&szLinkPath, OBJ_CASE_INSENSITIVE, NULL, 0,
*IoDeviceObjectType, KernelMode, NULL, &lpDeviceObject);

The last of call always returns 0xC0000024L = STATUS_OBJECT_TYPE_MISMATCH
Changing of lpDeviceObject to lpDriverObject and of IoDeviceObjectType to IoDriverObjectType
was bring same result.

Do anybody can say to me, which POBJECT_TYPE i must use for mentioned call for succesfull
implement of attaching with netware drives. Waiting until Of oser Process context does occured
is unacceptable.

You are currently subscribed to ntfsd as: xxxxx@storagecraft.com
To unsubscribe send a blank email to %%email.unsub%%

Hi all,

How can I kill a process under kernel mode ?

Thanks in advance,

Heldai
----- Original Message -----
From: Maxim S. Shatskih
To: File Systems Developers
Sent: Monday, April 01, 2002 2:10 PM
Subject: [ntfsd] Re: ObReferenceObjectByName

Lanman has nothing to do with NetWare.

Max

----- Original Message -----
From: Oleg Nikityenko
To: File Systems Developers
Sent: Monday, April 01, 2002 5:51 PM
Subject: [ntfsd] Re: ObReferenceObjectByName

Hi all ‘smart’ guys !
I’ve try to get of the LanmanRedirector device object by call ObReferenceObjectByName.
My sake is getting device object of it and attach with netware drives.
The my code was looked at next manner:

WCHAR wszLinkPath = L"\Device\LanmanRedirector";
UNICODE_STRING szLinkPath;
PDRIVER_OBJECT lpDriverObject;
PDEVICE_OBJECT lpDeviceObject;
NTSTATUS Status;

RtlInitUnicodeString(&szLinkPath,wszLinkPath);
InitializeObjectAttributes( &ObjectAttributes,&szLinkPath,OBJ_CASE_INSENSITIVE,
NULL,NULL);
ObReferenceObjectByName(&szLinkPath, OBJ_CASE_INSENSITIVE, NULL, 0,
*IoDeviceObjectType, KernelMode, NULL, &lpDeviceObject);

The last of call always returns 0xC0000024L = STATUS_OBJECT_TYPE_MISMATCH
Changing of lpDeviceObject to lpDriverObject and of IoDeviceObjectType to IoDriverObjectType
was bring same result.

Do anybody can say to me, which POBJECT_TYPE i must use for mentioned call for succesfull
implement of attaching with netware drives. Waiting until Of oser Process context does occured
is unacceptable.

You are currently subscribed to ntfsd as: xxxxx@storagecraft.com
To unsubscribe send a blank email to %%email.unsub%%

You are currently subscribed to ntfsd as: xxxxx@scuasecurity.com.br
To unsubscribe send a blank email to %%email.unsub%%

Sorry, I forget change the subject…
----- Original Message -----
From: Heldai
To: File Systems Developers
Sent: Monday, April 01, 2002 4:45 PM
Subject: [ntfsd] Re: ObReferenceObjectByName

Hi all,

How can I kill a process under kernel mode ?

Thanks in advance,

Heldai
----- Original Message -----
From: Maxim S. Shatskih
To: File Systems Developers
Sent: Monday, April 01, 2002 2:10 PM
Subject: [ntfsd] Re: ObReferenceObjectByName

Lanman has nothing to do with NetWare.

Max

----- Original Message -----
From: Oleg Nikityenko
To: File Systems Developers
Sent: Monday, April 01, 2002 5:51 PM
Subject: [ntfsd] Re: ObReferenceObjectByName

Hi all ‘smart’ guys !
I’ve try to get of the LanmanRedirector device object by call ObReferenceObjectByName.
My sake is getting device object of it and attach with netware drives.
The my code was looked at next manner:

WCHAR wszLinkPath = L"\Device\LanmanRedirector";
UNICODE_STRING szLinkPath;
PDRIVER_OBJECT lpDriverObject;
PDEVICE_OBJECT lpDeviceObject;
NTSTATUS Status;

RtlInitUnicodeString(&szLinkPath,wszLinkPath);
InitializeObjectAttributes( &ObjectAttributes,&szLinkPath,OBJ_CASE_INSENSITIVE,
NULL,NULL);
ObReferenceObjectByName(&szLinkPath, OBJ_CASE_INSENSITIVE, NULL, 0,
*IoDeviceObjectType, KernelMode, NULL, &lpDeviceObject);

The last of call always returns 0xC0000024L = STATUS_OBJECT_TYPE_MISMATCH
Changing of lpDeviceObject to lpDriverObject and of IoDeviceObjectType to IoDriverObjectType
was bring same result.

Do anybody can say to me, which POBJECT_TYPE i must use for mentioned call for succesfull
implement of attaching with netware drives. Waiting until Of oser Process context does occured
is unacceptable.

You are currently subscribed to ntfsd as: xxxxx@storagecraft.com
To unsubscribe send a blank email to %%email.unsub%%

You are currently subscribed to ntfsd as: xxxxx@scuasecurity.com.br
To unsubscribe send a blank email to %%email.unsub%%

You are currently subscribed to ntfsd as: xxxxx@scuasecurity.com.br
To unsubscribe send a blank email to %%email.unsub%%