public class HmacAuthorizor extends Object
Authorization
objects based on HMAC values in HTTP Authorization headers.Constructor and Description |
---|
HmacAuthorizor(KeyTable table) |
Modifier and Type | Method and Description |
---|---|
HmacSignature |
initSignature(String auth,
String method,
String host,
String path,
Map<String,? extends Iterable<String>> params)
Creates an initial signature object based on the request and Authorization header value.
|
Authorization |
validate(javax.servlet.http.HttpServletRequest request)
Validates a request based on HTTP Authorization header.
|
public HmacAuthorizor(KeyTable table)
table
- where to look up keyId => keypublic HmacSignature initSignature(String auth, String method, String host, String path, Map<String,? extends Iterable<String>> params)
auth
- method
- host
- path
- params
- null
.public Authorization validate(javax.servlet.http.HttpServletRequest request)
request
- the incoming requestAuthorization
objectCopyright © 2017. All rights reserved.