Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > Accessing files and folders on remote server - SERVER ERROR

Reply
Thread Tools

Accessing files and folders on remote server - SERVER ERROR

 
 
phil.stollery@gmail.com
Guest
Posts: n/a
 
      02-15-2006
Hi,

I've currently setup a local user as described in:

http://msdn.microsoft.com/library/de...SecNetHT01.asp

This users has been created on the remote server, and locally on our
web farm servers. All access to NTFS file system has been setup and the
users local privileges. However, when I add the

<identity impersonate="true" userName="YourAccount"
password="YourStrongPassword" />

Code in the web.config file, the website starts behaving in an
unpredictable manner - mainly blowing up with the following error:

Server Error in '/admin' Application.
--------------------------------------------------------------------------------

Cannot execute a program. The command being executed was
"c:\windows\microsoft.net\framework\v1.1.4322\csc. exe" /noconfig
@"C:\WINDOWS\Microsoft.NET\Framework\v1.1.4322\Tem porary ASP.NET
Files\admin\1afb246b\8ae84806\pu6rzxdn.cmdline".
Description: An unhandled exception occurred during compilation using
the CodeDomProvider 'Microsoft.CSharp.CSharpCodeProvider'. Please
review the stack trace for more information about the error and where
it originated in the code.

Exception Details: System.Runtime.InteropServices.ExternalException:
Cannot execute a program. The command being executed was
"c:\windows\microsoft.net\framework\v1.1.4322\csc. exe" /noconfig
@"C:\WINDOWS\Microsoft.NET\Framework\v1.1.4322\Tem porary ASP.NET
Files\admin\1afb246b\8ae84806\pu6rzxdn.cmdline".

Source Error:

An unhandled exception was generated during the execution of the
current web request. Information regarding the origin and location of
the exception can be identified using the exception stack trace below.


Stack Trace:


[ExternalException (0x10b): Cannot execute a program. The command being
executed was "c:\windows\microsoft.net\framework\v1.1.4322\csc. exe"
/noconfig @"C:\WINDOWS\Microsoft.NET\Framework\v1.1.4322\Tem porary
ASP.NET Files\admin\1afb246b\8ae84806\pu6rzxdn.cmdline".]

System.CodeDom.Compiler.Executor.ExecWaitWithCaptu reUnimpersonated(IntPtr
userToken, String cmd, String currentDir, TempFileCollection tempFiles,
String& outputName, String& errorName, String trueCmdLine) +2054
System.CodeDom.Compiler.Executor.ExecWaitWithCaptu re(IntPtr
userToken, String cmd, String currentDir, TempFileCollection tempFiles,
String& outputName, String& errorName, String trueCmdLine) +260
System.CodeDom.Compiler.CodeCompiler.Compile(Compi lerParameters
options, String compilerDirectory, String compilerExe, String
arguments, String& outputFile, Int32& nativeReturnValue, String
trueArgs) +383

System.CodeDom.Compiler.CodeCompiler.FromFileBatch (CompilerParameters
options, String[] fileNames) +548
System.CodeDom.Compiler.CodeCompiler.FromDomBatch( CompilerParameters
options, CodeCompileUnit[] ea) +428
System.CodeDom.Compiler.CodeCompiler.FromDom(Compi lerParameters
options, CodeCompileUnit e) +90

System.CodeDom.Compiler.CodeCompiler.System.CodeDo m.Compiler.ICodeCompiler.CompileAssemblyFromDom(Co mpilerParameters
options, CodeCompileUnit e) +37
System.Web.Compilation.BaseCompiler.GetCompiledTyp e() +227




--------------------------------------------------------------------------------
Version Information: Microsoft .NET Framework Version:1.1.4322.2300;
ASP.NET Version:1.1.4322.2300


If I remove the impersonation - the site works fine, apart from the
fact I can't read/write to the remote server. I have googled till I'm
blind, anyone any ideas?

 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Security Exception - Accessing remote folders & files addey ASP .Net Security 0 09-10-2008 10:37 AM
zipping files folders and sub folders w/ winzip or winrar Mike Computer Support 5 03-28-2008 09:10 PM
Desktop accesses laptop and reads folders but Laptop only accesses/opens Desktop but cannot read folders, access is denied onclejon Wireless Networking 3 11-01-2006 10:50 PM
Accessing files and folders =?Utf-8?B?U2Fs?= Wireless Networking 1 04-21-2005 09:39 PM
Accessing files and folders on remote server in webApplication =?Utf-8?B?WjBnUw==?= ASP .Net 2 02-04-2004 01:41 AM



Advertisments