You are here

class MetadataReader in SAML SP 2.0 Single Sign On (SSO) - SAML Service Provider 8

Hierarchy

Expanded class hierarchy of MetadataReader

1 file declares its use of MetadataReader
MiniorangeSPInformation.php in src/Form/MiniorangeSPInformation.php
Contains \Drupal\miniorange_saml\Form\MiniorangeSPInformation.

File

src/MetadataReader.php, line 3

Namespace

Drupal\miniorange_saml
View source
class MetadataReader {
  private $identityProviders;
  private $serviceProviders;
  public function __construct(\DOMNode $xml = NULL) {
    $this->identityProviders = array();
    $this->serviceProviders = array();
    $entityDescriptors = Utilities::xpQuery($xml, './saml_metadata:EntityDescriptor');
    foreach ($entityDescriptors as $entityDescriptor) {
      $idpSSODescriptor = Utilities::xpQuery($entityDescriptor, './saml_metadata:IDPSSODescriptor');
      if (isset($idpSSODescriptor) && !empty($idpSSODescriptor)) {
        array_push($this->identityProviders, new IdentityProviders($entityDescriptor));
      }

      //TODO: add sp descriptor
    }
  }
  public function getIdentityProviders() {
    return $this->identityProviders;
  }
  public function getServiceProviders() {
    return $this->serviceProviders;
  }

}

Members