public class AWSS3V4Signer extends AWS4Signer implements Presigner
AWS4Signer.HeaderSigningResult
ALGORITHM, doubleUrlEncode, log, overriddenDate, regionName, serviceName, TERMINATOR
Constructor and Description |
---|
AWSS3V4Signer()
Don't double-url-encode path elements; S3 expects path elements to be
encoded only once in the canonical URI.
|
Modifier and Type | Method and Description |
---|---|
protected String |
calculateContentHash(Request<?> request)
Returns the pre-defined header value and set other necessary headers
if the request needs to be chunk-encoded.
|
void |
presignRequest(Request<?> request,
AWSCredentials credentials,
Date expiration)
Sign the URL using V4, it will compute the signature and add it to the
query string as value of parameter 'X-Amz-Signature'.
|
protected void |
processRequestPayload(Request<?> request,
AWS4Signer.HeaderSigningResult headerSigningResult)
If necessary, creates a chunk-encoding wrapper on the request payload.
|
addHostHeader, addSessionCredentials, computeSignature, extractRegionName, extractServiceName, getCanonicalizedHeaderString, getCanonicalRequest, getDateFromRequest, getDateStamp, getScope, getSignedHeadersString, getStringToSign, getTimeStamp, setRegionName, setServiceName, sign
getBinaryRequestPayload, getBinaryRequestPayloadStream, getBinaryRequestPayloadStreamWithoutQueryParams, getBinaryRequestPayloadWithoutQueryParams, getCanonicalizedEndpoint, getCanonicalizedQueryString, getCanonicalizedQueryString, getCanonicalizedResourcePath, getCanonicalizedResourcePath, getRequestPayload, getRequestPayloadWithoutQueryParams, getSignatureDate, getTimeOffset, hash, hash, hash, newString, sanitizeCredentials, sign, sign, signAndBase64Encode, signAndBase64Encode
public AWSS3V4Signer()
public void presignRequest(Request<?> request, AWSCredentials credentials, Date expiration)
presignRequest
in interface Presigner
request
- The request to sign.credentials
- The credentials to sign it with.expiration
- The time when this presigned URL will expire.protected void processRequestPayload(Request<?> request, AWS4Signer.HeaderSigningResult headerSigningResult)
processRequestPayload
in class AWS4Signer
protected String calculateContentHash(Request<?> request)
calculateContentHash
in class AWS4Signer
Copyright © 2016. All rights reserved.