Home > Ask the SQL Server Experts > Steven Andres - Security Questions & Answers > Solve SQL Server permissions and authentication problems
Ask The SQL Server Expert: Questions & Answers
EMAIL THIS

Solve SQL Server permissions and authentication problems

Steven  Andres EXPERT RESPONSE FROM: Steven Andres

Pose a Question
Other SQL Server Categories
Meet all SQL Server Experts
Become an Expert for this site


Expert advice on database development
Digg This!    StumbleUpon Toolbar StumbleUpon    Bookmark with Delicious Del.icio.us    Add to Google


>
QUESTION POSED ON: 30 March 2007
For the past two weeks I've been trying to resolve a permissions problem, an authentication problem, or both. I've run out of ideas of where to look. Here is what I have:

  1. SQL Server 2005 on a Member Server (2003)
  2. I'm running Visual Studio .NET 2005 on my work station.
  3. I can access the SQL Server data from within my .NET project.
  4. If I access the website from outside my .NET project, I get Login Failed for user NT_AUTHORITY/NETWORK SERVICE.
    This happens on any PC and even the member server that houses SQL and the Intranet site IIS.
  5. The reason I think I have a permissions problem is because of the behavior of two seperate test projects. Project #1 uses PROFILES to save state. When the program gets to this line of code, the Login Failed message appears. In project #2, I'm not saving state.But when the code attempts to gather data into a dataset, the program halts with the Login Failed message.

Can you give me specific instructions on where to look and what to try?


>
EXPERT RESPONSE
I would try to confirm it is in fact a permisisons issue by going to the IIS settings for the virtual site and deactivating Anonymous access. Enable either Integrated Windows access or Basic auth. Next, go to the website as usual. You will be prompted to login with an HTTP/1.0 old-style login popup. Use any account that you know has read/write permisisons to the directory where the site files are stored.

If everything works fine, then it is definitely an authentication issue. Now, go back to anonymous access and start adding permissions to the IUSR_SERVER account to see if you can get the application to write properly. I would also suggest (if possible) downloading the excellent FileMon tool from SysInternals and see which read/write accesses are being denied. That will help you hunt down the issue.


Digg This!    StumbleUpon Toolbar StumbleUpon    Bookmark with Delicious Del.icio.us    Add to Google


RELATED CONTENT
Steven Andres - Security
Creating a SQL Server user authentication schema
Could a join of encrypted SQL Server data have a problem?
SQL Server connection lost when SA password is changed
How to set SQL Server password for SA login
Creating a login in SQL Server 2000 Enterprise Manager
Code to connect SQL Server 7.0 to Visual Basic 6.0
Set SQL Server password on database in version 7.0
Create username and password for new SQL Server database
Recover password in SQL Server 2000
Protect against SQL Injection by whitelisting

SQL Server security
FAQ: How to troubleshoot and grant SQL Server permissions
Secure SQL Server from SQL injection attacks
How insiders hack SQL databases with free tools and a little luck
Sarbanes-Oxley compliance checklist: IT security and SQL audits
SQL Server source code analysis and management adds database security
Ten common SQL Server security vulnerabilities you may be overlooking
SQL Server 2008 security and compliance features reduce security risks
Get your SQL Server security goals in order
How secure is your SQL Server network design?
Creating a SQL Server user authentication schema

.NET development for SQL Server
FAQ: How to troubleshoot and grant SQL Server permissions
Secure SQL Server from SQL injection attacks
Code to restore SQL Server databases in VB.NET
Custom VB.Net scripting in SQL Server Integration Services
Connect to SQL Server database with Visual Basics
SQL Server Blog Watch
Top 10 SQL Server development questions
Developing CLR database objects: 10 tips, 10 minutes
CLR architecture
Creating CLR database objects
.NET development for SQL Server Research

RELATED GLOSSARY TERMS
Terms from Whatis.com − the technology online dictionary
data corruption  (SearchSQLServer.com)
data hiding  (SearchSQLServer.com)

RELATED RESOURCES
2020software.com, trial software downloads for accounting software, ERP software, CRM software and business software systems
Search Bitpipe.com for the latest white papers and business webcasts
Whatis.com, the online computer dictionary



Search and Browse the Expert Answer Center
Search and browse more than 25,000 question and answer pairs from more than 250 TechTarget industry experts.
Browse our Expert Advice

HomeNewsTopicsITKnowledge ExchangeTipsAsk the ExpertsMultimediaWhite PapersIT Downloads
About Us  |  Contact Us  |  For Advertisers  |  For Business Partners  |  Site Index  |  RSS
SEARCH 
TechTarget provides enterprise IT professionals with the information they need to perform their jobs - from developing strategy, to making cost-effective IT purchase decisions and managing their organizations' IT projects - with its network of technology-specific Web sites, events and magazines.

TechTarget Corporate Web Site  |  Media Kits  |  Reprints  |  Site Map




All Rights Reserved, Copyright 2005 - 2008, TechTarget | Read our Privacy Policy
  TechTarget - The IT Media ROI Experts