Hi all,
I've been debating for a while (basically since asp.net 2.0 came out) on
using the built in mebership classes to handle user management in my web
apps. I seem to keep coming upon roadblocks that keep me from jumping in.
Well this time is no different. While trying to use an asp.net
sqlmembershipprovider to create a new user, I get the following error:
Server Error in '/' Application.
--------------------------------------------------------------------------------
Login failed for user 'DOMAIN\MACHINENAME$'.
Description: An unhandled exception occurred during the execution of the
current web request. Please review the stack trace for more information
about the error and where it originated in the code.
Exception Details: System.Data.SqlClient.SqlException: Login failed for user
'DOMAIN\MACHINENAME$'.
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 'DOMAIN\MACHINENAME$'.]
System.Data.SqlClient.SqlInternalConnection.OnErro r(SqlException
exception, Boolean breakConnection) +739123
System.Data.SqlClient.TdsParser.ThrowExceptionAndW arning(TdsParserStateObject
stateObj) +188
System.Data.SqlClient.TdsParser.Run(RunBehavior runBehavior, SqlCommand
cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet
bulkCopyHandler, TdsParserStateObject stateObj) +1956
System.Data.SqlClient.SqlInternalConnectionTds.Com pleteLogin(Boolean
enlistOK) +33
System.Data.SqlClient.SqlInternalConnectionTds.Att emptOneLogin(ServerInfo
serverInfo, String newPassword, Boolean ignoreSniOpenTimeout, Int64
timerExpire, SqlConnection owningObject) +170
System.Data.SqlClient.SqlInternalConnectionTds.Log inNoFailover(String
host, String newPassword, Boolean redirectedUserInstance, SqlConnection
owningObject, SqlConnectionString connectionOptions, Int64 timerStart) +349
System.Data.SqlClient.SqlInternalConnectionTds.Ope nLoginEnlist(SqlConnection
owningObject, SqlConnectionString connectionOptions, String newPassword,
Boolean redirectedUserInstance) +181
System.Data.SqlClient.SqlInternalConnectionTds..ct or(DbConnectionPoolIdentity
identity, SqlConnectionString connectionOptions, Object providerInfo, String
newPassword, SqlConnection owningObject, Boolean redirectedUserInstance)
+170
System.Data.SqlClient.SqlConnectionFactory.CreateC onnection(DbConnectionOptions
options, Object poolGroupProviderInfo, DbConnectionPool pool, DbConnection
owningConnection) +359
System.Data.ProviderBase.DbConnectionFactory.Creat ePooledConnection(DbConnection
owningConnection, DbConnectionPool pool, DbConnectionOptions options) +28
System.Data.ProviderBase.DbConnectionPool.CreateOb ject(DbConnection
owningObject) +424
System.Data.ProviderBase.DbConnectionPool.UserCrea teRequest(DbConnection
owningObject) +66
System.Data.ProviderBase.DbConnectionPool.GetConne ction(DbConnection
owningObject) +496
System.Data.ProviderBase.DbConnectionFactory.GetCo nnection(DbConnection
owningConnection) +82
System.Data.ProviderBase.DbConnectionClosed.OpenCo nnection(DbConnection
outerConnection, DbConnectionFactory connectionFactory) +105
System.Data.SqlClient.SqlConnection.Open() +111
System.Web.DataAccess.SqlConnectionHolder.Open(Htt pContext context,
Boolean revertImpersonate) +84
System.Web.DataAccess.SqlConnectionHelper.GetConne ction(String
connectionString, Boolean revertImpersonation) +197
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)
+1121
System.Web.Security.SqlMembershipProvider.CheckPas sword(String username,
String password, Boolean updateLastLoginActivityDate, Boolean
failIfNotApproved, String& salt, Int32& passwordFormat) +105
System.Web.Security.SqlMembershipProvider.CheckPas sword(String username,
String password, Boolean updateLastLoginActivityDate, Boolean
failIfNotApproved) +42
System.Web.Security.SqlMembershipProvider.Validate User(String username,
String password) +83
System.Web.UI.WebControls.Login.OnAuthenticate(Aut henticateEventArgs e)
+160
System.Web.UI.WebControls.Login.AttemptLogin() +105
System.Web.UI.WebControls.Login.OnBubbleEvent(Obje ct source, EventArgs e)
+99
System.Web.UI.Control.RaiseBubbleEvent(Object source, EventArgs args) +35
System.Web.UI.WebControls.Button.OnCommand(Command EventArgs e) +115
System.Web.UI.WebControls.Button.RaisePostBackEven t(String eventArgument)
+163
System.Web.UI.WebControls.Button.System.Web.UI.IPo stBackEventHandler.RaisePostBackEvent(String
eventArgument) +7
System.Web.UI.Page.RaisePostBackEvent(IPostBackEve ntHandler
sourceControl, String eventArgument) +11
System.Web.UI.Page.RaisePostBackEvent(NameValueCol lection postData) +33
System.Web.UI.Page.ProcessRequestMain(Boolean
includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +5102
--------------------------------------------------------------------------------
Version Information: Microsoft .NET Framework Version:2.0.50727.832; ASP.NET
Version:2.0.50727.832
Here's my configuration situation. I'm running .net 2.0 and sql server
2005. I'm using integrated security in my connection string similar to
"Data Source=SERVER;Initial Catalog=DATABASE;Trusted_Connection=True;". The
applicaiton in IIS is running as a network level user that has db_owner
access to the database in the connection string. The user is impersonated
in the web.config using "<identity impersonate="true"/>". The rest of the
database access on the site works fine using the same connection string. I
only get the error above when trying to do the membership functionality. It
almost looks like when I use the classes that it drops the annonymous user
and goes back to using a machine level account.
Any help would be greatly appreciated.
Thanks,
Matt 1 2786
Anyone have any thoughts on this?
"Matt MacDonald" <ma******@hotmail.comwrote in message
news:%2***************@TK2MSFTNGP06.phx.gbl...
Hi all,
I've been debating for a while (basically since asp.net 2.0 came out) on
using the built in mebership classes to handle user management in my web
apps. I seem to keep coming upon roadblocks that keep me from jumping in.
Well this time is no different. While trying to use an asp.net
sqlmembershipprovider to create a new user, I get the following error:
Server Error in '/' Application.
--------------------------------------------------------------------------------
Login failed for user 'DOMAIN\MACHINENAME$'.
Description: An unhandled exception occurred during the execution of the
current web request. Please review the stack trace for more information
about the error and where it originated in the code.
Exception Details: System.Data.SqlClient.SqlException: Login failed for
user 'DOMAIN\MACHINENAME$'.
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 'DOMAIN\MACHINENAME$'.]
System.Data.SqlClient.SqlInternalConnection.OnErro r(SqlException
exception, Boolean breakConnection) +739123
System.Data.SqlClient.TdsParser.ThrowExceptionAndW arning(TdsParserStateObject
stateObj) +188
System.Data.SqlClient.TdsParser.Run(RunBehavior runBehavior, SqlCommand
cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet
bulkCopyHandler, TdsParserStateObject stateObj) +1956
System.Data.SqlClient.SqlInternalConnectionTds.Com pleteLogin(Boolean
enlistOK) +33
System.Data.SqlClient.SqlInternalConnectionTds.Att emptOneLogin(ServerInfo
serverInfo, String newPassword, Boolean ignoreSniOpenTimeout, Int64
timerExpire, SqlConnection owningObject) +170
System.Data.SqlClient.SqlInternalConnectionTds.Log inNoFailover(String
host, String newPassword, Boolean redirectedUserInstance, SqlConnection
owningObject, SqlConnectionString connectionOptions, Int64 timerStart)
+349
System.Data.SqlClient.SqlInternalConnectionTds.Ope nLoginEnlist(SqlConnection
owningObject, SqlConnectionString connectionOptions, String newPassword,
Boolean redirectedUserInstance) +181
System.Data.SqlClient.SqlInternalConnectionTds..ct or(DbConnectionPoolIdentity
identity, SqlConnectionString connectionOptions, Object providerInfo,
String newPassword, SqlConnection owningObject, Boolean
redirectedUserInstance) +170
System.Data.SqlClient.SqlConnectionFactory.CreateC onnection(DbConnectionOptions
options, Object poolGroupProviderInfo, DbConnectionPool pool, DbConnection
owningConnection) +359
System.Data.ProviderBase.DbConnectionFactory.Creat ePooledConnection(DbConnection
owningConnection, DbConnectionPool pool, DbConnectionOptions options) +28
System.Data.ProviderBase.DbConnectionPool.CreateOb ject(DbConnection
owningObject) +424
System.Data.ProviderBase.DbConnectionPool.UserCrea teRequest(DbConnection
owningObject) +66
System.Data.ProviderBase.DbConnectionPool.GetConne ction(DbConnection
owningObject) +496
System.Data.ProviderBase.DbConnectionFactory.GetCo nnection(DbConnection
owningConnection) +82
System.Data.ProviderBase.DbConnectionClosed.OpenCo nnection(DbConnection
outerConnection, DbConnectionFactory connectionFactory) +105
System.Data.SqlClient.SqlConnection.Open() +111
System.Web.DataAccess.SqlConnectionHolder.Open(Htt pContext context,
Boolean revertImpersonate) +84
System.Web.DataAccess.SqlConnectionHelper.GetConne ction(String
connectionString, Boolean revertImpersonation) +197
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)
+1121
System.Web.Security.SqlMembershipProvider.CheckPas sword(String username,
String password, Boolean updateLastLoginActivityDate, Boolean
failIfNotApproved, String& salt, Int32& passwordFormat) +105
System.Web.Security.SqlMembershipProvider.CheckPas sword(String username,
String password, Boolean updateLastLoginActivityDate, Boolean
failIfNotApproved) +42
System.Web.Security.SqlMembershipProvider.Validate User(String username,
String password) +83
System.Web.UI.WebControls.Login.OnAuthenticate(Aut henticateEventArgs e)
+160
System.Web.UI.WebControls.Login.AttemptLogin() +105
System.Web.UI.WebControls.Login.OnBubbleEvent(Obje ct source, EventArgs
e) +99
System.Web.UI.Control.RaiseBubbleEvent(Object source, EventArgs args)
+35
System.Web.UI.WebControls.Button.OnCommand(Command EventArgs e) +115
System.Web.UI.WebControls.Button.RaisePostBackEven t(String
eventArgument) +163
System.Web.UI.WebControls.Button.System.Web.UI.IPo stBackEventHandler.RaisePostBackEvent(String
eventArgument) +7
System.Web.UI.Page.RaisePostBackEvent(IPostBackEve ntHandler
sourceControl, String eventArgument) +11
System.Web.UI.Page.RaisePostBackEvent(NameValueCol lection postData) +33
System.Web.UI.Page.ProcessRequestMain(Boolean
includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +5102
--------------------------------------------------------------------------------
Version Information: Microsoft .NET Framework Version:2.0.50727.832;
ASP.NET Version:2.0.50727.832
Here's my configuration situation. I'm running .net 2.0 and sql server
2005. I'm using integrated security in my connection string similar to
"Data Source=SERVER;Initial Catalog=DATABASE;Trusted_Connection=True;".
The applicaiton in IIS is running as a network level user that has
db_owner access to the database in the connection string. The user is
impersonated in the web.config using "<identity impersonate="true"/>".
The rest of the database access on the site works fine using the same
connection string. I only get the error above when trying to do the
membership functionality. It almost looks like when I use the classes
that it drops the annonymous user and goes back to using a machine level
account.
Any help would be greatly appreciated.
Thanks,
Matt This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics
by: Tilted |
last post by:
Hi
I have an application which has been deployed and worked fine on all
previous workstations, it is c# based and uses Crystal connecting directly
to MSDE using stored procedures and the...
|
by: Srinivasa Reddy K Ganji |
last post by:
Hi
I have come across this type of code at many places.
New SqlConnection("Data Source=(local);Initial Catalog=XYZ;Integrated
Security=SSPI;")
I assume that the database connection details...
|
by: Ravikanth[MVP] |
last post by:
Hi
It is possible that IIS and SQL Server can reside on
Seperate Machines and you can use Integrated Windows
Authentication to connect.
Ravikanth
>-----Original Message-----
|
by: Andrew |
last post by:
Hey all,
I would like to preface my question by stating I am still learning ASP.net
and while I am confident in the basics and foundation, the more advanced
stuff is still a challenge. Ok....
|
by: cdlipfert |
last post by:
Our intranet is running under windows integrated security. We have
domain users that want to access our intranet site via ssl vpn. SSL
VPN can not authenticate against services that run under...
|
by: Bob |
last post by:
I would like to use integrated security for DB connection for my ASP.NET
applications. Since these apps have different databases (SQL Server), I
want each app to be able to access its own...
|
by: Henry |
last post by:
I am writing a Windows forms VB.Net/MS SQL application via VS 2003 that
utilizes Crystal Reports. I want to be able to dynamically set the
report data source at run time.
I'm trying to change...
|
by: et |
last post by:
I created a web site using integrated security, and now I want it taken off.
I have taken it off of everything in IIS, I have even re-created the
project, brand new, nothing is in the project but...
|
by: daz_oldham |
last post by:
Hi All
Bit of an odd one - very basically I created an app using the
SqlMembershipProvider in VS.NET 2005, and I did it on a MS SQL 2005
server.
However, I then find out that for other...
|
by: Charles Arthur |
last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
|
by: ryjfgjl |
last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
|
by: nemocccc |
last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
|
by: Sonnysonu |
last post by:
This is the data of csv file
1 2 3
1 2 3
1 2 3
1 2 3
2 3
2 3
3
the lengths should be different i have to store the data by column-wise with in the specific length.
suppose the i have to...
|
by: Hystou |
last post by:
There are some requirements for setting up RAID:
1. The motherboard and BIOS support RAID configuration.
2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
|
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,...
|
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
|
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...
| |