473,796 Members | 2,707 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Database Access and trusted connections

I have a strange problem here. I have my development computer with IIS
installed, and we have a SQL server as well on a windows 2000 server. both
are members of a domain. I have restricted access to my web app using NTFS
ACL's and have disabled anonymous logon and enabled windows authentication.
So when a user logons on to a computer and they use there web browser, they
are not prompted to logon to the intranet web app I am building. All seems
to work except for Database Access. When any user logs onto my development
computer, they have no trouble getting database access (which is located on
another computer), but when they log into any other computer, they do not
have database access. in my code, I specify the connection string to use
trusted connections so it uses there current credentials. When a user is
logged into another computer and views a page that access's the database I
get the error, "NT AUTHORITY\ANONY MOUS LOGON DENIED" however, the user is
logged on, and if I display there logon with this command :
User.Identity.N ame

it definitly shows the user is logged on the web site with there curent
credintials. Am I missing something here in the code? here is my code by the
way( not that the code is the problem because I am not really doing
anything, just trying to connect)

SqlConnection conPubs = new
SqlConnection(" Trusted_connect ion=yes;Server= mysqlserver;Dat abase=mydatabas e");

SqlCommand cmdSql;

SqlDataReader dtrUsers;

cmdSql = new SqlCommand("SEL ECT * FROM Users, conPubs);

conPubs.Open();

dtrUsers = cmdSql.ExecuteR eader();
Nov 19 '05 #1
4 1958
WJ
Make sure that the domain users are also defined in the MS/SQL 2000 User
object and that your users are truly authenticated by your domain (where the
SQL box is a member of).

John
Nov 19 '05 #2
Try what John adviced !
If problem persist post it.


*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!
Nov 19 '05 #3
Yes all perms are set correctly on both the web server and sql server. one
thing I am not to (but pretty sure) is that the user is being authenticated.
I have a label and on the page_load event I set the text of the label to
User.Identity.N ame and it shows the name of the user logged on. So I am
pretty sure that the user is using his credentials and is not being logged
on anonymously (and I have disabled that anywayz. Thanks for your help
"Patrick Olurotimi Ige" <ig*@iprimus.co m.au> wrote in message
news:Op******** ******@TK2MSFTN GP10.phx.gbl...
Try what John adviced !
If problem persist post it.


*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!

Nov 19 '05 #4
WJ

"Shawn H. Mesiatowsky" <smesiatowsky@_ no_spam_perfect fit-ind.com> wrote in
message news:eF******** *****@TK2MSFTNG P10.phx.gbl...
Yes all perms are set correctly on both the web server and sql server. one
...
I specify the connection string to use trusted connections so it uses
there current credentials. When a user is logged into another computer and
views a page that access's the database I get the error, "NT
AUTHORITY\ANONY MOUS LOGON DENIED"


Sounds like your user is not authenticated to your Domain because SQL server
was sent "ANONYMOUS LOGON", not your user logon (per your 1st post).

John
Nov 19 '05 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
2413
by: Mudge | last post by:
Hi, My hosting provider only allows me to use 50 connections to my MySQL database that my Web site will use. I don't know what this 50 connections means exactly. Does this mean that only 50 visitors to my Web site can access my database through my Web site at one time? Or does this mean that in my code I can only use 50 connections? and like
3
3103
by: Maellic | last post by:
Hi, The website I am working on is built with ASP.NET and connects to a SQL Server 2000 database. The web server and database are on the same machine. I have recently tried to modify the timeout of the website from 20 mn to 60 mn. I changed the timeout setting in IIS. Now the website itself doesn't time out, however after 20 mn, when I try to access a page that needs to connect to the database, I get the following error message
6
2745
by: Ober | last post by:
I'm having trouble with my security model, Application_Start, and accessing my database. My ASP.NET app is only going to be running in an intranet environment (not on the public Internet). The production environment will have installed everything locally (i.e., IIS, SQL Server, .NET Framework, etc., all on a Win2k Server).
5
1888
by: Mythran | last post by:
I have a test server and a development machine. I have SQL Server installed on both, the installations are pretty much identical. Both servers are in the same domain. When I run my application locally, I can connect to the local sql server as well as the sql server on the test server. The IIS settings on both the test server and local machine are the same (anon disabled, use integrated windows auth). Identity impersonate is on in...
0
1611
by: Jonathan Wood | last post by:
I seem to be having errors creating and accessing an SQL database. Unfortunatley, I am brand new to SQL setup and administration issues so this really is not my area of expertise. I know I had to install some type of IIS component to run databases from Visual Studio 2003. Since then, I've installed Visual Studio 2005. I know VS 2005 has some component so that IIS is not required. Here's the two errors:
0
2892
by: gpl666666 | last post by:
I use Microsoft Access to create a webpage I publish this webpage to our company server, it gives two messages when I open the webpage, one is: "This website uses a data provider that may be unsafe. If you trust the website, click ok, otherwise click cancel" Another msg is: "This website is using your identity to access a data source. If you trust this website click ok to continue, otherwise click cancel" I have to click OK for both...
5
2182
by: John | last post by:
I have an ASP.NET 2.0 application developed in VB.net, that accesses an Microsoft Access database. When the database is on the same IIS server all works just fine. BUT when it tried to access the same database on a different server I get a permission error. I've created a shared drive on the other server and give it permission with all rights, as well as the Access database. BUT no matter how I set up the connection string in my app, I...
2
1676
by: =?Utf-8?B?R2lkaQ==?= | last post by:
Hi, I've created a ASP.NET application on my pc using visual studio and it works fine. when i moved it to my web server (another pc with IIS) and surf to my website, the website comes up but for some reason doesn't connect to the database. from the visual studio i could connect to the same database as i'm trying now.
9
6283
by: Gordon | last post by:
I want to add a feature to a project I'm working on where i have multiple users set up on my Postgres database with varying levels of access. At the bare minimum there will be a login user who only has read access to the users table so that users can log in. Once a user has been logged in successfully I want to escalate that user's access level to one appropriate to their role, which will include switching the postgres user they are...
0
9685
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
10467
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10021
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
9061
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
6802
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5454
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
1
4130
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
3744
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2931
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.