org.jclouds.route53.filters
Class RestAuthentication
java.lang.Object
org.jclouds.route53.filters.RestAuthentication
- All Implemented Interfaces:
- org.jclouds.http.HttpRequestFilter, org.jclouds.rest.RequestSigner
@Singleton
public class RestAuthentication
- extends Object
- implements org.jclouds.http.HttpRequestFilter, org.jclouds.rest.RequestSigner
Signs the Route53 request.
- See Also:
|
Constructor Summary |
RestAuthentication(com.google.common.base.Supplier<org.jclouds.domain.Credentials> creds,
javax.inject.Provider<String> timeStampProvider)
|
|
Method Summary |
String |
createStringToSign(org.jclouds.http.HttpRequest input)
|
org.jclouds.http.HttpRequest |
filter(org.jclouds.http.HttpRequest request)
|
String |
sign(String toSign)
signs toSign using HmacSHA256 initialized with
Credentials.credential. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
RestAuthentication
@Inject
public RestAuthentication(com.google.common.base.Supplier<org.jclouds.domain.Credentials> creds,
javax.inject.Provider<String> timeStampProvider)
filter
public org.jclouds.http.HttpRequest filter(org.jclouds.http.HttpRequest request)
throws org.jclouds.http.HttpException
- Specified by:
filter in interface org.jclouds.http.HttpRequestFilter
- Throws:
org.jclouds.http.HttpException
createStringToSign
public String createStringToSign(org.jclouds.http.HttpRequest input)
- Specified by:
createStringToSign in interface org.jclouds.rest.RequestSigner
sign
public String sign(String toSign)
- signs
toSign using HmacSHA256 initialized with
Credentials.credential.
- Specified by:
sign in interface org.jclouds.rest.RequestSigner
- Parameters:
toSign - string to sign in UTF-8 encoding
- Returns:
- base-64 encoded signature.
Copyright © 2009-2014 The Apache Software Foundation. All Rights Reserved.