protected static class AbstractHttpServer.SimpleSecurityContext extends Object implements javax.ws.rs.core.SecurityContext
| Modifier | Constructor and Description |
|---|---|
protected |
SimpleSecurityContext(String sAuthScheme, Principal principal, boolean fSecure)
Create a new SimpleSecurityContext instance.
|
| Modifier and Type | Method and Description |
|---|---|
String |
getAuthenticationScheme()
Return the string value of the authentication scheme used to protect the resource.
|
Principal |
getUserPrincipal()
Return a Principal object containing the name of the current authenticated user.
|
boolean |
isSecure()
Return a boolean indicating whether this request was made using a secure channel, such as HTTPS.
|
boolean |
isUserInRole(String sRole)
Return a boolean indicating whether the authenticated user is included in the specified logical "role".
|
protected SimpleSecurityContext(String sAuthScheme, Principal principal, boolean fSecure)
sAuthScheme - string value of the authentication scheme used to protect resourcesprincipal - the Principal containing the name of the current authenticated userfSecure - a boolean value indicating whether a request was made using a secure channel, such as HTTPSpublic String getAuthenticationScheme()
getAuthenticationScheme in interface javax.ws.rs.core.SecurityContextpublic Principal getUserPrincipal()
getUserPrincipal in interface javax.ws.rs.core.SecurityContextpublic boolean isSecure()
isSecure in interface javax.ws.rs.core.SecurityContextpublic boolean isUserInRole(String sRole)
isUserInRole in interface javax.ws.rs.core.SecurityContextsRole - the name of the role