Skip to content

Deny status 401 #11

@lastlegion

Description

@lastlegion

How to return 401s to the client on auth failure.

frontend http
	# *snip*
	
	http-request deny if ! { var(txn.auth_response_successful) -m bool }

will return 403.

we can use

frontend http
	# *snip*
	
	http-request auth if ! { var(txn.auth_response_successful) -m bool }

But it'll return 401 with basic auth instead of bearer token. Do you have any workaround for this?

Metadata

Metadata

Assignees

No one assigned

    Labels

    questionFurther information is requested

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions