Home All Groups Group Topic Archive Search About

NTAUTHORITY\NET SERVICE not authorized

Author
5 Jul 2005 1:40 PM
ChuckD_Duncan
(Platform: 2003 or XP, IIS) From a Web Service, I have a sqlConnection with
a correct (tested) connection string.  When I try to
      myConn.Open(); 
it fails with NTAUTHORITY\NET SERVICE not authorized... meaning it seems
to be looking for that in the SQL users list.  However, I can't find such
an account in the system to add to the database security.
   Somehow I have a combination of DejaVu and Alzheimer's .... appreciate
your help.

Thanks in advance.
Chuck Duncan

Author
5 Jul 2005 2:04 PM
ChuckD_Duncan
CORRECTION:
That should be:  NT AUTHORITY\NETWORK SERVICE

Do I just "Create" this in the SQL Logins even though it doesn't exist in
the NT system?
Are all your drivers up to date? click for free checkup

Author
5 Jul 2005 2:33 PM
Miha Markic [MVP C#]
Hi,

This is the default nt account under which your webservice runs.
And you have set windows authentication in your connection string.
Thus webservice tries with its account.
Is Sql server on the same machine?

--
Miha Markic [MVP C#] - RightHand .NET consulting & development
www.rthand.com
Blog: http://cs.rthand.com/blogs/blog_with_righthand/
SLODUG - Slovene Developer Users Group www.codezone-si.info

Show quoteHide quote
"ChuckD_Duncan" <cduncan@nospam.guardianangelcorp.com> wrote in message
news:a95a3864f0fd4b50de1ed73ba5fc5cc4@localhost.talkaboutsoftware.com...
> (Platform: 2003 or XP, IIS) From a Web Service, I have a sqlConnection
> with
> a correct (tested) connection string.  When I try to
>      myConn.Open();
> it fails with NTAUTHORITY\NET SERVICE not authorized... meaning it seems
> to be looking for that in the SQL users list.  However, I can't find such
> an account in the system to add to the database security.
>   Somehow I have a combination of DejaVu and Alzheimer's .... appreciate
> your help.
>
> Thanks in advance.
> Chuck Duncan
>
>
Author
5 Jul 2005 4:55 PM
ChuckD_Duncan
I have tried it with SQL on the same and on different machines... same
problem.  I am surprised that I cannot seem to find that account anywhere
so I can add it to the database.
Author
5 Jul 2005 6:41 PM
Miha Markic [MVP C#]
Did you try adding "NT AUTHORITY\NETWORK SERVICE" (without quotes) user to
sql server? Note that this account doesn't appear in available user list.
Other possibility is to create a new application pool (on the IIS) and
assign it a certain user account (Make sure your web application uses this
new pool). This account will be used for connection to sql server then.

--
Miha Markic [MVP C#] - RightHand .NET consulting & development
www.rthand.com
Blog: http://cs.rthand.com/blogs/blog_with_righthand/
SLODUG - Slovene Developer Users Group www.codezone-si.info

Show quoteHide quote
"ChuckD_Duncan" <cduncan@nospam.guardianangelcorp.com> wrote in message
news:58c9bddc1e9ed7aea1eded25ed8d6f38@localhost.talkaboutsoftware.com...
>I have tried it with SQL on the same and on different machines... same
> problem.  I am surprised that I cannot seem to find that account anywhere
> so I can add it to the database.
>
Author
5 Jul 2005 10:28 PM
ChuckD_Duncan
I did try adding NT AUTHORITY\NETWORK SERVICE which I thought might work
too, but it just said it doesn't exist.  Isn't it a different account on
2003 ?? 
As for the rest of your suggestion, I'm afraid you are way beyond me on
that.  I don't know how to do any of those. 
The problem is that when I try to create a web application or service in
Visual Studio, it tries to do it using the NT AUTHORITY... account so if I
don't get that working, then I am going to be stuck even creating the
project.
Author
5 Jul 2005 10:30 PM
ChuckD_Duncan
BTW, I WAS ABLE to add NT AUTHORITY\NETWORK SERVICE on a XP system just
fine.  So it must be something unique to 2003 ??
Author
5 Jul 2005 10:53 PM
ChuckD_Duncan
The issue is really getting the app or service built in the first place...
without VStudio 2003 throwing up.  You can't modify config files that
don't exist yet... see my problem?
Author
5 Jul 2005 11:06 PM
ChuckD_Duncan
Is it a factor: this is NOT a DC ie it doesnn't have Active Directory???

Bookmark and Share