diff options
| author | omnom62 <omnom62@outlook.com> | 2026-08-11 17:01:58 +1000 |
|---|---|---|
| committer | John Estabrook <jestabro@vyos.io> | 2026-08-26 13:33:34 -0500 |
| commit | c489a19e454a9be5438fc16e26e62407a0d64f49 (patch) | |
| tree | 6f2e5bf50d0ff780ef248cc81ed787f299c2aef8 /src/services/api | |
| parent | 0cdf7e696b4deb3c3103a596bfe4d4f167dcf4b7 (diff) | |
| download | vyos-1x-c489a19e454a9be5438fc16e26e62407a0d64f49.tar.gz vyos-1x-c489a19e454a9be5438fc16e26e62407a0d64f49.zip | |
http-api: T8989: linter fixes
Diffstat (limited to 'src/services/api')
| -rw-r--r-- | src/services/api/rest/routers.py | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/src/services/api/rest/routers.py b/src/services/api/rest/routers.py index 55967f57d..0973ad145 100644 --- a/src/services/api/rest/routers.py +++ b/src/services/api/rest/routers.py @@ -101,7 +101,12 @@ def check_auth(key_list, key): return key_id -def auth_required(data: ApiModel, x_api_key: Optional[str] = Header(None), authorization: Optional[str] = Header(None), x_client_verify: Optional[str] = Header(None)): +def auth_required( + data: ApiModel, + x_api_key: Optional[str] = Header(None), + authorization: Optional[str] = Header(None), + x_client_verify: Optional[str] = Header(None), +): session = SessionState() # mTLS: client certificate verified by nginx against configured CA if x_client_verify == 'SUCCESS': @@ -1032,6 +1037,7 @@ def traceroute_op(data: TracerouteModel): return success(res) + @router.post('/token') def token_op(data: ApiModel): session = SessionState() |
