class MetadataParser

Methods

array
parseXml(string $xml)

Parse IDP metadata from XML string.

array
parseFromUrl(string $url)

Fetch and parse metadata from a URL.

void
validateUrlNotInternal(string $url)

Validate that a URL does not point to internal/private network addresses.

string|null
getSsoUrl(DOMXPath $xpath, DOMElement $idpDescriptor)

Get the SSO URL from the metadata.

string|null
getSloUrl(DOMXPath $xpath, DOMElement $idpDescriptor)

Get the SLO URL from the metadata.

array
getCertificates(DOMXPath $xpath, DOMElement $idpDescriptor)

Get all certificates from the metadata.

Details

at line 13
array parseXml(string $xml)

Parse IDP metadata from XML string.

Parameters

string $xml

Return Value

array

at line 83
array parseFromUrl(string $url)

Fetch and parse metadata from a URL.

Parameters

string $url

Return Value

array

at line 112
protected void validateUrlNotInternal(string $url)

Validate that a URL does not point to internal/private network addresses.

Parameters

string $url

Return Value

void

at line 136
protected string|null getSsoUrl(DOMXPath $xpath, DOMElement $idpDescriptor)

Get the SSO URL from the metadata.

Parameters

DOMXPath $xpath
DOMElement $idpDescriptor

Return Value

string|null

at line 165
protected string|null getSloUrl(DOMXPath $xpath, DOMElement $idpDescriptor)

Get the SLO URL from the metadata.

Parameters

DOMXPath $xpath
DOMElement $idpDescriptor

Return Value

string|null

at line 192
protected array getCertificates(DOMXPath $xpath, DOMElement $idpDescriptor)

Get all certificates from the metadata.

Parameters

DOMXPath $xpath
DOMElement $idpDescriptor

Return Value

array