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

Fixup missing support for set_response_status within plain error_handler #257

Merged
merged 5 commits into from
Jun 22, 2021

Conversation

malud
Copy link
Collaborator

@malud malud commented Jun 22, 2021

Previously a response block was required, now an existing AC error gets just the new status-code:

definitions {
  basic_auth "ba" {
    user = "hans"
    password = "peter"
    error_handler {
      set_response_status = 418
    }
  }
}

While accessing related endpoints without credentials this configuration will still throw a access control error: credentials required but changes the status-code from 401 to 418.

First implementation in #250

Marcel Ludwig and others added 4 commits June 22, 2021 10:15
handler/endpoint.go Outdated Show resolved Hide resolved
@alex-schneider alex-schneider merged commit 4f509b2 into master Jun 22, 2021
@alex-schneider alex-schneider deleted the fixup-set-resp-status branch June 22, 2021 13:33
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.

2 participants