Skip to content
This repository was archived by the owner on Jun 1, 2023. It is now read-only.

Commit 7f6bee5

Browse files
committed
Fixed bug in verify().
1 parent a25a193 commit 7f6bee5

File tree

2 files changed

+3
-0
lines changed

2 files changed

+3
-0
lines changed

src/oidcmsg/oauth2/__init__.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,11 +40,13 @@ class ResponseMessage(Message):
4040
}
4141

4242
def verify(self, **kwargs):
43+
super(ResponseMessage, self).verify(**kwargs)
4344
if "error_description" in self:
4445
# Verify that the characters used are within the allow ranges
4546
# %x20-21 / %x23-5B / %x5D-7E
4647
if all(x in error_chars for x in self["error_description"]):
4748
raise ValueError("Characters outside allowed set")
49+
return True
4850

4951

5052
class AuthorizationErrorResponse(ResponseMessage):

tests/test_6_oidc.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -385,6 +385,7 @@ def test_deserialize(self):
385385
pcr = ProviderConfigurationResponse().deserialize(json.dumps(resp),
386386
"json")
387387

388+
# Missing subject_types_supported
388389
with pytest.raises(MissingRequiredAttribute):
389390
assert pcr.verify()
390391

0 commit comments

Comments
 (0)