Solved

Webapplication run as another user

Posted on 2008-10-21
3
476 Views
Last Modified: 2013-11-05
Well.. Hello all over there,

I have written a Web-Application which can read all rights of a folder... Now I need to run this Web-Application on an IIS with special rights... For example by the user "domain\testuser"... So the Website have to run as testuser of the domain...
would it be possible?

pmb µatthias
0
Comment
Question by:counterroot
  • 2
3 Comments
 
LVL 43

Expert Comment

by:TimCottee
ID: 22767160
Hello counterroot,

In your web.config line, locate the  element and change it accordingly:

            

Regards,

TimCottee
0
 
LVL 1

Author Comment

by:counterroot
ID: 22769160
well thx =)
if I would choose the option with the web.config...
what would be the full web.config-file? Because I didn't find it... It should be located in C:\Inetpub\wwwroot\ for example..

I tried to create this file and fill it with your line... but without results... -.-*

Now I could identy the Application-Pool through the inetmgr. so the problem is solved, but...
Would it be possible that you attach some web.config with this line? so I could see it? It would be the more interesting solution ;)
pmb µatthias
0
 
LVL 43

Accepted Solution

by:
TimCottee earned 30 total points
ID: 22769488
Web.config should be located in the root folder of your application, so if you have created the site in IIS and set the location of the application to a specific folder (not necessarily \inetpub\wwwroot) then this is where you would find it. I could post an example but as it would not be appropriate for your application (assemblies will differ etc) it would not be much use.

The advantage of using the web.config method is that if you do not specify a username and password but set impersonate="true" then it will use the credentials of the logged in user on the client to run. This can be useful in intranet environments where you know that a user will be logged into the domain as their permissions will then apply to their session.
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

What is an ISAPI filter?   •      It's an assembly (.dll file) that can add or change the way IIS works.   •      They can be enabled globally for your web server or on a site-by-site basis.   When the IIS server receives a request, enabling the ISAPI fi…
Prologue It is often required to host multiple websites on a single instance of IIS, mostly in development environments instead of on production servers. I am sure it is not much a preferred solution on production servers but this is at least a pos…
Need to grow your business through quality cloud solutions? With everything required to build a cloud platform and solution, you may feel like the distance between you and the cloud is quite long. Help is here. Spend some time learning about the Con…
A company’s greatest vulnerability is their email. CEO fraud, ransomware and spear phishing attacks are the no1 threat to a company’s security. Cybercrime is responsible for the largest loss of money to companies today with losses projected to r…

930 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now