Asp.net membership providers and iisexpress

Discussion of open issues, suggestions and bugs regarding ADO.NET provider for MySQL
Post Reply
KW
Posts: 135
Joined: Tue 19 Feb 2008 19:12

Asp.net membership providers and iisexpress

Post by KW » Mon 06 Jan 2014 23:02

I am trying to get my dev machine to accept Forms authentication using IISExpress, I get the following errors if Forms authentication is on:

Code: Select all

Object reference not set to an instance of an object. 
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.NullReferenceException: Object reference not set to an instance of an object.

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: 


[NullReferenceException: Object reference not set to an instance of an object.]
   System.Web.Security.CookielessHelperClass.UseCookieless(HttpContext context, Boolean doRedirect, HttpCookieMode cookieMode) +67
   System.Web.Security.FormsAuthenticationModule.ExtractTicketFromCookie(HttpContext context, String name, Boolean& cookielessTicket) +1786
   System.Web.Security.FormsAuthenticationModule.OnAuthenticate(FormsAuthenticationEventArgs e) +107
   System.Web.Security.FormsAuthenticationModule.OnEnter(Object source, EventArgs eventArgs) +80
   System.Web.SyncEventExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() +136
   System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) +69
 


--------------------------------------------------------------------------------
Version Information: Microsoft .NET Framework Version:4.0.30319; ASP.NET Version:4.0.30319.33440 

Here is the web.config for providers:

Code: Select all

 <authentication mode="Forms">
      <forms  ticketCompatibilityMode="Framework20"   name=".MeridianBugTracker_ASPXAUTH" requireSSL="true" timeout="10000" />
      
    </authentication>
    <membership hashAlgorithmType="SHA1" defaultProvider="AspNetMySqlMembershipProvider" userIsOnlineTimeWindow="15">
      <providers>
        <remove name="AspNetMySqlMembershipProvider" />
        <add name="AspNetMySqlMembershipProvider" type="Devart.Data.MySql.Web.Providers.MySqlMembershipProvider,Devart.Data.MySql.Web, Version=8.1.45.4, Culture=neutral,PublicKeyToken=09af7300eec23701" connectionStringName="MySqlServices" enablePasswordRetrieval="false" enablePasswordReset="true" requiresQuestionAndAnswer="false" requiresUniqueEmail="true" passwordFormat="Hashed" maxInvalidPasswordAttempts="5" minRequiredPasswordLength="7" minRequiredNonalphanumericCharacters="0" applicationName="/ReservationSystem" passwordAttemptWindow="10" />
      </providers>
    </membership>
    <roleManager defaultProvider="AspNetMySqlRoleProvider" createPersistentCookie="true" enabled="true" cacheRolesInCookie="true" cookieName=".ASPROLES" cookieSlidingExpiration="false" cookieTimeout="10000" cookiePath="/" cookieProtection="All">
      <providers>
        <remove name="AspNetMySqlRoleProvider" />
        <add name="AspNetMySqlRoleProvider" type="Devart.Data.MySql.Web.Providers.MySqlRoleProvider, Devart.Data.MySql.Web, Version=8.1.45.4, Culture=neutral, PublicKeyToken=09af7300eec23701" applicationName="/ReservationSystem" connectionStringName="MySqlServices" />
      </providers>
    </roleManager>
    <profile defaultProvider="AspNetMySqlProfileProvider" enabled="true">
      <providers>
        <remove name="AspNetMySqlProfileProvider" />
        <add name="AspNetMySqlProfileProvider" type="Devart.Data.MySql.Web.Providers.MySqlProfileProvider,Devart.Data.MySql.Web, Version=8.1.45.4, Culture=neutral, PublicKeyToken=09af7300eec23701"     applicationName="/ReservationSystem" connectionStringName="MySqlServices" />
      </providers>
      <properties>
        <add name="FriendlyName" />
      </properties>
    </profile>

Do you have any idea what is causing the issue? I've tried to debug it, but I cannot step into anything.

Shalex
Site Admin
Posts: 9543
Joined: Thu 14 Aug 2008 12:44

Re: Asp.net membership providers and iisexpress

Post by Shalex » Tue 07 Jan 2014 15:33

We think that the problem is not related to dotConnect for MySQL because there are no Devart.* classes in the stack trace.

If the same application works with a standard provider (e.g.: System.Data.SqlClient) but fails with dotConnect for MySQL, please send us your small test project so that we can reproduce the issue in our environment.

Post Reply