[KEYCLOAK-3546] - Missing fixes.

This commit is contained in:
Pedro Igor 2016-09-09 01:25:17 -03:00
parent 6ec0ed632e
commit 17225116e3
2 changed files with 6 additions and 3 deletions

View file

@ -6,8 +6,11 @@ This class provides several methods from where you can use to obtain permissions
Obtaining the Authorization Context in a Servlet Container Obtaining the Authorization Context in a Servlet Container
```java ```java
HttpServletRequest request = ... // obtain javax.servlet.http.HttpServletRequest HttpServletRequest request = ... // obtain javax.servlet.http.HttpServletRequest
KeycloakSecurityContext keycloakSecurityContext = (KeycloakSecurityContext) request.getAttribute(KeycloakSecurityContext.class.getName()); KeycloakSecurityContext keycloakSecurityContext =
AuthorizationContext authzContext = keycloakSecurityContext.getAuthorizationContext(); (KeycloakSecurityContext) request
.getAttribute(KeycloakSecurityContext.class.getName());
AuthorizationContext authzContext =
keycloakSecurityContext.getAuthorizationContext();
``` ```
[NOTE] [NOTE]

View file

@ -28,7 +28,7 @@ checked against the roles mapped to these same resources. While roles are very u
* Depending on your application size, role management may become difficult and error-prone * Depending on your application size, role management may become difficult and error-prone
* It is not the most flexible access control mechanism. Roles do not represent who you are and lack context information. If you have a role, you can do something. * It is not the most flexible access control mechanism. Roles do not represent who you are and lack context information. If you have a role, you can do something.
Considering that today we need to consider a heterogeneous environments, where users are distributed across different regions, with different local policies, Considering that today we need to consider heterogeneous environments where users are distributed across different regions, with different local policies,
using different devices, and with a high demand for information sharing, {{book.project.name}} Authorization Services can help you improve the authorization capabilities of your applications and services by providing: using different devices, and with a high demand for information sharing, {{book.project.name}} Authorization Services can help you improve the authorization capabilities of your applications and services by providing:
* Resource protection using fine-grained authorization policies and different access control mechanisms * Resource protection using fine-grained authorization policies and different access control mechanisms