Quantcast
Channel: MySQL Forums - Connector/NET and C#, Mono, .Net
Viewing all articles
Browse latest Browse all 1451

Connector .Net 6.3.5 Access denied for user ''@'localhost' (using password: NO) (no replies)

$
0
0
I followed the tutorial here: http://dev.mysql.com/doc/refman/5.1/en/connector-net-tutorials-asp-roles.html#c11548 when setting up my connection. I created two users and roles but when I click the test links in the provider section I get an error that says they could not connect to the database.

If I try to use the actual login form the error message I get says:

An exception occurred communicating with the data source.

Action: GetUsers

Exception: MySql.Data.MySqlClient.MySqlException: Access denied for user ''@'localhost' (using password: NO)
at MySql.Data.MySqlClient.MySqlStream.ReadPacket()
at MySql.Data.MySqlClient.NativeDriver.AuthenticateNew()
at MySql.Data.MySqlClient.NativeDriver.Authenticate()
at MySql.Data.MySqlClient.NativeDriver.Open()
at MySql.Data.MySqlClient.Driver.Open()
at MySql.Data.MySqlClient.Driver.Create(MySqlConnectionStringBuilder settings)
at MySql.Data.MySqlClient.MySqlPool.CreateNewPooledConnection()
at MySql.Data.MySqlClient.MySqlPool.GetPooledConnection()
at MySql.Data.MySqlClient.MySqlPool.TryToGetDriver()
at MySql.Data.MySqlClient.MySqlPool.GetConnection()
at MySql.Data.MySqlClient.MySqlConnection.Open()
at MySql.Web.Security.MySQLMembershipProvider.GetUsers(String username, String email, Int32 pageIndex, Int32 pageSize, Int32& totalRecords)

My Connections string section matches the tutorial spot on and my membership and role providers look like this:

<membership defaultProvider="MySqlMembershipProvider">
<providers>
<clear/>
<remove name="MySqlMembershipProvider" />
<add name="MySqlMembershipProvider"
type="MySql.Web.Security.MySQLMembershipProvider, MySql.Web"
connectionStringName="LocalMySqlServer"
enablePasswordRetrieval="false"
enablePasswordReset="true"
requiresQuestionAndAnswer="false"
requiresUniqueEmail="true"
passwordFormat="Hashed"
maxInvalidPasswordAttempts="5"
minRequiredPasswordLength="8"
minRequiredNonalphanumericCharacters="1"
passwordAttemptWindow="10"
applicationName="/"
autogenerateschema="true" />
</providers>
</membership>

<roleManager enabled="true" defaultProvider="MySqlRoleProvider">
<providers>
<clear />
<remove name="MySqlRoleProvider" />
<add connectionStringName="LocalMySqlServer"
applicationName="/"
name="MySqlRoleProvider"
type="MySql.Web.Security.MySQLRoleProvider, MySql.Web"
autogenerateschema="true"/>
</providers>
</roleManager>

Any idea what could be causing the error?

Viewing all articles
Browse latest Browse all 1451

Trending Articles