warpgate
warpgate copied to clipboard
[BUG] API Token missing username in /api/info
Requesting with authorized cookie responds correctly with username filled in
curl 'https://warpgate.example.com/@warpgate/api/info' \
-H 'Accept-Encoding: gzip, deflate, br, zstd' \
-H 'Cookie: warpgate-http-session=example-valid-session'
{
"authorized_via_sso_with_single_logout": true,
"authorized_via_ticket": false,
"external_host": "warpgate.example.com",
"own_credential_management_allowed": true,
"ports": {
"http": 8888,
"mysql": 33306,
"postgres": 55432,
"ssh": 2222
},
"selected_target": null,
"setup_state": null,
"username": "CORRECT_USERNAME",
"version": "v0.16.0-modified"
}
But when requesting with api token, username is missing
curl 'https://warpgate.example.com/@warpgate/api/info' \
-H 'Accept-Encoding: gzip, deflate, br, zstd' \
-H 'X-Warpgate-Token: example-valid-token'
{
"authorized_via_sso_with_single_logout": false,
"authorized_via_ticket": false,
"external_host": "warpgate.example.com",
"own_credential_management_allowed": true,
"ports": {
"http": 8888,
"mysql": 33306,
"postgres": 55432,
"ssh": 2222
},
"selected_target": null,
"setup_state": null,
"username": null,
"version": "v0.16.0-modified"
}
Additional information:
- SSO has been configured according to docs
- this user has been created manually and then linked to SSO email