Skip to content

Commit

Permalink
Merge 05a3635 into f748a46
Browse files Browse the repository at this point in the history
  • Loading branch information
Moroine Bentefrit committed Nov 24, 2017
2 parents f748a46 + 05a3635 commit 80da0f4
Show file tree
Hide file tree
Showing 6 changed files with 33 additions and 14 deletions.
17 changes: 13 additions & 4 deletions CHANGELOG.md
@@ -1,12 +1,21 @@
# CHANGELOG

## v0.7.2
## [unreleased]

### Add
- Add an ability to receive GET and POST requests
- \AdactiveSas\Saml2BridgeBundle\Entity\IdentityProvider::getSsoBinding was removed
- \AdactiveSas\Saml2BridgeBundle\Entity\IdentityProvider::getSlsBinding was removed
- receiving POST binding request
- NewRelic example
- Single sign-on using `HostedIdentityProviderProcessor::processSingleSignOn` now supports GET and POST requests.
- Single logout using `HostedIdentityProviderProcessor::processSingleLogoutService` now supports GET and POST messages.

## Fix
- remove dependency of "roave/security-advisories" to allow require without putting minimum stability dev (#10)[https://github.com/AdactiveSAS/saml2-bridge-bundle/issues/10]

## Deprecated
- `\AdactiveSas\Saml2BridgeBundle\Entity\IdentityProvider::getSsoBinding` was removed, overwriting this method have no
more effects.
- `\AdactiveSas\Saml2BridgeBundle\Entity\IdentityProvider::getSlsBinding` was removed, overwriting this method have no
more effects.

## v0.7.1

Expand Down
16 changes: 13 additions & 3 deletions composer.json
@@ -1,7 +1,18 @@
{
"name": "adactive-sas/saml2-bridge-bundle",
"description": "This bundle aim to integrate simplesamlphp/saml2 library",
"keywords": ["adactiveSas", "simplesamlphp", "SAML", "SAML2", "Symfony", "Bundle"],
"keywords": [
"adactiveSas",
"SAML",
"SAML2",
"idp",
"identity-provider",
"saml-idp",
"Symfony",
"Bundle",
"symfony-bundle",
"bridge"
],
"type": "symfony-bundle",
"license": "GPL-3.0",
"minimum-stability": "stable",
Expand All @@ -16,8 +27,7 @@
"ext-openssl": "*",
"simplesamlphp/saml2": "^1.10.3",
"symfony/symfony": "^2.7.0|^3.0.0",
"symfony/workflow": "^3.0.0",
"roave/security-advisories": "dev-master"
"symfony/workflow": "^3.0.0"
},
"require-dev": {
"phpunit/phpunit": "^5.7.17",
Expand Down
2 changes: 1 addition & 1 deletion phpunit.xml.dist
Expand Up @@ -21,7 +21,7 @@

<testsuites>
<testsuite name="SAML Bridge Bundle Test Suite">
<directory>src/Tests</directory>
<directory suffix="Test.php" >src/Tests</directory>
</testsuite>
</testsuites>

Expand Down
4 changes: 2 additions & 2 deletions src/Resources/views/Metadata/metadata.xml.twig
Expand Up @@ -2,10 +2,10 @@
<md:EntityDescriptor xmlns:md="urn:oasis:names:tc:SAML:2.0:metadata" entityID="{{ metadata.entityId }}">
{% if metadata.hasIdp %}
<md:IDPSSODescriptor protocolSupportEnumeration="urn:oasis:names:tc:SAML:2.0:protocol">
<md:SingleSignOnService Binding="{{ constant('\SAML2_Const::BINDING_HTTP_REDIRECT') }}" Location="{{ metadata.idp.ssoUrl }}"/>
<md:SingleSignOnService Binding="{{ constant('\SAML2_Const::BINDING_HTTP_POST') }}" Location="{{ metadata.idp.ssoUrl }}"/>
<md:SingleLogoutService Binding="{{ constant('\SAML2_Const::BINDING_HTTP_REDIRECT') }}" Location="{{ metadata.idp.slsUrl }}"/>
<md:SingleLogoutService Binding="{{ constant('\SAML2_Const::BINDING_HTTP_POST') }}" Location="{{ metadata.idp.slsUrl }}"/>
<md:SingleSignOnService Binding="{{ constant('\SAML2_Const::BINDING_HTTP_REDIRECT') }}" Location="{{ metadata.idp.ssoUrl }}"/>
<md:SingleSignOnService Binding="{{ constant('\SAML2_Const::BINDING_HTTP_POST') }}" Location="{{ metadata.idp.ssoUrl }}"/>
</md:IDPSSODescriptor>
{% endif %}
</md:EntityDescriptor>
2 changes: 1 addition & 1 deletion src/SAML2/Provider/HostedIdentityProviderProcessor.php
Expand Up @@ -401,7 +401,7 @@ public function continueSingleSignOn()
*/
public function processSingleLogoutService(Request $httpRequest)
{
$inputBinding = $this->bindingContainer->get($this->identityProvider->getSlsBinding());
$inputBinding = $this->bindingContainer->getByRequestMethod($httpRequest->getMethod());

try {
$logoutMessage = $inputBinding->receiveUnsignedMessage($httpRequest);
Expand Down
6 changes: 3 additions & 3 deletions src/Tests/Functional/MetadataTest.php
Expand Up @@ -18,17 +18,17 @@

namespace AdactiveSas\Saml2BridgeBundle\Tests\Functional;

class MetadataTestTest extends WebTestCase
class MetadataTest extends WebTestCase
{
protected $metadataExpected =
<<<META
<?xml version="1.0" encoding="UTF-8"?>
<md:EntityDescriptor xmlns:md="urn:oasis:names:tc:SAML:2.0:metadata" entityID="http://localhost/saml/metadata/">
<md:IDPSSODescriptor protocolSupportEnumeration="urn:oasis:names:tc:SAML:2.0:protocol">
<md:SingleSignOnService Binding="urn:oasis:names:tc:SAML:2.0:bindings:HTTP-Redirect" Location="http://localhost/saml/sso/"/>
<md:SingleSignOnService Binding="urn:oasis:names:tc:SAML:2.0:bindings:HTTP-POST" Location="http://localhost/saml/sso/"/>
<md:SingleLogoutService Binding="urn:oasis:names:tc:SAML:2.0:bindings:HTTP-Redirect" Location="http://localhost/saml/sls/"/>
<md:SingleLogoutService Binding="urn:oasis:names:tc:SAML:2.0:bindings:HTTP-POST" Location="http://localhost/saml/sls/"/>
<md:SingleSignOnService Binding="urn:oasis:names:tc:SAML:2.0:bindings:HTTP-Redirect" Location="http://localhost/saml/sso/"/>
<md:SingleSignOnService Binding="urn:oasis:names:tc:SAML:2.0:bindings:HTTP-POST" Location="http://localhost/saml/sso/"/>
</md:IDPSSODescriptor>
</md:EntityDescriptor>
META;
Expand Down

0 comments on commit 80da0f4

Please sign in to comment.