Skip to content

Do not ignore 401 #62

Answered by TimWolla
schklom asked this question in Q&A
Discussion options

You must be logged in to vote

whether you think this should be handled in the haproxy configuration

This likely needs to be handled in your HAProxy config. You should be able to either:

  1. Direct the request to a different (authentication) backend when encountering the 401:
use_backend my_auth_service if ! { var(txn.auth_response_successful) -m bool } { var(txn.auth_response_code) eq 401 }

or something similar.

  1. Leverage lua.auth-intercept to return the response to the client (see README.md, this was contributed via a PR and is not something I use myself).

Replies: 4 comments

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Answer selected by TimWolla
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants
Converted from issue

This discussion was converted from issue #61 on June 30, 2023 11:39.