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

Error logging: Un-Auth'd Users Can Request Secure Data #549

Open
allthesignals opened this issue Jul 23, 2020 · 0 comments
Open

Error logging: Un-Auth'd Users Can Request Secure Data #549

allthesignals opened this issue Jul 23, 2020 · 0 comments

Comments

@allthesignals
Copy link
Collaborator

Logs:

2020-07-23T21:04:59.648370+00:00 heroku[router]: at=info method=GET path="/projects?email=[hidden]%3E&include=packages.pasForm" host=applicant-portal.herokuapp.com request_id=c5794140-cd0b-47e9-8fda-54fc808821f6 fwd="98.153.164.170" dyno=web.1 connect=0ms service=144ms status=500 bytes=415 protocol=https

2020-07-23T21:04:59.649333+00:00 app[web.1]: �[31m[Nest] 23 - �[39m07/23/2020, 9:04:59 PM �[38;5;3m[ExceptionsHandler] �[39m�[31mCannot destructure property 'contactid' of '(intermediate value)' as it is undefined.�[39m�[38;5;3m +440690ms�[39m

2020-07-23T21:04:59.649427+00:00 app[web.1]: TypeError: Cannot destructure property 'contactid' of '(intermediate value)' as it is undefined.

2020-07-23T21:04:59.649428+00:00 app[web.1]: at ProjectsController.listOfCurrentUserProjects (/app/dist/projects/projects.controller.js:33:27)

2020-07-23T21:04:59.649429+00:00 app[web.1]: at processTicksAndRejections (internal/process/task_queues.js:97:5)

It seems that a user's that's not authenticated can still try to visit projects but see a failure because they're not authenticated.

The error is confusing and should be improved to guard against situations in which a req is made but session is undefined.

@hannahkates hannahkates added this to the Sprint P: 2020 milestone Jul 29, 2020
@hannahkates hannahkates changed the title Un-Auth'd Users Can Request Secure Data Error logging: Un-Auth'd Users Can Request Secure Data Jul 29, 2020
@hannahkates hannahkates removed this from the Sprint P: 2020 milestone Aug 12, 2020
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

2 participants