private static String buildCanonicalQueryString(
            HttpServletRequest request) {
        // The parameters are required to be sorted
        List<String> parameters = Collections.list(request.getParameterNames());
        Collections.sort(parameters);
        List<String> queryParameters = new ArrayList<>();

        for (String key : parameters) {
            if (key.equals("X-Amz-Signature")) {
                continue;
            }
            // re-encode keys and values in AWS normalized form
            String value = request.getParameter(key);
            queryParameters.add(AWS_URL_PARAMETER_ESCAPER.escape(key) +
                    "=" + AWS_URL_PARAMETER_ESCAPER.escape(value));
        }
        return Joiner.on("&").join(queryParameters);
    }
Create Amazon V2 signature.  Reference:
http://docs.aws.amazon.com/general/latest/gr/signature-version-2.html
src/main/java/org/gaul/s3proxy/AwsSignature.java