diff options
-rw-r--r-- | CHANGELOG.rst | 2 | ||||
-rw-r--r-- | jwt/api_jwt.py | 2 |
2 files changed, 3 insertions, 1 deletions
diff --git a/CHANGELOG.rst b/CHANGELOG.rst index 37875e9..3c69338 100644 --- a/CHANGELOG.rst +++ b/CHANGELOG.rst @@ -10,6 +10,8 @@ This project adheres to `Semantic Versioning <https://semver.org/>`__. Changed ~~~~~~~ +- Changed the error message when the token audience doesn't match the expected audience by @irdkwmnsb `#809 <https://github.com/jpadilla/pyjwt/pull/809>`__ + Fixed ~~~~~ diff --git a/jwt/api_jwt.py b/jwt/api_jwt.py index 8840708..fd8a8bf 100644 --- a/jwt/api_jwt.py +++ b/jwt/api_jwt.py @@ -331,7 +331,7 @@ class PyJWT: audience = [audience] if all(aud not in audience_claims for aud in audience): - raise InvalidAudienceError("Invalid audience") + raise InvalidAudienceError("Audience doesn't match") def _validate_iss(self, payload: dict[str, Any], issuer: Any) -> None: if issuer is None: |