Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • MortenSkjoldager 2 posts 22 karma points
    Nov 11, 2023 @ 08:30
    MortenSkjoldager
    0

    Member login not working after upgrading from v. 7 to v.8

    Hi all, I am about to complete an upgrade from Umbraco 7 to Umbraco 8 and in the upgrade path on the database, the member logins no longer work. I can see a bunch of options here also on the forum on how to fix them, but none of them have seemed to be working.

    The latest thing that I've tried is making sure the membershipprovider configuration in web.config matches the old site, which it does. I use the following code to validate the member:

    _provider = Membership.Providers["UmbracoMembershipProvider"];
    _provider.ValidateUser(username, password);
    

    Now the passwords are the same (also in the database) between the two versoins, so it is most likely "just" a matter of finding the right algorithm? Or is there anything else I need to do to make it work?

    EDIT: This is the web config properties i carried over from the old v7 site:

    <add name="UmbracoMembershipProvider" type="Umbraco.Web.Security.Providers.MembersMembershipProvider, Umbraco.Web" minRequiredNonalphanumericCharacters="0" minRequiredPasswordLength="6" useLegacyEncoding="false" enablePasswordRetrieval="false" enablePasswordReset="false" requiresQuestionAndAnswer="false" defaultMemberTypeAlias="Member" passwordFormat="Hashed" hashAlgorithmType="HMACSHA256" maxInvalidPasswordAttempts="2147483647" />
    
  • Yakov Lebski 594 posts 2350 karma points
    Nov 12, 2023 @ 17:00
    Yakov Lebski
    0

    I belive it should be related to useLegacyEncoding="false" make ot true to use old encdoing passwords

  • MortenSkjoldager 2 posts 22 karma points
    Nov 12, 2023 @ 20:45
    MortenSkjoldager
    0

    Hello Yakov,

    Thank you so much for your reply :)

    I have tried both setting this to true and false - also in combination with hashingalgorithm (keep it blank, and set the property to what it was in V7).

    Looking at the source code, it appears that there's a comment stating that the hashing algorithm was always Sha1 but I don't know if that applies to the version I was upgrading from (7.2.9).

    I think my next option is to simply pull the entire membership provider into both solutions to figure out where this is wrong, unless there's other things I should try frist.

  • This forum is in read-only mode while we transition to the new forum.

    You can continue this topic on the new forum by tapping the "Continue discussion" link below.

Please Sign in or register to post replies