mirror of
https://github.com/go-gost/gost.git
synced 2026-10-08 03:55:45 +00:00
test(e2e): add auth module e2e test suite
Verify HTTP proxy authentication for both inline single-user auth and a named auther with multiple users. Covers valid credentials, wrong password, missing credentials, and any-user-in-auther acceptance.
This commit is contained in:
Vendored
+18
@@ -0,0 +1,18 @@
|
||||
# HTTP proxy authenticated via a named auther holding multiple users. Any
|
||||
# listed user/password pair is accepted; unlisted credentials are rejected.
|
||||
services:
|
||||
- name: proxy
|
||||
addr: ":8080"
|
||||
handler:
|
||||
type: http
|
||||
auther: auther-0
|
||||
listener:
|
||||
type: tcp
|
||||
|
||||
authers:
|
||||
- name: auther-0
|
||||
auths:
|
||||
- username: alice
|
||||
password: secret
|
||||
- username: bob
|
||||
password: hunter2
|
||||
Vendored
+13
@@ -0,0 +1,13 @@
|
||||
# HTTP proxy with inline single-user authentication. Clients must supply the
|
||||
# proxy credentials user/pass; wrong or missing credentials get a 407 and never
|
||||
# reach the echo server.
|
||||
services:
|
||||
- name: proxy
|
||||
addr: ":8080"
|
||||
handler:
|
||||
type: http
|
||||
auth:
|
||||
username: user
|
||||
password: pass
|
||||
listener:
|
||||
type: tcp
|
||||
Reference in New Issue
Block a user