Re: How to mount a volume as a current user.

Tech Tip: Click here to run a free scan for Windows Errors and optimize PC performance



Use SUBST to create a session-local mapping.

Creating a reparse point will affect all users and is persistent. Because of
that, it requires admin privileges.

"JPB" <JPB@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
news:288AFF89-E6F6-4C61-88B7-A589AFE123E5@xxxxxxxxxxxxxxxx
Sorry David,

The driver I wrote is not the trouble.

Look on your XP.
Create a normal local or domain user.

Use mountvol.exe to mount yours CDROM on C:\mnt\cdrom. I receive an access
denied.
So my question is How can a user mount a volume? What is the security
point ?

Thanks in advance.

"David Craig" wrote:

This is the wrong newsgroup for your question. It is NOT about how to do
this from a user mode app, but how to do it correctly from the driver.
Look
at the mount*.h header files in the WDK for clues. Also look at the
source
code for disk.sys in the WDK. Not all that difficult.


"JPB" <JPB@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
news:A18DD0F7-9773-4C8B-9F21-A0E10491820D@xxxxxxxxxxxxxxxx
Hi,

I wrote some piece of code using the API "SetVolumeMountPoint" wich
allow
me
to mount a volume wich looks like \\?\Volume{GUID} (I create myself
this
volume from my own driver) in an NTFS folder.

It works as far as my process run as an user from the "administrators"
group, but when I try tu run it as a normal user I receive an "access
denied".

As in Vista I get also an "access denied" when my process run as an
user
from the "administrators" group I dig the users access right (former
privilege) but no success.

I know how to put NTFS rights on the root of the volume I mount. But
I'am
not so clear with the access right of the "\\?\Volume{GUID}" object.

Is this object just a link on the internal "\device\Mydriver" object ?
As
swhon in WinObj (Sysinternals tool).

How can I change the DACL of this object ?

Do have I to change the acces rights of "\device\Mydriver" (deficult
for
me
I'am not allowed to use IoCreateDeviceSecure to run from W2K to Vista)
?

So can anybody can help me to use Mountvol.exe as a user ?

Thanks in advance.

Cheers

PS : last solution will be to mount from a service, but I'am a bit
upset
to
create a service just for that !





.



Relevant Pages

  • Re: How to mount a volume as a current user.
    ... Privilege / DACL. ... The driver I wrote is not the trouble. ... So my question is How can a user mount a volume? ... I know how to put NTFS rights on the root of the volume I mount. ...
    (microsoft.public.win32.programmer.kernel)
  • Re: How to mount a volume as a current user.
    ... The driver I wrote is not the trouble. ... So my question is How can a user mount a volume? ... I know how to put NTFS rights on the root of the volume I mount. ... I'am not allowed to use IoCreateDeviceSecure to run from W2K to Vista)? ...
    (microsoft.public.win32.programmer.kernel)
  • Re: Cannot mount cdrom? Pls help
    ... checking for saved MCA error records ... CPU 1 SAL log contains MCA error record ... > EFI Time Services Driver v0.4 ... I also cannot mount /media/cdrom. ...
    (linux.redhat.misc)
  • RE: Unable to mount the SD card formatted using the DIGITAL CAMREA on Linux box
    ... Below are my driver messages logged at initialization time & sfdisk call ... TIFM INFO | TI init Routine Invoked! ... Mount: you must specify the filesystem type ... If you are not the intended recipient, ...
    (Linux-Kernel)
  • Re: UDC performance on PXA270
    ... I did some more tests on my PXA270 UDC using the Mass_Storage_Class. ... Mount my Flash File System as the Mass Storage: ... Mount a USB Stick as the Mass Storage: ... driver ...
    (microsoft.public.windowsce.platbuilder)