mirror of
https://github.com/0rangebananaspy/authelia.git
synced 2024-09-14 22:47:21 +07:00
6586402114
Traefik handles auth forwarding but does not manage redirections like Nginx. Therefore, Authelia must redirect the user and Traefik will forward this request. To support both Nginx and Traefik, /api/verify is now configurable with the 'redirect' get parameter. If the verification fails and 'redirect' is not provided the response will be a 401 error as before. If the parameter is provided and set to any URL, the response will be a redirection (302) to this URL.
9 lines
457 B
Gherkin
9 lines
457 B
Gherkin
Feature: Generic tests on Authelia endpoints
|
|
|
|
Scenario: /api/verify replies with error when redirect parameter is not provided
|
|
When I query "https://authelia.example.com:8080/api/verify"
|
|
Then I get error code 401
|
|
|
|
Scenario: /api/verify redirects when redirect parameter is provided
|
|
When I query "https://authelia.example.com:8080/api/verify?redirect=http://login.example.com:8080"
|
|
Then I get redirected to "http://login.example.com:8080" |