Skip to content

Commit

Permalink
Add Logging
Browse files Browse the repository at this point in the history
  • Loading branch information
CannonLock committed Oct 18, 2024
1 parent d3e2a55 commit 5f437d3
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions macrostrat_db_insertion/security/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,9 @@ class OAuth2AuthorizationCodeBearerWithCookie(OAuth2AuthorizationCodeBearer):
async def __call__(self, request: Request) -> Optional[str]:
authorization = request.cookies.get("Authorization") # authorization = request.headers.get("Authorization")
scheme, param = get_authorization_scheme_param(authorization)

logging.debug(f"Authorization: {authorization}")
logging.debug(f"Cookies: {request.cookies}")
if not authorization or scheme.lower() != "bearer":
if self.auto_error:
raise HTTPException(
Expand Down

0 comments on commit 5f437d3

Please sign in to comment.