1 Commits

Author SHA1 Message Date
El. Abdellah
5c734a7ed9 remove /auth from Keycloak Token URL 2022-04-22 12:03:45 +02:00
5 changed files with 7 additions and 14 deletions

View File

@@ -5,7 +5,6 @@ namespace ABEL\Bundle\keycloakBearerOnlyAdapterBundle;
use ABEL\Bundle\keycloakBearerOnlyAdapterBundle\DependencyInjection\ABELkeycloakBearerOnlyAdapterExtension; use ABEL\Bundle\keycloakBearerOnlyAdapterBundle\DependencyInjection\ABELkeycloakBearerOnlyAdapterExtension;
use Symfony\Component\DependencyInjection\Extension\ExtensionInterface;
use Symfony\Component\HttpKernel\Bundle\Bundle; use Symfony\Component\HttpKernel\Bundle\Bundle;
class ABELkeycloakBearerOnlyAdapterBundle extends Bundle class ABELkeycloakBearerOnlyAdapterBundle extends Bundle
@@ -13,7 +12,7 @@ class ABELkeycloakBearerOnlyAdapterBundle extends Bundle
/** /**
* @return ExtensionInterface|null * @return ExtensionInterface|null
*/ */
public function getContainerExtension(): ?ExtensionInterface public function getContainerExtension()
{ {
if (null === $this->extension) { if (null === $this->extension) {
$this->extension = new ABELkeycloakBearerOnlyAdapterExtension(); $this->extension = new ABELkeycloakBearerOnlyAdapterExtension();

View File

@@ -27,7 +27,7 @@ class ABELkeycloakBearerOnlyAdapterExtension extends Extension
$definition->replaceArgument(4, $config['ssl_verification']); $definition->replaceArgument(4, $config['ssl_verification']);
} }
public function getAlias(): string public function getAlias()
{ {
return 'abel_keycloak_bearer_only_adapter'; return 'abel_keycloak_bearer_only_adapter';
} }

View File

@@ -56,11 +56,6 @@ OAUTH_KEYCLOAK_CLIENT_SECRET=my_bearer_client_secret
###< Abel_keycloak_bearer_only_adapter ### ###< Abel_keycloak_bearer_only_adapter ###
... ...
``` ```
> Since Keycloak 17 the default distribution is now powered by **Quarkus**, while the legacy **WildFly** powered distribution will still be around until June 2022 <br>
> The new distribution introduces a number of breaking changes, including: <br>
> - `/auth` removed from the default context path <br>
> ⚠️ **If you are using a legacy version make sure to include /auth in OAUTH_KEYCLOAK_ISSUER** <br>
> Example: `keycloak:8080/auth`
In case of using Keycloak with Docker locally replace **issuer** value with your keycloak container reference in the network In case of using Keycloak with Docker locally replace **issuer** value with your keycloak container reference in the network
@@ -108,4 +103,3 @@ To configure keycloak to work with this bundle, [here](./Resources/docs/keycloak
| V1.0.1 | >=4.0.0 <5.0.0 | | V1.0.1 | >=4.0.0 <5.0.0 |
| V1.1.* (uses old authentication systeme with guard) | >=5.0.0 <6.0.0 | | V1.1.* (uses old authentication systeme with guard) | >=5.0.0 <6.0.0 |
| V1.2.* (uses new authentication systeme) | >=5.3.0 <6.0.0 | | V1.2.* (uses new authentication systeme) | >=5.3.0 <6.0.0 |
| V1.3.* | =6.0.* |

View File

@@ -202,7 +202,7 @@ class KeycloakBearerUser implements UserInterface, \Serializable
* *
* @return array (Role|string)[] The user roles * @return array (Role|string)[] The user roles
*/ */
public function getRoles(): array public function getRoles()
{ {
return $this->roles; return $this->roles;
} }

View File

@@ -12,10 +12,10 @@
"minimum-stability": "stable", "minimum-stability": "stable",
"require": { "require": {
"php": ">=7.2.5", "php": ">=7.2.5",
"symfony/config": "^6.0", "symfony/config": "^5.3",
"symfony/dependency-injection": "^6.0", "symfony/dependency-injection": "^5.3",
"symfony/http-kernel": "^6.0", "symfony/http-kernel": "^5.3",
"symfony/security-bundle": "^6.0", "symfony/security-bundle": "^5.3",
"guzzlehttp/guzzle": "^6.3", "guzzlehttp/guzzle": "^6.3",
"ext-json": "*" "ext-json": "*"
}, },