We help IT Professionals succeed at work.

We've partnered with Certified Experts, Carl Webster and Richard Faulkner, to bring you two Citrix podcasts. Learn about 2020 trends and get answers to your biggest Citrix questions!Listen Now

x

Authentication Problems NT AUTHORITY\NETWORK SERVICE

tradeline
tradeline asked
on
Medium Priority
922 Views
Last Modified: 2008-03-10
I''m trying to get my asp.net/sql server2005 app running under IIS 6.  The DB connection is working fine in visual studio environment, but when I try and access the DB through localhost, it crashes, saying that NT AUTHORITY\NETWORK SERVICE is not a valid login.

I grant access to the NT Authority user using the following code:

exec sp_grantlogin N'NT AUTHORITY\NETWORK SERVICE'
go

exec sp_grantdbaccess N'NT AUTHORITY\NETWORK SERVICE'
go

and then the login error stops.  BUT, now it throws an error saying that the stored procedure 'x' doesn't exist.  The sproc clearly exists, and I've confirmed that it's still attempting to access the correct DB.  Do I also have to grant access to the SPROCS?

Any insight is appreciated.

Scott.

Comment
Watch Question

Commented:
if you grant access to a user you have to then give it priviledges within SQLServer

Give the SQL user execute permissions on the stored procedure and see if it can then find sproc 'x'

Not the solution you were looking for? Getting a personalized solution is easy.

Ask the Experts
Hi,

even if this should solve your problem, it is absolutely dangerous.
Anyone that connects to your localhost from a remote machine will be able to execute your pages and gains access to the database.
Better would be to impersonate the database connection by reading the user credentials in your ASP.NET code and changing the connection strings
your app uses to SSPI=true.
this way you won't have  a security preach between your network security and SQL Server security

HTH

Andy
Access more of Experts Exchange with a free account
Thanks for using Experts Exchange.

Create a free account to continue.

Limited access with a free account allows you to:

  • View three pieces of content (articles, solutions, posts, and videos)
  • Ask the experts questions (counted toward content limit)
  • Customize your dashboard and profile

*This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

OR

Please enter a first name

Please enter a last name

8+ characters (letters, numbers, and a symbol)

By clicking, you agree to the Terms of Use and Privacy Policy.