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

fix: Don't log error at login/consent cancelation #1914

Merged
merged 4 commits into from
Jun 22, 2020

Conversation

sawadashota
Copy link
Contributor

Related issue

Fixed #1912

Proposed changes

Don't log error at login/consent cancelation

Checklist

  • I have read the contributing guidelines.
  • I have read the security policy.
  • I confirm that this pull request does not address a security
    vulnerability. If this pull request addresses a security. vulnerability, I
    confirm that I got green light (please contact
    security@ory.sh) from the maintainers to push
    the changes.
  • I have added tests that prove my fix is effective or that my feature
    works.
  • I have added or changed the documentation.

Signed-off-by: sawadashota <xiootas@gmail.com>
@sawadashota sawadashota marked this pull request as ready for review June 18, 2020 09:08
@aeneasr
Copy link
Member

aeneasr commented Jun 18, 2020

Nice, that totally makes sense not to log it as an error! However, I would like to use something else here, with the newest ory/x release we have added an AuditLogger (https://github.com/ory/x/blob/master/logrusx/logrus.go#L138) which will be responsible for logging auditable actions (e.g. access denied, access allowed, ...) in the future. It's currently very similar to the existing logger but adds a field audience=audit to the structured log output, which can then be used to filter in your log pipeline. I would prefer to move to that than to ignore the error completely!

Signed-off-by: sawadashota <xiootas@gmail.com>
Signed-off-by: sawadashota <xiootas@gmail.com>
Signed-off-by: sawadashota <xiootas@gmail.com>
@sawadashota
Copy link
Contributor Author

@aeneasr I added audit logger and use for allow/denied access. Could you review again?

@aeneasr
Copy link
Member

aeneasr commented Jun 22, 2020

Awesome, thank you!

@aeneasr aeneasr merged commit 379eed3 into ory:master Jun 22, 2020
@sawadashota sawadashota deleted the fix-1912 branch June 22, 2020 09:50
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

Successfully merging this pull request may close these issues.

Error log at login/consent cancelation
2 participants