Skip to content

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
NikiforovAll authored Apr 25, 2024
1 parent 47d8f53 commit 8e0e0b5
Showing 1 changed file with 0 additions and 12 deletions.
12 changes: 0 additions & 12 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -69,18 +69,6 @@ In this example, configuration is based on `appsettings.json`.
}
```

You can always fetch the corresponding authentication options like this:

```csharp
var authenticationOptions = configuration
.GetSection(KeycloakAuthenticationOptions.Section)
.Get<KeycloakAuthenticationOptions>(KeycloakFormatBinder.Instance);

services.AddKeycloakAuthentication(authenticationOptions);
```

Note, the default case convention for `KeycloakAuthenticationOptions` configuration is PascalCase, but you can change it by specifying `KeycloakFormatBinder.Instance` binding options to retrieve it based on original kebab-case. See [changes in 2.0.0](https://nikiforovall.github.io/keycloak-authorization-services-dotnet/migration.html#key-changes-in-2-0-0)

## Example Authorization

With `Keycloak.AuthServices.Authorization`, you can implement role-based authorization in your application. This package allows you to define policies based on roles. Also, you can use Keycloak as Authorization Server. It is a powerful way to organize and apply authorization polices centrally.
Expand Down

0 comments on commit 8e0e0b5

Please sign in to comment.