Skip to content

🚀 Feature: Re-hash Password on Phone Update #4990

Closed

Description

@stnguyen90

🔖 Feature description

Users can be imported with a different password hash, but they should be re-hashed to the default algorithm. This is done for the update email API call:

->setAttribute('password', $isAnonymousUser ? Auth::passwordHash($password, Auth::DEFAULT_ALGO, Auth::DEFAULT_ALGO_OPTIONS) : $user->getAttribute('password', ''))

but not for the update phone API call.

🎤 Pitch

Update the update phone API call to make sure it's consistent with update email.

👀 Have you spent some time to check if this issue has been raised before?

  • I checked and didn't find similar issue

🏢 Have you read the Code of Conduct?

Activity

  1. added
    product / auth
    on Jan 11, 2023
  2. harshmange44 commented on Jan 12, 2023

    @harshmange44

    @stnguyen90 I'd like to contribute to this feature.

  3. stnguyen90 commented on Jan 12, 2023

    @stnguyen90
    ContributorAuthor

    @harshmange44 assigned! thanks for your interest! 🙏🏼

  4. harsh020 commented on Jan 12, 2023

    @harsh020

    @stnguyen90, I would also be interested in working on this.

    If I understand this correctly, you want the updatePhone api to re-hash the password if the user is anonymous. Am I right?

  5. stnguyen90 commented on Jan 12, 2023

    @stnguyen90
    ContributorAuthor

    @stnguyen90, I would also be interested in working on this.

    @harsh020, thanks! 🙏🏼 However, this has already been assigned to @harshmange44 and it's enough to have 1 person working on this.

    If I understand this correctly, you want the updatePhone api to re-hash the password if the user is anonymous. Am I right?

    Yes, the logic should be the same as the updateEmail API.

  6. harshmange44 commented on Jan 13, 2023

    @harshmange44

    @stnguyen90 I've raised a PR: ##5003

  7. added this to the 1.3.0 milestone on Jan 13, 2023
  8. abhishek818 commented on Mar 23, 2023

    @abhishek818

    @stnguyen90 @Meldiron can i pick up this issue , have a MR --> #5269

  9. removed this from the 1.3.0 milestone on Apr 25, 2023
  10. self-assigned this
    on Apr 25, 2023
  11. stnguyen90 commented on Apr 25, 2023

    @stnguyen90
    ContributorAuthor

    Sorry, looks like we're going to change the behavior a bit.

    1. We don't want to update the password for users without a password
    2. We don't want to verify the password if the user doesn't have a password
  12. added this to the 1.4.0 milestone on May 26, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

product / auth

Type

No type

Projects

No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions