Skip to content

Commit

Permalink
Merge pull request #1572 from ScilifelabDataCentre/DDS-2175-InvalidJW…
Browse files Browse the repository at this point in the history
…EData

InvalidJWEData
  • Loading branch information
rv0lt authored Nov 28, 2024
2 parents 709550a + d60dab3 commit d4f8cc2
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
4 changes: 4 additions & 0 deletions SPRINTLOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -450,3 +450,7 @@ _Nothing merged during this sprint_
- Workflow: Bump GitHub checkout action to v4 ([#1556](https://github.com/ScilifelabDataCentre/dds_web/pull/1556))
- Workflow: CodeQL action version(s) bumped to v3 ([#1569](https://github.com/ScilifelabDataCentre/dds_web/pull/1569))
- Workflow: Setup-node, codecov and upload-sarif action versions bumped to v4, v4 and v3, respectively ([#1570](https://github.com/ScilifelabDataCentre/dds_web/pull/1570))

# 2024-11-04 - 2024-11-15

- Removed exception for invalid token to simplify logging and reduce unnecessary error entries ([#1572](https://github.com/ScilifelabDataCentre/dds_web/pull/1572))
2 changes: 1 addition & 1 deletion dds_web/security/auth.py
Original file line number Diff line number Diff line change
Expand Up @@ -278,7 +278,7 @@ def __verify_general_token(token):
# ValueError is raised when the token doesn't look right (for example no periods)
# jwcryopto.common.JWException is the base exception raised by jwcrypto,
# and is raised when the token is malformed or invalid.
flask.current_app.logger.exception(e)
flask.current_app.logger.warning(f"Error with Token operation: {type(e).__name__}")
raise AuthenticationError(message="Invalid token") from e

expiration_time = data.get("exp")
Expand Down

0 comments on commit d4f8cc2

Please sign in to comment.