Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions flask_saml2/sp/sp.py
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,10 @@ def get_sp_entity_id(self) -> str:
"""
return self.get_metadata_url()

def get_nameid_format(self) -> str:
"""Get the NameIDFormat for this SP."""
return self.get_sp_config().get('nameid_format')

def get_sp_certificate(self) -> Optional[X509]:
"""Get the public certificate for this SP."""
return self.get_sp_config().get('certificate')
Expand Down Expand Up @@ -302,6 +306,7 @@ def get_metadata_context(self) -> dict:
'acs_url': self.get_acs_url(),
'entity_id': self.get_sp_entity_id(),
'certificate': certificate_to_string(self.get_sp_certificate()),
'nameid_format': self.get_nameid_format(),
'org': None,
'contacts': [],
}
Expand Down