Hi,
I want to disable any reads from or write to a particular drive.
Is this possible programatically? If so, do you have any suggestions on how
I can accomplish this?
Thank you,
Marc
Well, you could always remove the device programmatically; from Win32 I
believe you achieve this using the SetupDi functions.
If you wanted to build a filter of some sort you could do that (disk or
port level). File system filter level is too high in the stack, though.
If you want to pursue a disk filter, I’d suggest asking further
questions in NTDEV, since they worry about things like block storage.
Regards,
Tony
Tony Mason
Consulting Partner
OSR Open Systems Resources, Inc.
http://www.osr.com http:</http:>
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of Marc Cruz
Sent: Monday, August 29, 2005 6:07 PM
To: ntfsd redirect
Subject: [ntfsd] Is it possible to disable file sharing to a particular
drive programatically?
Hi,
I want to disable any reads from or write to a particular drive.
Is this possible programatically? If so, do you have any suggestions on
how I can accomplish this?
Thank you,
Marc
— Questions? First check the IFS FAQ at
https://www.osronline.com/article.cfm?id=17 You are currently subscribed
to ntfsd as: unknown lmsubst tag argument: ‘’ To unsubscribe send a
blank email to xxxxx@lists.osr.com
The title of your question asks about file sharing,
the text of the message asks about reads/writes from
the volume. Which is correct ?
L.
Sorry,
What I meant to ask is:
Can I disable network file sharing programmatically? I would like to
disallow any reads and writes from the network file share only for a
particular drive.
Thanks,
Marc
On 8/29/05, Ladislav Zezula wrote:
>
> The title of your question asks about file sharing,
> the text of the message asks about reads/writes from
> the volume. Which is correct ?
> L.
>
> —
> Questions? First check the IFS FAQ at
> https://www.osronline.com/article.cfm?id=17
>
> You are currently subscribed to ntfsd as: unknown lmsubst tag argument: ‘’
>
> To unsubscribe send a blank email to xxxxx@lists.osr.com
>
Filter MJ_CREATE in the FSF, get Parameters->Create.SecurityContext from the IRP, get the access token from it, get its group list and check for Network pseudo-group (it has the well-known SID).
This will not disable the share creation (filtering undocumented IOCTLs to \Device\LanmanServer is the only way, and this is very fragile and unreliable), but will disable any accesses to the files from SRV’s clients.
Maxim Shatskih, Windows DDK MVP
StorageCraft Corporation
xxxxx@storagecraft.com
http://www.storagecraft.com
----- Original Message -----
From: Marc Cruz
To: Windows File Systems Devs Interest List
Sent: Tuesday, August 30, 2005 2:05 PM
Subject: Re: [ntfsd] Is it possible to disable file sharing to a particular drive programatically?
Sorry,
What I meant to ask is:
Can I disable network file sharing programmatically? I would like to disallow
What’s wrong with the user-mode management APIs for the file sharing
service?
If you want to disable all file sharing – stop and disable the service.
If you want to disable access to a particular drive – set ACLs on the drive
that contain “deny” ACEs for the Network SID.
There’s no need to intercept IRPs.
– arlie
----- Original Message -----
From: Marc Cruz mailto:xxxxx
To: Windows File Systems Devs Interest List mailto:xxxxx
Sent: Tuesday, August 30, 2005 2:05 PM
Subject: Re: [ntfsd] Is it possible to disable file sharing to a particular
drive programatically?
Sorry,
What I meant to ask is:
Can I disable network file sharing programmatically? I would like to
disallow
—
Questions? First check the IFS FAQ at
https://www.osronline.com/article.cfm?id=17
You are currently subscribed to ntfsd as: unknown lmsubst tag argument: ‘’
To unsubscribe send a blank email to xxxxx@lists.osr.com</mailto:xxxxx></mailto:xxxxx>