Skip to content

Commit

Permalink
fix: allow empty validation keys to be set into security configuration
Browse files Browse the repository at this point in the history
  • Loading branch information
wazelin committed Sep 13, 2022
1 parent 237fafd commit 99646a8
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 3 deletions.
5 changes: 3 additions & 2 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
CHANGELOG
=========

Unreleased
6.7.2
-----

* Added AUD claim validation in `LtiServiceClient`
* Fixed AUD claim validation in `LtiServiceClient`
* Fixed empty validation key assignment to the security configuration

6.7.1
-----
Expand Down
4 changes: 3 additions & 1 deletion src/Security/Jwt/Configuration/ConfigurationFactory.php
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,9 @@ private function findAlgorithm(?KeyInterface $signingKey = null, ?KeyInterface $
private function convertKey(?KeyInterface $key = null): Key
{
if (null === $key) {
return InMemory::plainText('');
return method_exists(InMemory::class, 'empty')
? InMemory::empty()
: InMemory::plainText('');
}

return $this->converter->convert($key);
Expand Down

0 comments on commit 99646a8

Please sign in to comment.