SQL Server Authentication no longer working

  • I'm developing a piece of software that uses SQL Server Authentication instead of Windows Authentication.

    I'm using SQL Server 2016, ASP.NET and C# (with StrataFrame as a development framework)

    The connection resides in the GLOBAL.ASAX file and looks like this:

    DataLayer.DataSources.Add(new SqlDataSourceItem("", @"Server=SEP-JT;Database=Crucible;User Id=crucible;Password=Tv$8g*kdLpMs=[97")); (password changed to protect the innocent ;-))

    I know that this connection string is correct as it was working just fine until a couple of days ago.

    Here is the website ... the stack trace can be seen there ... http://www.crucibleweb.com

    What can make a perfectly functioning connection environment all of a sudden just up and stop working?

    Thanks,

    C. T. Blankenship
    http://www.novantconsulting.com
    ctblankenship@gmail.com

  • Did someone change the server to Windows Authentication?
    EXEC master.sys.xp_loginconfig 'login mode'

  • No, on the Server Properties - Security page the Server Authentication is set to "SQL Server and Windows Authentication".  That was the first thing I checked.  Sorry, I should have stated that initially.

    The result of your query is 'Mixed".

    Thanks,
    CT

  • ctblankenship - Tuesday, September 25, 2018 10:43 AM

    I'm developing a piece of software that uses SQL Server Authentication instead of Windows Authentication.

    I'm using SQL Server 2016, ASP.NET and C# (with StrataFrame as a development framework)

    The connection resides in the GLOBAL.ASAX file and looks like this:

    DataLayer.DataSources.Add(new SqlDataSourceItem("", @"Server=SEP-JT;Database=Crucible;User Id=crucible;Password=Tv$8g*kdLpMs=[97")); (password changed to protect the innocent ;-))

    I know that this connection string is correct as it was working just fine until a couple of days ago.

    Here is the website ... the stack trace can be seen there ... http://www.crucibleweb.com

    What can make a perfectly functioning connection environment all of a sudden just up and stop working?

    Thanks,

    C. T. Blankenship
    http://www.novantconsulting.com
    ctblankenship@gmail.com

    Not going to go the site to look at the file and I am sure that there are others that won't as well.  What is the error message you are getting?

  • Not going to visit the site?  I guess that makes sense ... in any event, the following is the stack trace for the error.

    Thanks,
    CT

    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 'crucible'.

    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 'crucible'.] 
    System.Data.SqlClient.SqlInternalConnectionTds..ctor(DbConnectionPoolIdentity identity, SqlConnectionString connectionOptions, SqlCredential credential, Object providerInfo, String newPassword, SecureString newSecurePassword, Boolean redirectedUserInstance, SqlConnectionString userConnectionOptions, SessionData reconnectSessionData, DbConnectionPool pool, String accessToken, Boolean applyTransientFaultHandling) +1385 
    System.Data.SqlClient.SqlConnectionFactory.CreateConnection(DbConnectionOptions options, DbConnectionPoolKey poolKey, Object poolGroupProviderInfo, DbConnectionPool pool, DbConnection owningConnection, DbConnectionOptions userOptions) +1091 
    System.Data.ProviderBase.DbConnectionFactory.CreatePooledConnection(DbConnectionPool pool, DbConnection owningObject, DbConnectionOptions options, DbConnectionPoolKey poolKey, DbConnectionOptions userOptions) +70 
    System.Data.ProviderBase.DbConnectionPool.CreateObject(DbConnection owningObject, DbConnectionOptions userOptions, DbConnectionInternal oldConnection) +981 System.Data.ProviderBase.DbConnectionPool.UserCreateRequest(DbConnection owningObject, DbConnectionOptions userOptions, DbConnectionInternal oldConnection) +114 
    System.Data.ProviderBase.DbConnectionPool.TryGetConnection(DbConnection owningObject, UInt32 waitForMultipleObjectsTimeout, Boolean allowCreate, Boolean onlyOneCheckConnection, DbConnectionOptions userOptions, DbConnectionInternal& connection) +1590 
    System.Data.ProviderBase.DbConnectionPool.TryGetConnection(DbConnection owningObject, TaskCompletionSource`1 retry, DbConnectionOptions userOptions, DbConnectionInternal& connection) +156 System.Data.ProviderBase.DbConnectionFactory.TryGetConnection(DbConnection owningConnection, TaskCompletionSource`1 retry, DbConnectionOptions userOptions, DbConnectionInternal oldConnection, DbConnectionInternal& connection) +268 
    System.Data.ProviderBase.DbConnectionInternal.TryOpenConnectionInternal(DbConnection outerConnection, DbConnectionFactory connectionFactory, TaskCompletionSource`1 retry, DbConnectionOptions userOptions) +314 
    System.Data.SqlClient.SqlConnection.TryOpenInner(TaskCompletionSource`1 retry) +204 
    System.Data.SqlClient.SqlConnection.TryOpen(TaskCompletionSource`1 retry) +428 
    System.Data.SqlClient.SqlConnection.Open() +130 System.Data.Common.DbDataAdapter.FillInternal(DataSet dataset, DataTable[] datatables, Int32 startRecord, Int32 maxRecords, String srcTable, IDbCommand command, CommandBehavior behavior) +173 
    System.Data.Common.DbDataAdapter.Fill(DataTable[] dataTables, Int32 startRecord, Int32 maxRecords, IDbCommand command, CommandBehavior behavior) +453 
    System.Data.Common.DbDataAdapter.Fill(DataTable dataTable) +141 
    MicroFour.StrataFrame.Data.DbDataSourceItem.GetDataTable(DbCommand Command, OnChangeEventHandler CallBack) +155 
    MicroFour.StrataFrame.Business.BusinessLayer.FillDataTable(DbCommand CommandToExecute) +43 
    Crucible.Web.Site.BuildMenuItems() +84 Crucible.Web.Site.Page_Load(Object sender, EventArgs e) +43 
    System.Web.UI.Control.OnLoad(EventArgs e) +103 
    System.Web.UI.Control.LoadRecursive() +68 
    System.Web.UI.Control.LoadRecursive() +162 
    System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +3811

  • Did you check the error logs on the server?

  • ctblankenship - Tuesday, September 25, 2018 10:43 AM

    I'm developing a piece of software that uses SQL Server Authentication instead of Windows Authentication.

    I'm using SQL Server 2016, ASP.NET and C# (with StrataFrame as a development framework)

    The connection resides in the GLOBAL.ASAX file and looks like this:

    DataLayer.DataSources.Add(new SqlDataSourceItem("", @"Server=SEP-JT;Database=Crucible;User Id=crucible;Password=Tv$8g*kdLpMs=[97")); (password changed to protect the innocent ;-))

    I know that this connection string is correct as it was working just fine until a couple of days ago.

    Here is the website ... the stack trace can be seen there ... http://www.crucibleweb.com

    What can make a perfectly functioning connection environment all of a sudden just up and stop working?

    Thanks,

    C. T. Blankenship
    http://www.novantconsulting.com
    ctblankenship@gmail.com

    You need to check the SQL Server error log - not the stack trace. The SQL Server error log reports more information and the reason for the failure.

    Sue

  • Thanks for the SQL Server Error Log tip ... it said passwords didn't match.  Come to find out that the " in the password was causing the problem.

    Thanks to everyone for their time and effort.

    CT

Viewing 8 posts - 1 through 7 (of 7 total)

You must be logged in to reply to this topic. Login to reply