Re: ASPNET can't write in event log on win XP
From: richlm (richlm_at_nospam.nospam)
Date: 01/18/05
- Next message: Reuben Gann via DotNetMonster.com: "XPBurn RecordDisc function does nothing"
- Previous message: Nick Malik [Microsoft]: "Re: Error: dotnetfx.exe is not a valid Win32 application"
- In reply to: Stephane: "ASPNET can't write in event log on win XP"
- Next in thread: Stephane: "Re: ASPNET can't write in event log on win XP"
- Reply: Stephane: "Re: ASPNET can't write in event log on win XP"
- Messages sorted by: [ date ] [ thread ]
Date: Tue, 18 Jan 2005 10:00:32 +0100
see http://support.microsoft.com/default.aspx?scid=kb;en-us;842795
Yes the default registry permissions on XP/2003 are tighter than on 2000.
The first time your app tries to write to the event log, it checks to see if
an event source for your application (typically the application name)
already exists. If not, it tries to create it.
Event log sources are stored in the registry under:
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Eventlog\...
Changing file system permissions will have no effect on the registry. If you
start regedit.exe and locate the registry key above, right click and select
'Permissions' you can see which accounts do have access.
You could just add the ASPNET account here, but this is a BAD idea because
it will complicate deployment of your application and weaken security.
The usual solution is to create the event source at installation time using
EventLog.CreateEventSource (or the EventLogInstaller class). Installation
will normally be done in the context of an administrator account.
Here's a couple of links to get you started:
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/vbcon/html/vbwlkWalkthroughCreatingEventLogInstallers.asp
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/vbcon/html/vbtskaddingyourapplicationassourceofeventlogentries.asp
- Next message: Reuben Gann via DotNetMonster.com: "XPBurn RecordDisc function does nothing"
- Previous message: Nick Malik [Microsoft]: "Re: Error: dotnetfx.exe is not a valid Win32 application"
- In reply to: Stephane: "ASPNET can't write in event log on win XP"
- Next in thread: Stephane: "Re: ASPNET can't write in event log on win XP"
- Reply: Stephane: "Re: ASPNET can't write in event log on win XP"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|