I have a web server where people upload files. I need to make these files and write them to a file share in an Active Directory domain. Problem - the web server is not in the domain.
So how is the best way to do this? I would have thought it would be easy, something like creating a connection with some credentials and doing it. But apparently not. The closest I found is an impersonation WindowsIdentity.Impersonate, but all I read says this is a bad idea in a production environment.
Any ideas? I am working on a solution that supports FTP files, but this is unsatisfactory and has a backup plan.
I am using C # and .net 4.0 in a (obviously) Windows environment.
Change: . I must indicate that I cannot start servers (or services) that access the outside of this domain. FTP connection is a temporary solution.
source
share