Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Access is denied on sc
Message
De
10/09/2013 08:56:06
 
 
À
Tous
Information générale
Forum:
ASP.NET
Catégorie:
Autre
Titre:
Access is denied on sc
Versions des environnements
Environment:
VB 9.0
OS:
Windows 7
Network:
Windows 2003 Server
Database:
MS SQL Server
Application:
Web
Divers
Thread ID:
01582680
Message ID:
01582680
Vues:
64
On a Web server which is having its home directory on a domain network share drive, I can go on Terminal Server and sc a command to create a service which points to that domain network share drive without any problem. But, when I do it from the Web site, I have an access is denied.

This is the same command. So, the command is ok.

From the ASP.NET application, I am executing the command from the Process class. This is what I use for all other commands I need to execute. However, this is the first time I have to use it under a domain network share drive.

For the Web site, the Security tab is using a domain account for the Anonymous definition. The same domain account is used for the application pool. That account has full access to those drives. The domain account has been added into the IIS_WPG group by going into "Computer Management\Local Users and Groups\Groups\IIS_WPG". The domain account has been added into "Log on as service".

The Web site works ok. However, I cannot execute the command to create a Windows Service by the use of the sc command because I receive "Access is denied".

I am trying to find what access is needed. This is a service that has to be created on the Web server. The only difference is that the account used to run the Web site is a domain account instead of a local account. When this is a local account, it works. So, because this is a domain account, do I have to pass a RunAs username and RunAs password for the Process class? If yes, I already tried that and the IIS will not respond to the hit as the hit will run indefinitely. I tried two local accounts having administrative rights. I also tried with the LoadUserProfile on and off. This is the same thing. As soon as I try to pass credentials to the Process class to execute that command, the hit will never respond.

So, the first question is to know, in such situation, because the Web site is running under a domain account, if I execute a command from the Web site to create a service on the Web server, do I need to pass credentials to the Process class which executes the command? If yes, is that a local or domain account I need to use? And, if yes, do I need to have the LoadUserProfile on or off?

Other than that, what else could be a factor here so I can bypass this security barrier?
Michel Fournier
Level Extreme Inc.
Designer, architect, owner of the Level Extreme Platform
Subscribe to the site at https://www.levelextreme.com/Home/DataEntry?Activator=55&NoStore=303
Subscription benefits https://www.levelextreme.com/Home/ViewPage?Activator=7&ID=52
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform