Wrox Programmer Forums
|
Classic ASP Databases Discuss using ASP 3 to work with data in databases, including ASP Database Setup issues from the old P2P forum on this specific subtopic. See also the book forum Beginning ASP.NET Databases for questions specific to that book. NOT for ASP.NET 1.0, 1.1, or 2.0.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Classic ASP Databases section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old July 30th, 2003, 01:47 PM
Registered User
 
Join Date: Jul 2003
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default Post method and anonymous access

I have an application that I use anonymous access using a domain account with to access a SQL Server. If I use only anonymous access, then I am able to get to the DB just fine. My problem is if I use anonymous access, the post method stops working for my forms on that page. And just the opposite if I use NT authentication instead of anonymous access. Post method works fine, but I cannot access the database. Please help. I've searched all over google with no solutions. Thanks
 
Old July 30th, 2003, 03:12 PM
Registered User
 
Join Date: Jul 2003
Posts: 7
Thanks: 0
Thanked 0 Times in 0 Posts
Default

What it sounds like to me is that when you are using NT Authentication, you are eliminating the default anonymous user. Instead of putting the user information into the connection string, you've made the internet user an admin of your database. I say just make a new user in your db with a good password and define the user name and password in your connection string. For example, you might do this:

Const strServer = "MYSQLDBSERVER01"
Const strDatabaseName = "MyDatabase"
Const strUID = "MyInetUser"
Const strPassword = "Qx56zp"
myConnString = "DRIVER={SQL Server};SERVER=" & strServer &";DATABASE=" & strDatabaseName &";UID=" & strUID &";PWD=" & strPassword &";DSN=;"
Set myConnect = Server.CreateObject("adodb.connection")
myConnect.Open myConnString

That should do it. I've always been able to have my inet user account work well as a database user, but I've only worked with 2k and XP as SQL Server environments.

 
Old July 30th, 2003, 03:23 PM
Registered User
 
Join Date: Jul 2003
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Thanks for the response. Here is the connection string I am using.

strConnectEBPPInfo = "Provider=SQLOLEDB; Data Source = nexus\ebpp; Initial Catalog = EBPPDev; Trusted_Connection=yes"

Our SQL server is setup for NT authentication mode only. If it was setup in mixed mode, then your solution works. Unfortunatly, our security team will not let that happen. So what I did is made a domain account ten added that account to the user list on the DB. Then in order to access that data, I needed to use that account for the anonymous user instead of the IUSR account. Make sense?





Similar Threads
Thread Thread Starter Forum Replies Last Post
Webpart in Anonymous Access site arunduttgp SharePoint Development 0 December 21st, 2007 01:56 AM
post method franta1346 Reporting Services 0 July 22nd, 2007 11:08 PM
Post Method Error spitz Classic ASP Databases 2 June 10th, 2005 04:31 AM
about post and get method csc820203 HTML Code Clinic 1 August 2nd, 2004 01:13 PM
Post Method? zhenwe1 Servlets 0 January 25th, 2004 01:17 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.