Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 9 additions & 9 deletions .github/workflows/php.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,9 @@ jobs:
strategy:
fail-fast: false
matrix:
php-version: ['8.2', '8.3', '8.4', '8.5']
php-version: ['8.3', '8.4', '8.5']

uses: simplesamlphp/simplesamlphp-test-framework/.github/workflows/reusable_phplinter.yml@v1.10.6
uses: simplesamlphp/simplesamlphp-test-framework/.github/workflows/reusable_phplinter.yml@v1.11.0
with:
php-version: ${{ matrix.php-version }}

Expand All @@ -30,7 +30,7 @@ jobs:
strategy:
fail-fast: false

uses: simplesamlphp/simplesamlphp-test-framework/.github/workflows/reusable_linter.yml@v1.10.6
uses: simplesamlphp/simplesamlphp-test-framework/.github/workflows/reusable_linter.yml@v1.11.0
with:
enable_eslinter: false
enable_jsonlinter: true
Expand All @@ -45,15 +45,15 @@ jobs:
fail-fast: false
matrix:
operating-system: [ubuntu-latest]
php-versions: ['8.2', '8.3', '8.4', '8.5']
php-versions: ['8.3', '8.4', '8.5']

steps:
- name: Setup PHP, with composer and extensions
# https://github.com/shivammathur/setup-php
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php-versions }}
extensions: ctype, date, dom, pcre, spl, xml
extensions: ctype, date, dom, intl, pcre, sodium, spl, xml
tools: composer
ini-values: error_reporting=E_ALL
coverage: pcov
Expand Down Expand Up @@ -107,15 +107,15 @@ jobs:
fail-fast: true
matrix:
operating-system: [windows-latest]
php-versions: ['8.2', '8.3', '8.4', '8.5']
php-versions: ['8.3', '8.4', '8.5']

steps:
- name: Setup PHP, with composer and extensions
# https://github.com/shivammathur/setup-php
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php-versions }}
extensions: ctype, date, dom, pcre, spl, xml
extensions: ctype, date, dom, intl, pcre, sodium, spl, xml
tools: composer
ini-values: error_reporting=E_ALL
coverage: none
Expand Down Expand Up @@ -160,8 +160,8 @@ jobs:
uses: shivammathur/setup-php@v2
with:
# Should be the lowest supported version
php-version: '8.2'
extensions: ctype, date, dom, pcre, spl, xml
php-version: '8.3'
extensions: ctype, date, dom, intl, pcre, sodium, spl, xml
tools: composer
coverage: none

Expand Down
4 changes: 2 additions & 2 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
}
],
"require": {
"php": "^8.2",
"php": "^8.3",
"ext-dom": "*",

"simplesamlphp/assert": "~1.9",
Expand All @@ -19,7 +19,7 @@
"simplesamlphp/xml-wss-core": "~1.0"
},
"require-dev": {
"simplesamlphp/simplesamlphp-test-framework": "~1.10",
"simplesamlphp/simplesamlphp-test-framework": "~1.11",
"simplesamlphp/xml-soap": "~2.0"
},
"autoload": {
Expand Down
32 changes: 16 additions & 16 deletions src/Constants.php
Original file line number Diff line number Diff line change
Expand Up @@ -15,46 +15,46 @@ class Constants extends \SimpleSAML\XML\Constants
/**
* The namespace for WS-Addressing protocol.
*/
public const NS_ADDR_200408 = 'http://schemas.xmlsoap.org/ws/2004/08/addressing';
public const string NS_ADDR_200408 = 'http://schemas.xmlsoap.org/ws/2004/08/addressing';

public const NS_ADDR_200508 = 'http://www.w3.org/2005/08/addressing';
public const string NS_ADDR_200508 = 'http://www.w3.org/2005/08/addressing';

/**
* The namespace for the WS-Addressing - Metadata.
*/
public const NS_ADDR_METADATA = 'http://www.w3.org/2007/02/addressing/metadata';
public const string NS_ADDR_METADATA = 'http://www.w3.org/2007/02/addressing/metadata';

/**
* The namespace for the WS-Addressing - WSDL Binding.
*/
public const NS_ADDR_WSDL = 'http://www.w3.org/2006/05/addressing/wsdl';
public const string NS_ADDR_WSDL = 'http://www.w3.org/2006/05/addressing/wsdl';

/**
* The schema-defined wsa fault codes
*/
public const WSA_FAULT_INVALID_ADDRESSING_HEADER = 'InvalidAddressingHeader';
public const string WSA_FAULT_INVALID_ADDRESSING_HEADER = 'InvalidAddressingHeader';

public const WSA_FAULT_INVALID_ADDRESS = 'InvalidAddress';
public const string WSA_FAULT_INVALID_ADDRESS = 'InvalidAddress';

public const WSA_FAULT_INVALID_EPR = 'InvalidEPR';
public const string WSA_FAULT_INVALID_EPR = 'InvalidEPR';

public const WSA_FAULT_INVALID_CARDINALITY = 'InvalidCardinality';
public const string WSA_FAULT_INVALID_CARDINALITY = 'InvalidCardinality';

public const WSA_FAULT_MISSING_ADDRESS_IN_EPR = 'MissingAddressInEPR';
public const string WSA_FAULT_MISSING_ADDRESS_IN_EPR = 'MissingAddressInEPR';

public const WSA_FAULT_DUPLICATE_MESSAGEID = 'DupicateMessageID';
public const string WSA_FAULT_DUPLICATE_MESSAGEID = 'DupicateMessageID';

public const WSA_FAULT_ACTION_MISMATCH = 'ActionMismatch';
public const string WSA_FAULT_ACTION_MISMATCH = 'ActionMismatch';

public const WSA_FAULT_MESSAGE_ADDRESSING_HEADER_REQUIRED = 'MessageAddressingHeaderRequired';
public const string WSA_FAULT_MESSAGE_ADDRESSING_HEADER_REQUIRED = 'MessageAddressingHeaderRequired';

public const WSA_FAULT_DESTINATION_UNREACHABLE = 'DestinationUnreachable';
public const string WSA_FAULT_DESTINATION_UNREACHABLE = 'DestinationUnreachable';

public const WSA_FAULT_ACTION_NOT_SUPPORTED = 'ActionNotSupported';
public const string WSA_FAULT_ACTION_NOT_SUPPORTED = 'ActionNotSupported';

public const WSA_FAULT_ENDPOINT_UNAVAILABLE = 'EndpointUnavailable';
public const string WSA_FAULT_ENDPOINT_UNAVAILABLE = 'EndpointUnavailable';

public const FAULT_CODES = [
public const array FAULT_CODES = [
self::WSA_FAULT_INVALID_ADDRESSING_HEADER,
self::WSA_FAULT_INVALID_ADDRESS,
self::WSA_FAULT_INVALID_EPR,
Expand Down
7 changes: 2 additions & 5 deletions src/XML/wsa_200408/AbstractAttributedQNameType.php
Original file line number Diff line number Diff line change
Expand Up @@ -27,11 +27,10 @@ abstract class AbstractAttributedQNameType extends AbstractWsaElement
use TypedTextContentTrait;


/** @var string */
public const TEXTCONTENT_TYPE = QNameValue::class;
public const string TEXTCONTENT_TYPE = QNameValue::class;

/** The namespace-attribute for the xs:anyElement element */
public const XS_ANY_ATTR_NAMESPACE = NS::OTHER;
public const string XS_ANY_ATTR_NAMESPACE = NS::OTHER;


/**
Expand All @@ -51,7 +50,6 @@ final public function __construct(QNameValue $value, array $namespacedAttributes
* Convert XML into a class instance
*
* @param \DOMElement $xml The XML element we should load
* @return static
*
* @throws \SimpleSAML\XMLSchema\Exception\InvalidDOMElementException
* If the qualified name of the supplied element is wrong
Expand All @@ -69,7 +67,6 @@ public static function fromXML(DOMElement $xml): static
* Convert this element to XML.
*
* @param \DOMElement|null $parent The element we should append this element to.
* @return \DOMElement
*/
public function toXML(?DOMElement $parent = null): DOMElement
{
Expand Down
7 changes: 2 additions & 5 deletions src/XML/wsa_200408/AbstractAttributedURIType.php
Original file line number Diff line number Diff line change
Expand Up @@ -27,11 +27,10 @@ abstract class AbstractAttributedURIType extends AbstractWsaElement
use TypedTextContentTrait;


/** @var string */
public const TEXTCONTENT_TYPE = AnyURIValue::class;
public const string TEXTCONTENT_TYPE = AnyURIValue::class;

/** The namespace-attribute for the xs:anyAttribute element */
public const XS_ANY_ATTR_NAMESPACE = NS::OTHER;
public const string XS_ANY_ATTR_NAMESPACE = NS::OTHER;


/**
Expand All @@ -51,7 +50,6 @@ final public function __construct(AnyURIValue $value, array $namespacedAttribute
* Convert XML into a class instance
*
* @param \DOMElement $xml The XML element we should load
* @return static
*
* @throws \SimpleSAML\XMLSchema\Exception\InvalidDOMElementException
* If the qualified name of the supplied element is wrong
Expand All @@ -69,7 +67,6 @@ public static function fromXML(DOMElement $xml): static
* Convert this element to XML.
*
* @param \DOMElement|null $parent The element we should append this element to.
* @return \DOMElement
*/
public function toXML(?DOMElement $parent = null): DOMElement
{
Expand Down
6 changes: 2 additions & 4 deletions src/XML/wsa_200408/AbstractEndpointReferenceType.php
Original file line number Diff line number Diff line change
Expand Up @@ -32,10 +32,10 @@ abstract class AbstractEndpointReferenceType extends AbstractWsaElement


/** The namespace-attribute for the xs:any element */
public const XS_ANY_ELT_NAMESPACE = NS::OTHER;
public const string XS_ANY_ELT_NAMESPACE = NS::OTHER;

/** The namespace-attribute for the xs:anyAttribute element */
public const XS_ANY_ATTR_NAMESPACE = NS::OTHER;
public const string XS_ANY_ATTR_NAMESPACE = NS::OTHER;


/**
Expand Down Expand Up @@ -126,7 +126,6 @@ public function getServiceName(): ?ServiceName
* Note: this method cannot be used when extending this class, if the constructor has a different signature.
*
* @param \DOMElement $xml The XML element we should load.
* @return static
*
* @throws \SimpleSAML\XMLSchema\Exception\InvalidDOMElementException
* if the qualified name of the supplied element is wrong
Expand Down Expand Up @@ -175,7 +174,6 @@ public static function fromXML(DOMElement $xml): static
* Add this endpoint reference to an XML element.
*
* @param \DOMElement|null $parent The element we should append this endpoint to.
* @return \DOMElement
*/
public function toXML(?DOMElement $parent = null): DOMElement
{
Expand Down
7 changes: 2 additions & 5 deletions src/XML/wsa_200408/AbstractRelationshipType.php
Original file line number Diff line number Diff line change
Expand Up @@ -28,11 +28,10 @@ abstract class AbstractRelationshipType extends AbstractWsaElement
use TypedTextContentTrait;


/** @var string */
public const TEXTCONTENT_TYPE = AnyURIValue::class;
public const string TEXTCONTENT_TYPE = AnyURIValue::class;

/** The namespace-attribute for the xs:anyAttribute element */
public const XS_ANY_ATTR_NAMESPACE = NS::OTHER;
public const string XS_ANY_ATTR_NAMESPACE = NS::OTHER;


/**
Expand Down Expand Up @@ -65,7 +64,6 @@ public function getRelationshipType(): ?QNameValue
* Convert XML into a class instance
*
* @param \DOMElement $xml The XML element we should load
* @return static
*
* @throws \SimpleSAML\XMLSchema\Exception\InvalidDOMElementException
* If the qualified name of the supplied element is wrong
Expand All @@ -87,7 +85,6 @@ public static function fromXML(DOMElement $xml): static
* Convert this element to XML.
*
* @param \DOMElement|null $parent The element we should append this element to.
* @return \DOMElement
*/
public function toXML(?DOMElement $parent = null): DOMElement
{
Expand Down
7 changes: 2 additions & 5 deletions src/XML/wsa_200408/AbstractRetryAfterType.php
Original file line number Diff line number Diff line change
Expand Up @@ -27,11 +27,10 @@ abstract class AbstractRetryAfterType extends AbstractWsaElement
use TypedTextContentTrait;


/** @var string */
public const TEXTCONTENT_TYPE = NonNegativeIntegerValue::class;
public const string TEXTCONTENT_TYPE = NonNegativeIntegerValue::class;

/** The namespace-attribute for the xs:anyAttribute element */
public const XS_ANY_ATTR_NAMESPACE = NS::OTHER;
public const string XS_ANY_ATTR_NAMESPACE = NS::OTHER;


/**
Expand All @@ -53,7 +52,6 @@ final public function __construct(
* Convert XML into a class instance
*
* @param \DOMElement $xml The XML element we should load
* @return static
*
* @throws \SimpleSAML\XMLSchema\Exception\InvalidDOMElementException
* If the qualified name of the supplied element is wrong
Expand All @@ -71,7 +69,6 @@ public static function fromXML(DOMElement $xml): static
* Convert this element to XML.
*
* @param \DOMElement|null $parent The element we should append this element to.
* @return \DOMElement
*/
public function toXML(?DOMElement $parent = null): DOMElement
{
Expand Down
7 changes: 2 additions & 5 deletions src/XML/wsa_200408/AbstractServiceNameType.php
Original file line number Diff line number Diff line change
Expand Up @@ -28,11 +28,10 @@ abstract class AbstractServiceNameType extends AbstractWsaElement
use TypedTextContentTrait;


/** @var string */
public const TEXTCONTENT_TYPE = QNameValue::class;
public const string TEXTCONTENT_TYPE = QNameValue::class;

/** The namespace-attribute for the xs:anyElement element */
public const XS_ANY_ATTR_NAMESPACE = NS::OTHER;
public const string XS_ANY_ATTR_NAMESPACE = NS::OTHER;


/**
Expand Down Expand Up @@ -65,7 +64,6 @@ public function getPortName(): ?NCNameValue
* Convert XML into a class instance
*
* @param \DOMElement $xml The XML element we should load
* @return static
*
* @throws \SimpleSAML\XMLSchema\Exception\InvalidDOMElementException
* If the qualified name of the supplied element is wrong
Expand All @@ -87,7 +85,6 @@ public static function fromXML(DOMElement $xml): static
* Convert this element to XML.
*
* @param \DOMElement|null $parent The element we should append this element to.
* @return \DOMElement
*/
public function toXML(?DOMElement $parent = null): DOMElement
{
Expand Down
9 changes: 3 additions & 6 deletions src/XML/wsa_200408/AbstractWsaElement.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,9 @@
*/
abstract class AbstractWsaElement extends AbstractElement
{
/** @var string */
public const NS = C::NS_ADDR_200408;
public const string NS = C::NS_ADDR_200408;

/** @var string */
public const NS_PREFIX = 'wsa';
public const string NS_PREFIX = 'wsa';

/** @var string */
public const SCHEMA = 'resources/schemas/ws-addr-200408.xsd';
public const string SCHEMA = 'resources/schemas/ws-addr-200408.xsd';
}
6 changes: 1 addition & 5 deletions src/XML/wsa_200408/ReferenceParameters.php
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ final class ReferenceParameters extends AbstractWsaElement


/** The namespace-attribute for the xs:any element */
public const XS_ANY_ELT_NAMESPACE = NS::ANY;
public const string XS_ANY_ELT_NAMESPACE = NS::ANY;


/**
Expand All @@ -37,8 +37,6 @@ public function __construct(array $children = [])

/**
* Test if an object, at the state it's in, would produce an empty XML-element
*
* @return bool
*/
public function isEmptyElement(): bool
{
Expand All @@ -50,7 +48,6 @@ public function isEmptyElement(): bool
* Convert XML into an ReferenceParameters element
*
* @param \DOMElement $xml The XML element we should load
* @return static
*
* @throws \SimpleSAML\XMLSchema\Exception\InvalidDOMElementException
* If the qualified name of the supplied element is wrong
Expand All @@ -70,7 +67,6 @@ public static function fromXML(DOMElement $xml): static
* Convert this ReferenceParameters to XML.
*
* @param \DOMElement|null $parent The element we should add this ReferenceParameters to.
* @return \DOMElement This Header-element.
*/
public function toXML(?DOMElement $parent = null): DOMElement
{
Expand Down
Loading