Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / .NET Framework / CLR / November 2005

Tip: Looking for answers? Try searching our database.

CLR host process account

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Jim Weiler - 31 Oct 2005 19:22 GMT
[This followup was posted to microsoft.public.dotnet.framework.clr and a
copy was sent to the cited author.]

When managed code is started, the CLR is loaded into a process and it
starts executing the managed code.
Q1. How is the process used to host the CLR determined?
Q2. what account does that process run under and how can you configure
the account that process runs under?

Thanks, Jim
Mattias Sjögren - 31 Oct 2005 20:12 GMT
>Q1. How is the process used to host the CLR determined?

It loads into the current process,  i.e. the one started by the
managed code EXE. It doesn't run as a separate process.

>Q2. what account does that process run under and how can you configure
>the account that process runs under?

Whatever the current process is running under.

Mattias

Signature

Mattias Sjögren [MVP]  mattias @ mvps.org
http://www.msjogren.net/dotnet/ | http://www.dotnetinterop.com
Please reply only to the newsgroup.

Bajoo - 01 Nov 2005 09:53 GMT
Q1. How is the process used to host the CLR determined?
When the compiler/linker creates an assembly, JMP _CorExeMain 6-byte
x86 stub function is emitted into the PE file's. _CorExeMain function
belongs to Microsoft's MSCorEE.dll dynamic-link library. When managed
executable is invoked, OS treats it like unmanaged executable. Then the
loader obtains the address of the _CorExeMain function inside
MSCorEE.dll. _CorExeMain starts CLR and then looks at the executable
assembly's matadata to determine what entry point method should
execute. Its runs in the current Process not as a saperate process. In
XP and windows 2003 its a little different it checks the Directory
Entry 14.

Q2. what account does that process run under and how can you configure
the account that process runs under?
Under which the current process is running but you can change that
afterwards using System.Security.Permissions classes.

I hope it helps.

Regdrs,
Naveed Ahmad Bajwa
Kalsoft Pvt Ltd.
"Jeffrey Tan[MSFT]" - 07 Nov 2005 08:22 GMT
Hi Jim,

Does the community's replies make sense to you? If you still have any
concern, please feel free to tell me, thanks

Best regards,
Jeffrey Tan
Microsoft Online Partner Support
Signature

Get Secure! - www.microsoft.com/security
This posting is provided "as is" with no warranties and confers no rights.


Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.