troubleshooting Question

Using COMAdmin to create a COM+ application running under an identity of "Network Service"

Avatar of lambch0p
lambch0pFlag for Afghanistan asked on
.NET ProgrammingSystem Programming
2 Comments1 Solution1948 ViewsLast Modified:

I'm trying to create a COM+ application using the COMAdmin object.

I'm having problems with the identity property.  If I use a domain username and password it works fine.  However, some of our components run under the "Network Service" account.  Does anyone know how to specify this when creating the COM+ application?  I obviously don't have the password for this account,  and would like to know if it's possible to set the identity to "Network Service" (at all), and if it's possible to do without knowing the password.

Here's a code snippet.  

public void CreateCom(comApplication app)
    COMAdmin.COMAdminCatalogObject application;
    application = (COMAdmin.COMAdminCatalogObject)ObjApplications.Add();
    application.set_Value("Identity","Network Service");//How do I specify the network service account?
    application.set_Value("Password", "");
    foreach (comComponent com in app.DllFiles)
        objAdmin.InstallComponent(application.Name.ToString(), com.ComDll, "", "");

Incidentally, this is running on Windows XP SP2 at the moment, although it's intended for use on Server 2003.

These are values I have tried, without success:
application.set_Value("Identity","NT Authority\\Network service");
application.set_Value("Identity","NT Authority\\Networkservice");
application.set_Value("Identity","Network service");
application.set_Value("Identity",@"NT Authority\Network service");//Just in case
I have tried each of them with:
application.set_Value("Password", "");//blank password
application.set_Value("Password", "asdfasd");//a random, made-up password
//application.set_Value("Password", "");//No password property\value specified at all
Each of them results in an unhandled COMException

The identity or password set on the application is not valid (Exception from HRESULT: 0x80110414)


Join the community to see this answer!
Join our exclusive community to see this answer & millions of others.
Unlock 1 Answer and 2 Comments.
Join the Community
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 1 Answer and 2 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros