Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Email address is case sensitive when editing passwords #287

Closed
ghost opened this issue Dec 18, 2012 · 3 comments
Closed

Email address is case sensitive when editing passwords #287

ghost opened this issue Dec 18, 2012 · 3 comments

Comments

@ghost
Copy link

ghost commented Dec 18, 2012

In

/ catalog / model / account / customer.php

Change:

$this->db->query("UPDATE " . DB_PREFIX . "customer SET salt = '" . $this->db->escape($salt = substr(md5(uniqid(rand(), true)), 0, 9)) . "', password = '" . $this->db->escape(sha1($salt . sha1($salt . sha1($password)))) . "' WHERE email = '" . $this->db->escape($email) . "'");

To:

$this->db->query("UPDATE " . DB_PREFIX . "customer SET salt = '" . $this->db->escape($salt = substr(md5(uniqid(rand(), true)), 0, 9)) . "', password = '" . $this->db->escape(sha1($salt . sha1($salt . sha1($password)))) . "' WHERE LOWER(email) = '" . $this->db->escape(strtolower($email)) . "'");
@opencart
Copy link
Collaborator

i have updated the sql in the latest commit. it will be case insensitive.

@opencart
Copy link
Collaborator

please confirm

@ghost
Copy link
Author

ghost commented Dec 19, 2012

#289

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

0 participants