Skip to content

Commit 16566ee

Browse files
authored
Merge pull request #602 from RoSk0/568-follow-up
#568 follow up - simplify generating metadata without validUntil
2 parents a782c08 + 52b3a7f commit 16566ee

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

src/Saml2/Settings.php

+3-2
Original file line numberDiff line numberDiff line change
@@ -879,14 +879,15 @@ public function getIdPSLOResponseUrl()
879879
* $advancedSettings['security']['wantAssertionsEncrypted'] are enabled.
880880
* @param int|null $validUntil Metadata's valid time
881881
* @param int|null $cacheDuration Duration of the cache in seconds
882+
* @param bool $ignoreValidUntil exclude the validUntil tag from metadata
882883
*
883884
* @return string SP metadata (xml)
884885
* @throws Exception
885886
* @throws Error
886887
*/
887-
public function getSPMetadata($alwaysPublishEncryptionCert = false, $validUntil = null, $cacheDuration = null)
888+
public function getSPMetadata($alwaysPublishEncryptionCert = false, $validUntil = null, $cacheDuration = null, $ignoreValidUntil = false)
888889
{
889-
$metadata = Metadata::builder($this->_sp, $this->_security['authnRequestsSigned'], $this->_security['wantAssertionsSigned'], $validUntil, $cacheDuration, $this->getContacts(), $this->getOrganization());
890+
$metadata = Metadata::builder($this->_sp, $this->_security['authnRequestsSigned'], $this->_security['wantAssertionsSigned'], $validUntil, $cacheDuration, $this->getContacts(), $this->getOrganization(), [], $ignoreValidUntil);
890891

891892
$certNew = $this->getSPcertNew();
892893
if (!empty($certNew)) {

0 commit comments

Comments
 (0)