Question - How do I enable my ASP.NET application to write to new event source

J.D. Meier, Alex Mackman, Blaine Wastell, Prashant Bansode, Andy Wigley, Kishore Gopalan

Applies to

Answer:

To enable your ASP.NET application to write to the event log using its own event source, you have two options:

The default ASP.NET worker process identities have sufficient permissions to write records to the event log using existing event sources. However, if your application needs to create new event sources using the default worker process identity, it would fail as the default worker process identity does not have privileges to create event sources. In a production scenario where you might be using, custom domain account for running the ASP.Net application instead of the default. The permissions on the registry must be granted to the custom domain account. If you have configured your application to use impersonation, then permissions must be granted to the authenticated user's account or IUSR_machineName for anonymous callers.

Additional Resources

Attributes

  • Author: J.D. Meier, Alex Mackman, Blaine Wastell, Prashant Bansode, Andy Wigley, Kishore Gopalan

  • Category: Exception Management

  • filePath: ..\Libraries\patterns & practices Library\faq\fe312307-b199-428a-a253-9dd7a6e7899d.xml

  • Pri: 2

  • Rule Type: Implementation

  • Source: patterns & practices Library

  • Status: Release

  • Technology: ASP.NET 2.0

  • Title: Question - How do I enable my ASP.NET application to write to new event source

  • Topic: Security

  • Type: Question and Answer

  • ID: fe312307-b199-428a-a253-9dd7a6e7899d