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 / ASP.NET / Security / November 2006

Tip: Looking for answers? Try searching our database.

ASP.NET Custom Identity bad environment !

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Olivier Matrot - 22 Nov 2006 11:00 GMT
Hello all,
Environment : Windows 2003/ASP.NET 2.0.
I have changed the process identity of an application pool to a custom
identity following this link :
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnpag2/html/pag
ht000009.asp


This is working partially. The worker process use my custom identity but do
not load the corresponding profile (or fails to do it ?). Thus, the
environment of the process is inherited from the identity of the parent
process, which is lcoal system.

I need to have a correct profile because, I need to acces the user's
temporary directory. Last but not least, I want to use SQL Express 2005 User
Instances. This is not working for the same reason : bad user  profile.

Any help appreciated.

TIA.
Dominick Baier - 22 Nov 2006 11:49 GMT
Hi,

profiles are not loaded by IIS6

dominick

> Hello all,
> Environment : Windows 2003/ASP.NET 2.0.
[quoted text clipped - 15 lines]
>
> TIA.
Olivier Matrot - 22 Nov 2006 14:19 GMT
Is there a way to have a profile loaded by hand ?
I already know that in IIS7, profiles could be loaded. This is nice.

> Hi,
>
[quoted text clipped - 21 lines]
>>
>> TIA.
Dominick Baier - 22 Nov 2006 13:44 GMT
Hi,

yes - you can load it by hand - but i wouldn't really recommend that because
it kind of hacky

do this from the cmdline:

runas /u:youruser /profile cmd.exe

then you have to enter the pwd etc...the profile is loaded as long as the
cmd.exe is living....

don't quote me on that ;)

dominick

> Is there a way to have a profile loaded by hand ?
> I already know that in IIS7, profiles could be loaded. This is nice.
[quoted text clipped - 26 lines]
>>>
>>> TIA.
Joe Kaplan - 22 Nov 2006 15:15 GMT
Could you also p/invoke into LoadUserProfile to accomplish the same thing?
I haven't tried it...

Joe K.

Signature

Joe Kaplan-MS MVP Directory Services Programming
Co-author of "The .NET Developer's Guide to Directory Services Programming"
http://www.directoryprogramming.net
--

> Hi,
> yes - you can load it by hand - but i wouldn't really recommend that
[quoted text clipped - 41 lines]
>>>>
>>>> TIA.
Olivier Matrot - 22 Nov 2006 15:45 GMT
I just tried it.
This is weird. There is no error on LoadUserProfile, but the environment
remains unchanged...

> Could you also p/invoke into LoadUserProfile to accomplish the same thing?
> I haven't tried it...
[quoted text clipped - 46 lines]
>>>>>
>>>>> TIA.
Dominick Baier - 22 Nov 2006 15:47 GMT
LoadUserProfile requires SYSTEM

bummer :)

-----
Dominick Baier (http://www.leastprivilege.com)

> Could you also p/invoke into LoadUserProfile to accomplish the same
> thing? I haven't tried it...
>
> Joe K.

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.