Skip to content

Commit b11d713

Browse files
authored
Harden XMLSecEnc against PHP 8 null fatals
Guard encrypt/decrypt and EncryptedKey construction against null DOM nodes and failed crypto returns; tighten PHPDoc and changelog.
1 parent bd22307 commit b11d713

2 files changed

Lines changed: 241 additions & 50 deletions

File tree

CHANGELOG.txt

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -92,6 +92,8 @@ Notes:
9292
Improvements:
9393
- Fix deprecation notice in makeAsnSegment() under PHP 8.5
9494
- Update parameter type in XMLSecurityDSig::addReference() and addRefInternal()
95+
- Tighten XMLSecEnc PHPDoc types for algorithm allowlists, references, and
96+
encrypt/decrypt return values
9597

9698
Bug Fixes:
9799
- Compact signature template (XMLSecurityDSig 'stripWhitespace' option) removes
@@ -100,6 +102,9 @@ Bug Fixes:
100102
- Compact encryption template (XMLSecEnc 'stripWhitespace' option) removes
101103
inter-element whitespace from EncryptedData for peers that reject significant
102104
whitespace between elements.
105+
- Guard XMLSecEnc encrypt/decrypt and EncryptedKey construction against null
106+
DOM nodes, uninitialized templates, and non-string crypto results that could
107+
fatal under PHP 8; prefer getAlgorithm() when writing EncryptionMethod
103108

104109
12, Dec 2025, 3.1.5
105110
Security:

0 commit comments

Comments
 (0)