Wrox Programmer Forums
|
BOOK: ASP.NET 2.0 Instant Results ISBN: 978-0-471-74951-6
This is the forum to discuss the Wrox book ASP.NET 2.0 Instant Results by Imar Spaanjaars, Paul Wilton, Shawn Livermore; ISBN: 9780471749516
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: ASP.NET 2.0 Instant Results ISBN: 978-0-471-74951-6 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 June 28th, 2007, 09:39 PM
Registered User
 
Join Date: Jun 2007
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Default Photo login failure

Hi

I'm trying to install the photogallery website with a remote DB server(SQL Server 2k5 DEV ED)

The website works fine, but I can't log on to the admin page.
I can see the Roles via the ASP.Net configuration page. I can create/delete roles also. The domain web account as db_owner access and as full control to the folders.

here is the error. Any help appreciated. Thanks

Exception Details: System.Data.SqlClient.SqlException: Login failed for user 'DUET\WIN2KIIS$'.

Source Error:

An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.

Stack Trace:


[SqlException (0x80131904): Login failed for user 'DUET\WIN2KIIS$'.]
   System.Data.SqlClient.SqlInternalConnection.OnErro r(SqlException exception, Boolean breakConnection) +264
   System.Data.SqlClient.TdsParser.ThrowExceptionAndW arning(TdsParserStateObject stateObj) +244
   System.Data.SqlClient.TdsParser.Run(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj) +2675
   System.Data.SqlClient.SqlInternalConnectionTds.Com pleteLogin(Boolean enlistOK) +53
   System.Data.SqlClient.SqlInternalConnectionTds.Ope nLoginEnlist(SqlConnection owningObject, SqlConnectionString connectionOptions, String newPassword, Boolean redirectedUserInstance) +1274
   System.Data.SqlClient.SqlInternalConnectionTds..ct or(DbConnectionPoolIdentity identity, SqlConnectionString connectionOptions, Object providerInfo, String newPassword, SqlConnection owningObject, Boolean redirectedUserInstance) +385
   System.Data.SqlClient.SqlConnectionFactory.CreateC onnection(DbConnectionOptions options, Object poolGroupProviderInfo, DbConnectionPool pool, DbConnection owningConnection) +808
   System.Data.ProviderBase.DbConnectionFactory.Creat ePooledConnection(DbConnection owningConnection, DbConnectionPool pool, DbConnectionOptions options) +54
   System.Data.ProviderBase.DbConnectionPool.CreateOb ject(DbConnection owningObject) +702
   System.Data.ProviderBase.DbConnectionPool.UserCrea teRequest(DbConnection owningObject) +81
   System.Data.ProviderBase.DbConnectionPool.GetConne ction(DbConnection owningObject) +1835
   System.Data.ProviderBase.DbConnectionFactory.GetCo nnection(DbConnection owningConnection) +110
   System.Data.ProviderBase.DbConnectionClosed.OpenCo nnection(DbConnection outerConnection, DbConnectionFactory connectionFactory) +263
   System.Data.SqlClient.SqlConnection.Open() +272
   System.Web.DataAccess.SqlConnectionHolder.Open(Htt pContext context, Boolean revertImpersonate) +85
   System.Web.DataAccess.SqlConnectionHelper.GetConne ction(String connectionString, Boolean revertImpersonation) +414
   System.Web.Security.SqlMembershipProvider.GetPassw ordWithFormat(String username, Boolean updateLastLoginActivityDate, Int32& status, String& password, Int32& passwordFormat, String& passwordSalt, Int32& failedPasswordAttemptCount, Int32& failedPasswordAnswerAttemptCount, Boolean& isApproved, DateTime& lastLoginDate, DateTime& lastActivityDate) +1542
   System.Web.Security.SqlMembershipProvider.CheckPas sword(String username, String password, Boolean updateLastLoginActivityDate, Boolean failIfNotApproved, String& salt, Int32& passwordFormat) +217
   System.Web.Security.SqlMembershipProvider.CheckPas sword(String username, String password, Boolean updateLastLoginActivityDate, Boolean failIfNotApproved) +65
   System.Web.Security.SqlMembershipProvider.Validate User(String username, String password) +126
   System.Web.UI.WebControls.Login.AuthenticateUsingM embershipProvider(AuthenticateEventArgs e) +75
   System.Web.UI.WebControls.Login.AttemptLogin() +163
   System.Web.UI.WebControls.Login.OnBubbleEvent(Obje ct source, EventArgs e) +130
   System.Web.UI.Control.RaiseBubbleEvent(Object source, EventArgs args) +50
   System.Web.UI.Page.RaisePostBackEvent(IPostBackEve ntHandler sourceControl, String eventArgument) +32
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +3215





 
Old June 29th, 2007, 01:21 AM
Imar's Avatar
Wrox Author
 
Join Date: Jun 2003
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
Default

Hi there,

Is DUET the domain or a machine? In the latter case your web site runs under a different account then you may think. If you look at the roles using the Web Site Administration Tool, the site runs under your account. However, when you run it normally, it doesn't.

You may want to read this:

http://imar.spaanjaars.com/QuickDocId.aspx?quickdoc=395

It explains how to configure SQL Server.

In addition you may want to read this:

http://imar.spaanjaars.com/QuickDocId.aspx?quickdoc=287

which explains how to find out the account used by IIS.

Cheers,

Imar


---------------------------------------
Imar Spaanjaars
http://Imar.Spaanjaars.Com
Everyone is unique, except for me.
Author of ASP.NET 2.0 Instant Results and Beginning Dreamweaver MX / MX 2004
Want to be my colleague? Then check out this post.
 
Old June 29th, 2007, 01:57 AM
Registered User
 
Join Date: Jun 2007
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Duet is the domain and win2kiis is the server. The account that I'm running under is a domain account Duet\webuser which has db_owner access and full control on folders but I still can't log in. I set impersonate = true and anonymous access is enabled.

 
Old June 29th, 2007, 12:33 PM
Imar's Avatar
Wrox Author
 
Join Date: Jun 2003
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
Default

That's odd. If you enabled impersonation and set the IIS web site to run under a specific account, it should be that account that is accessing the database. However, the error message you posted seems to suggest that the account DUET\WIN2KIIS$ is accessing the database.

What do you get when you write out the account name in an ASPX page?

Imar


---------------------------------------
Imar Spaanjaars
http://Imar.Spaanjaars.Com
Everyone is unique, except for me.
Author of ASP.NET 2.0 Instant Results and Beginning Dreamweaver MX / MX 2004
Want to be my colleague? Then check out this post.
 
Old June 29th, 2007, 02:14 PM
Registered User
 
Join Date: Jun 2007
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Default

That fixed it!. I had to stated a account to impersonate!

You're the man Imar!!

Thanks!

-Paul


 
Old June 29th, 2007, 02:25 PM
Imar's Avatar
Wrox Author
 
Join Date: Jun 2003
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
Default

Hi Paul,

You're welcome. Glad it's working.

Imar


---------------------------------------
Imar Spaanjaars
http://Imar.Spaanjaars.Com
Everyone is unique, except for me.
Author of ASP.NET 2.0 Instant Results and Beginning Dreamweaver MX / MX 2004
Want to be my colleague? Then check out this post.





Similar Threads
Thread Thread Starter Forum Replies Last Post
login failure yasminnnnn BOOK: ASP.NET Website Programming Problem-Design-Solution 2 February 27th, 2007 04:16 AM
How to determine login success or failure? kscase VB Databases Basics 1 January 22nd, 2007 02:31 PM
Login failure - Wrox Photo Album devman BOOK: ASP.NET 2.0 Instant Results ISBN: 978-0-471-74951-6 12 September 19th, 2006 10:20 AM
Login Failure Basia BOOK: ASP.NET Website Programming Problem-Design-Solution 6 November 1st, 2005 08:33 PM
Another Login failure Bo.B.B BOOK: Beginning VB.NET Databases 6 July 10th, 2005 04:02 AM





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