use caps in api key header name w/ burnettk

This commit is contained in:
jasquat 2024-01-17 11:04:40 -05:00
parent 11d9e32d1f
commit 88f81cd2b3
No known key found for this signature in database
2 changed files with 3 additions and 3 deletions

View File

@ -13,7 +13,7 @@ from spiffworkflow_backend.models.db import db
# this is designed to be used for the "service" column on the user table, which is designed to hold
# information about which authentiation system is used to authenticate this user.
# in this case, we are authenticating based on SpiffWorkflow-Api-key which correlates to a known value in the spiff db.
# in this case, we are authenticating based on SpiffWorkflow-Api-Key which correlates to a known value in the spiff db.
SPIFF_SERVICE_ACCOUNT_AUTH_SERVICE = "spiff_service_account"
SPIFF_SERVICE_ACCOUNT_AUTH_SERVICE_ID_PREFIX = "service_account_"

View File

@ -317,8 +317,8 @@ def _find_token_from_headers(token: str | None) -> dict[str, str | None]:
):
token = request.cookies["access_token"]
if not token and "SpiffWorkflow-Api-key" in request.headers:
api_key = request.headers["SpiffWorkflow-Api-key"]
if not token and "SpiffWorkflow-Api-Key" in request.headers:
api_key = request.headers["SpiffWorkflow-Api-Key"]
token_info = {"token": token, "api_key": api_key}
return token_info