User impersation in VB.NET, logonuser succeeds but that's about it...

S

Sven Eric

Hi All,

I try to use user-impersonation in VB.NET with a user (let's call him Bill).
I'm using the LogonUser function to create the token and so on. This
works --> calling WindowsIdentity.GetCurrent().Name() afterwards gives me
the username I'm try to impersonate. But this is about all I can do, I don't
have access to the users files on the network, for instance I get an access
denied error when I try to open a file on
\\our-fileserver\home\bill\documents .

What am I missing?

Thnx in advance.


Sven
 
S

Sven Eric

Dear Ken,

Thanks for your speedy reply. I've checked out the article you sent me. The
code is pretty much the same code I've been using. The results are as they
should be: impersonation of the user is successful, however while
impersonating the user I don't have access to his/her files on the file
server...

Thanks again,

Sven
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top