SimpleSAML_Metadata_SAMLParser::processSPSSODescriptor PHP Method

processSPSSODescriptor() private method

This function extracts metadata from a SPSSODescriptor element.
private processSPSSODescriptor ( SAML2\XML\md\SPSSODescriptor $element, integer | null $expireTime )
$element SAML2\XML\md\SPSSODescriptor The element which should be parsed.
$expireTime integer | null The unix timestamp for when this element should expire, or NULL if unknown.
    private function processSPSSODescriptor(\SAML2\XML\md\SPSSODescriptor $element, $expireTime)
    {
        assert('is_null($expireTime) || is_int($expireTime)');
        $sp = self::parseSSODescriptor($element, $expireTime);
        // find all AssertionConsumerService elements
        $sp['AssertionConsumerService'] = self::extractEndpoints($element->AssertionConsumerService);
        // find all the attributes and SP name...
        $attcs = $element->AttributeConsumingService;
        if (count($attcs) > 0) {
            self::parseAttributeConsumerService($attcs[0], $sp);
        }
        // check AuthnRequestsSigned
        if ($element->AuthnRequestsSigned !== null) {
            $sp['AuthnRequestsSigned'] = $element->AuthnRequestsSigned;
        }
        // check WantAssertionsSigned
        if ($element->WantAssertionsSigned !== null) {
            $sp['WantAssertionsSigned'] = $element->WantAssertionsSigned;
        }
        $this->spDescriptors[] = $sp;
    }