HighTechTalks DotNet Forums  

Help on EventLog security ???

Dotnet Security microsoft.public.dotnet.security


Discuss Help on EventLog security ??? in the Dotnet Security forum.



Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old   
=?Utf-8?B?Y2FsZGVyYXJh?=
 
Posts: n/a

Default Help on EventLog security ??? - 07-19-2007 , 10:20 AM






Dear all,

I am buidling as assembly which logs potentials generated error or exception
in Event viewer.
For that I am through code creating an EventSource for the log before
writing inside.
I have noticed that for creating that source you need to be an administrator
user.
So if my libryr is executed my a client aplication under a normal user
context, I will have an exception error when creating the EventSource.

How can I be an administrator from my code only during the needed time ?
Sure I might change the contect of my code to be an admin and then
impersonate during the execution of my admin part, then probably use the Undo
method to recover to normal user but how ?

My assembly would need also the EvenLog permission i guess ?
As declarative of imperative mode.

thnaks for help
regards
serge

Reply With Quote
Reply




Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

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

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.