PlayKid
PlayKid

Reputation: 871

In C#, how do I Opening file even if the user do not have right to access the physical server?

How do I open a file, any file, like txt file from another machine, even the user who is opening the file do not have right to access to the machine where the file actually store?

I would like to create an application who will show a list of files which stores on another machine, and those files can be access by whoever have access to my application, via my application, the usr can then open the file from his/her side.

Thanks alot

PlayKid

Upvotes: 0

Views: 62

Answers (2)

Marino Šimić
Marino Šimić

Reputation: 7340

If you cannot access the other computer because of network sharing restrictions (like domain rules) then probably not in that way.

But if you have access to install applications to the other computer what you basically want is a file sharing application.

That however is too much to explain and should be googled about.

Upvotes: 0

Darin Dimitrov
Darin Dimitrov

Reputation: 1039548

You could execute the code that will fetch the remote file under an account that will have access to this file. This involves storing the username/password of the account in your application though which could be a security issue.

If this is an ASP.NET application you could grant permissions to the account executing this application sufficient permissions in order to access the remote resource.

Upvotes: 1

Related Questions