Ask a Question related to ASP.NET Security, Design and Development.
-
TBALKAN #1
JIT compilation failure with impersonation
We have two machines. Machine1 is the web server and Machine2 is the 'file
server'. The goal is to read and write files from Machine2 using the
aspnet_wp.exe process which is running under ASPNET credentials on Machine1.
In order to do that we added the identity element into the web.config and
provided a domain-level account to use for impersonation. That account has
Modify permissions on the folder in which it is trying to read the file from
on Machine2. When the transaction is finished (which involves accessing the
remote resource on Machine2), and the user tries to open a web page that was
not previously JIT compiled, we get the following error:
Exception Type: System.Web.HttpException
Exception:
An unhandled exception occurred during compilation using the CodeDomProvider
'Microsoft.VisualBasic.VBCodeProvider'. Please review the stack trace for
more information about the error and where it originated in the code.
StackTrace:
at System.Web.UI.TemplateParser.GetParserCacheItemInt ernal(Boolean
fCreateIfNotFound) at System.Web.UI.TemplateParser.GetParserCacheItem() at
System.Web.UI.TemplateControlParser.CompileAndGetP arserCacheItem(String
virtualPath, String inputFile, HttpContext context) at
System.Web.UI.TemplateControlParser.GetCompiledTyp e(String virtualPath,
String inputFile, HttpContext context) at
System.Web.UI.UserControlParser.GetCompiledUserCon trolType(String
virtualPath, String inputFile, HttpContext context) at
System.Web.UI.TemplateControl.LoadControl(String virtualPath) at
E3Container.E3WebPartWindowUC.LoadWebPart(String strInitData, IE3Container
pE3Container)
TargetSite: System.Web.UI.TemplateParser.GetParserCacheItemInt ernal
Parameters:
- System.Boolean fCreateIfNotFound
::InnerException::
Exception Type: System.Web.HttpUnhandledException
Exception:
An unhandled exception occurred during compilation using the CodeDomProvider
'Microsoft.VisualBasic.VBCodeProvider'. Please review the stack trace for
more information about the error and where it originated in the code.
StackTrace:
at System.Web.Compilation.BaseCompiler.GetCompiledTyp e() at
System.Web.UI.UserControlParser.CompileIntoType() at
System.Web.UI.TemplateParser.GetParserCacheItemThr oughCompilation()
TargetSite: System.Web.Compilation.BaseCompiler.GetCompiledTyp e
::InnerException::
Exception Type: System.Runtime.InteropServices.ExternalException
Exception:
Cannot execute a program. The command being executed was
"c:\winnt\microsoft.net\framework\v1.1.4322\vbc.ex e"
@"C:\WINNT\Microsoft.NET\Framework\v1.1.4322\Tempo rary ASP.NET
Files\e3container\b879c699\68436b67\o-5s2ovn.cmdline".
StackTrace:
at System.CodeDom.Compiler.Executor.ExecWaitWithCaptu reUnimpersonated(IntPtr
userToken, String cmd, String currentDir, TempFileCollection tempFiles,
String& outputName, String& errorName, String trueCmdLine) at
System.CodeDom.Compiler.Executor.ExecWaitWithCaptu re(IntPtr userToken, String
cmd, String currentDir, TempFileCollection tempFiles, String& outputName,
String& errorName, String trueCmdLine) at
System.CodeDom.Compiler.CodeCompiler.Compile(Compi lerParameters options,
String compilerDirectory, String compilerExe, String arguments, String&
outputFile, Int32& nativeReturnValue, String trueArgs) at
System.CodeDom.Compiler.CodeCompiler.FromFileBatch (CompilerParameters
options, String[] fileNames) at
System.CodeDom.Compiler.CodeCompiler.FromDomBatch( CompilerParameters options,
CodeCompileUnit[] ea) at
System.CodeDom.Compiler.CodeCompiler.FromDom(Compi lerParameters options,
CodeCompileUnit e) at
System.CodeDom.Compiler.CodeCompiler.System.CodeDo m.Compiler.ICodeCompiler.CompileAssemblyFromDom(Co mpilerParameters
options, CodeCompileUnit e) at
System.Web.Compilation.BaseCompiler.GetCompiledTyp e()
TargetSite:
System.CodeDom.Compiler.Executor.ExecWaitWithCaptu reUnimpersonated
Parameters:
- System.IntPtr userToken
- System.String cmd
- System.String currentDir
- System.CodeDom.Compiler.TempFileCollection tempFiles
- System.String& outputName
- System.String& errorName
- System.String trueCmdLine
We have checked permission for all temp folders (Framework, Winnt, etc.)
where the JIT compilation might occur.
Thanks,
Tony
TBALKAN Guest
-
Impersonation
Can someone explain this to me I have a web app I am trying to deploy for the Intranet of our company. I want to use integrated windows so have... -
Impersonation in ASP.Net
Hi, you can enter a domainuser for the anonymous access. Than you just have to activate impersonation for your web application. Modify the... -
Impersonation failure
Hi, I am trying to implement Impersonation in ASP .Net, but can not get it to work. I have copied the sample code to impersonate a specific user... -
Impersonation failure with Index Server and Forms Authentication with Active Directory
I'm posting my problem experience and solution I found here for other ASP.NET developers. I have a web application that uses Forms Authentication... -
ASP.NET Impersonation over VPN?
Has anyone had any issues using Impersonation over a VPN? I work from home (have my own domain), and use Cisco's VPN Client (version 4) to...



Reply With Quote

