Skip to content

Commit

Permalink
Update saml2 library to 4.6.13 (#1341)
Browse files Browse the repository at this point in the history
* Update SAML2 library to 4.6.13
* Fix integration tests

The Mock IdP must set a Destination attribute in the <Response>, as per simplesamlphp/saml2@b4daf21
  • Loading branch information
baszoetekouw authored Nov 26, 2024
1 parent 0668b8c commit 8259e53
Show file tree
Hide file tree
Showing 4 changed files with 35 additions and 22 deletions.
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
"ramsey/uuid": "^3.3.0",
"sensio/framework-extra-bundle": "^3.0",
"sensio/generator-bundle": "^3.0",
"simplesamlphp/saml2": "^4.1",
"simplesamlphp/saml2": "4.6.*",
"swiftmailer/swiftmailer": "^5.4",
"symfony/monolog-bundle": "^3.1.0",
"symfony/swiftmailer-bundle": "^2.6",
Expand Down
50 changes: 30 additions & 20 deletions composer.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -100,6 +100,9 @@ public function singleSignOnAction(Request $request, $idpName)
$authnRequest->getAssertionConsumerServiceURL() :
$response->getDestination());

/* set the destination element of the response to the ACS URL */
$response->setDestination($destination);

if ($mockIdp->mustUseHttpRedirect()) {
$redirect = new HTTPRedirect();
$redirect->setDestination($destination);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ public function testToString()
$annotatedRequest->setDebug();

$this->assertEquals(
'{"sspMessage":"<?xml version=\"1.0\"?>\n<samlp:AuthnRequest xmlns:samlp=\"urn:oasis:names:tc:SAML:2.0:protocol\" xmlns:saml=\"urn:oasis:names:tc:SAML:2.0:assertion\" ID=\"TEST123\" Version=\"2.0\" IssueInstant=\"1970-01-01T00:00:00Z\"\/>\n","keyId":null,"wasSigned":false,"debug":true,"unsolicited":false,"transparent":false,"deliverByBinding":null}',
'{"sspMessage":"<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<samlp:AuthnRequest xmlns:samlp=\"urn:oasis:names:tc:SAML:2.0:protocol\" xmlns:saml=\"urn:oasis:names:tc:SAML:2.0:assertion\" ID=\"TEST123\" Version=\"2.0\" IssueInstant=\"1970-01-01T00:00:00Z\"\/>\n","keyId":null,"wasSigned":false,"debug":true,"unsolicited":false,"transparent":false,"deliverByBinding":null}',
$annotatedRequest->__toString()
);
}
Expand Down

0 comments on commit 8259e53

Please sign in to comment.