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

access: InvenioWebAccessMailCookieError for non existing user email #3309

Closed
bouzlibop opened this issue Jun 25, 2015 · 3 comments · Fixed by #3321
Closed

access: InvenioWebAccessMailCookieError for non existing user email #3309

bouzlibop opened this issue Jun 25, 2015 · 3 comments · Fixed by #3321
Assignees
Milestone

Comments

@bouzlibop
Copy link
Member

Steps to reproduce:

  1. Go to sign in panel
  2. Click Lost your password?
  3. Provide some non existing email
Traceback (most recent call last):
 File "/opt/zenodo/src/invenio/invenio/ext/legacy/__init__.py", line 124, in __call__
   response = self.app.full_dispatch_request()
 File "/opt/zenodo/lib/python2.7/site-packages/flask/app.py", line 1477, in full_dispatch_request
   rv = self.handle_user_exception(e)
 File "/opt/zenodo/lib/python2.7/site-packages/flask_restful/__init__.py", line 270, in error_router
   return original_handler(e)
 File "/opt/zenodo/src/invenio/invenio/base/wrappers.py", line 125, in handle_user_exception
   return super(Flask, self).handle_user_exception(e)
 File "/opt/zenodo/lib/python2.7/site-packages/flask/app.py", line 1<*****>81, in handle_user_exception
   reraise(exc_type, exc_value, tb)
 File "/opt/zenodo/lib/python2.7/site-packages/flask/app.py", line 1475, in full_dispatch_request
   rv = self.dispatch_request()
 File "/opt/zenodo/lib/python2.7/site-packages/flask/app.py", line 1461, in dispatch_request
   return self.view_functions[rule.endpoint](**req.view_args)
 File "/opt/zenodo/src/invenio/invenio/modules/accounts/views/accounts.py", line <*****>05, in lost
   if reset_password(request.values['email'], g.ln):
 File "/opt/zenodo/src/invenio/invenio/ext/login/__init__.py", line 56, in reset_password
   days=CFG_WEBSESSION_RESET_PASSWORD_EXPIRE_IN_DAYS))
 File "/opt/zenodo/src/invenio/invenio/modules/access/mailcookie.py", line 71, in mail_cookie_create_pw_reset
   "Email '%s' doesn't exist" % email)
InvenioWebAccessMailCookieError: Email '[email protected]' doesn't exist

The problem is in this line: https://github.com/inveniosoftware/invenio/blob/master/invenio/modules/access/mailcookie.py#L68

@bouzlibop
Copy link
Member Author

Shall we notify user that provided email doesn't exist or shall we return some generic error page?

@jirikuncar jirikuncar modified the milestones: v2.0.5, v2.1.1 Jun 25, 2015
@jirikuncar
Copy link
Member

I would go for generic error page for InvenioWebAccessMailCookieError exception ("Provided URL is not valid.").

@jirikuncar
Copy link
Member

This problem is applicable on maint-2.0 too, hence I'm changing back the milestone.

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

Successfully merging a pull request may close this issue.

2 participants