Skip to content

Commit

Permalink
Merge pull request #62 from maykinmedia/fix/58-wrong-entity-id
Browse files Browse the repository at this point in the history
[#58] Do not swap entityID with URL for eH
  • Loading branch information
vaszig authored Mar 5, 2024
2 parents 970d3ed + e79459f commit a3eda6f
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 6 deletions.
6 changes: 1 addition & 5 deletions digid_eherkenning/models/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -221,11 +221,7 @@ def process_metadata_from_xml_source(self) -> tuple[dict[str, str], bytes]:
# sometimes the xml file contains urn instead of a url as an entity ID
# use the provided url instead
urls = {
"entityId": (
entity_id
if not (entity_id := idp.get("entityId")).startswith("urn:")
else self.metadata_file_source
),
"entityId": idp.get("entityId"),
"sso_url": idp.get("singleSignOnService", {}).get("url"),
"slo_url": idp.get("singleLogoutService", {}).get("url"),
}
Expand Down
2 changes: 1 addition & 1 deletion tests/test_models.py
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ def test_fields_are_populated_on_eherkennig_save(self, get_matadata):
)
self.assertEqual(
config.idp_service_entity_id,
"https://eh01.staging.iwelcome.nl/broker/sso/1.13",
"urn:etoegang:HM:00000003520354760000:entities:9632",
)

@patch(
Expand Down

0 comments on commit a3eda6f

Please sign in to comment.