Examples of AWSS3V4Signer


Examples of com.amazonaws.services.s3.internal.AWSS3V4Signer

        Signer signer = getSigner();

        if (upgradeToSigV4() && !(signer instanceof AWSS3V4Signer)){

            AWSS3V4Signer v4Signer = new AWSS3V4Signer();

            // Always set the service name; if the user has overridden it via
            // setEndpoint(String, String, String), this will return the right
            // value. Otherwise it will return "s3", which is an appropriate
            // default.
            v4Signer.setServiceName(getServiceNameIntern());

            // If the user has set an authentication region override, pass it
            // to the signer. Otherwise leave it null - the signer will parse
            // region from the request endpoint.

            String regionOverride = getSignerRegionOverride();
            if (regionOverride == null) {
                if (!hasExplicitRegion) {
                    throw new AmazonClientException(
                        "Signature Version 4 requires knowing the region of "
                        + "the bucket you're trying to access. You can "
                        + "configure a region by calling AmazonS3Client."
                        + "setRegion(Region) or AmazonS3Client.setEndpoint("
                        + "String) with a region-specific endpoint such as "
                        + "\"s3-us-west-2.amazonaws.com\".");
                }
            } else {
                v4Signer.setRegionName(regionOverride);
            }

            return v4Signer;

        }
View Full Code Here

Examples of com.amazonaws.services.s3.internal.AWSS3V4Signer

        Signer signer = getSigner();

        if (upgradeToSigV4() && !(signer instanceof AWSS3V4Signer)){

            AWSS3V4Signer v4Signer = new AWSS3V4Signer();

            // Always set the service name; if the user has overridden it via
            // setEndpoint(String, String, String), this will return the right
            // value. Otherwise it will return "s3", which is an appropriate
            // default.
            v4Signer.setServiceName(getServiceNameIntern());

            // If the user has set an authentication region override, pass it
            // to the signer. Otherwise leave it null - the signer will parse
            // region from the request endpoint.

            String regionOverride = getSignerRegionOverride();
            if (regionOverride == null) {
                if (!hasExplicitRegion) {
                    throw new AmazonClientException(
                        "Signature Version 4 requires knowing the region of "
                        + "the bucket you're trying to access. You can "
                        + "configure a region by calling AmazonS3Client."
                        + "setRegion(Region) or AmazonS3Client.setEndpoint("
                        + "String) with a region-specific endpoint such as "
                        + "\"s3-us-west-2.amazonaws.com\".");
                }
            } else {
                v4Signer.setRegionName(regionOverride);
            }

            return v4Signer;

        }
View Full Code Here

Examples of com.amazonaws.services.s3.internal.AWSS3V4Signer

        Signer signer = getSigner();

        if (upgradeToSigV4() && !(signer instanceof AWSS3V4Signer)){

            AWSS3V4Signer v4Signer = new AWSS3V4Signer();

            // Always set the service name; if the user has overridden it via
            // setEndpoint(String, String, String), this will return the right
            // value. Otherwise it will return "s3", which is an appropriate
            // default.
            v4Signer.setServiceName(getServiceNameIntern());

            // If the user has set an authentication region override, pass it
            // to the signer. Otherwise leave it null - the signer will parse
            // region from the request endpoint.

            String regionOverride = getSignerRegionOverride();
            if (regionOverride == null) {
                if (!hasExplicitRegion) {
                    throw new AmazonClientException(
                        "Signature Version 4 requires knowing the region of "
                        + "the bucket you're trying to access. You can "
                        + "configure a region by calling AmazonS3Client."
                        + "setRegion(Region) or AmazonS3Client.setEndpoint("
                        + "String) with a region-specific endpoint such as "
                        + "\"s3-us-west-2.amazonaws.com\".");
                }
            } else {
                v4Signer.setRegionName(regionOverride);
            }

            return v4Signer;

        }
View Full Code Here

Examples of com.amazonaws.services.s3.internal.AWSS3V4Signer

        Signer signer = getSigner();

        if (upgradeToSigV4() && !(signer instanceof AWSS3V4Signer)){

            AWSS3V4Signer v4Signer = new AWSS3V4Signer();

            // Always set the service name; if the user has overridden it via
            // setEndpoint(String, String, String), this will return the right
            // value. Otherwise it will return "s3", which is an appropriate
            // default.
            v4Signer.setServiceName(getServiceNameIntern());

            // If the user has set an authentication region override, pass it
            // to the signer. Otherwise leave it null - the signer will parse
            // region from the request endpoint.

            String regionOverride = getSignerRegionOverride();
            if (regionOverride == null) {
                if (!hasExplicitRegion) {
                    throw new AmazonClientException(
                        "Signature Version 4 requires knowing the region of "
                        + "the bucket you're trying to access. You can "
                        + "configure a region by calling AmazonS3Client."
                        + "setRegion(Region) or AmazonS3Client.setEndpoint("
                        + "String) with a region-specific endpoint such as "
                        + "\"s3-us-west-2.amazonaws.com\".");
                }
            } else {
                v4Signer.setRegionName(regionOverride);
            }

            return v4Signer;

        }
View Full Code Here

Examples of com.amazonaws.services.s3.internal.AWSS3V4Signer

        Signer signer = getSigner();

        if (upgradeToSigV4() && !(signer instanceof AWSS3V4Signer)){

            AWSS3V4Signer v4Signer = new AWSS3V4Signer();

            // Always set the service name; if the user has overridden it via
            // setEndpoint(String, String, String), this will return the right
            // value. Otherwise it will return "s3", which is an appropriate
            // default.
            v4Signer.setServiceName(getServiceNameIntern());

            // If the user has set an authentication region override, pass it
            // to the signer. Otherwise leave it null - the signer will parse
            // region from the request endpoint.

            String regionOverride = getSignerRegionOverride();
            if (regionOverride == null) {
                if (!hasExplicitRegion) {
                    throw new AmazonClientException(
                        "Signature Version 4 requires knowing the region of "
                        + "the bucket you're trying to access. You can "
                        + "configure a region by calling AmazonS3Client."
                        + "setRegion(Region) or AmazonS3Client.setEndpoint("
                        + "String) with a region-specific endpoint such as "
                        + "\"s3-us-west-2.amazonaws.com\".");
                }
            } else {
                v4Signer.setRegionName(regionOverride);
            }

            return v4Signer;

        }
View Full Code Here

Examples of com.amazonaws.services.s3.internal.AWSS3V4Signer

        final boolean sigv4ForGetRequests = ((originalRequest instanceof GetObjectRequest) && !isStandardEnpoint);

        if ((upgradeToSigV4() && !(signer instanceof AWSS3V4Signer))
                || (sigv4ForGetRequests)) {

            AWSS3V4Signer v4Signer = new AWSS3V4Signer();

            // Always set the service name; if the user has overridden it via
            // setEndpoint(String, String, String), this will return the right
            // value. Otherwise it will return "s3", which is an appropriate
            // default.
            v4Signer.setServiceName(getServiceNameIntern());

            // If the user has set an authentication region override, pass it
            // to the signer. Otherwise leave it null - the signer will parse
            // region from the request endpoint.

            String regionOverride = getSignerRegionOverride();
            if (regionOverride == null) {
                if (!hasExplicitRegion) {
                    throw new AmazonClientException(
                        "Signature Version 4 requires knowing the region of "
                        + "the bucket you're trying to access. You can "
                        + "configure a region by calling AmazonS3Client."
                        + "setRegion(Region) or AmazonS3Client.setEndpoint("
                        + "String) with a region-specific endpoint such as "
                        + "\"s3-us-west-2.amazonaws.com\".");
                }
            } else {
                v4Signer.setRegionName(regionOverride);
            }

            return v4Signer;

        }
View Full Code Here

Examples of com.amazonaws.services.s3.internal.AWSS3V4Signer

        Signer signer = getSigner();

        if (upgradeToSigV4() && !(signer instanceof AWSS3V4Signer)){

            AWSS3V4Signer v4Signer = new AWSS3V4Signer();

            // Always set the service name; if the user has overridden it via
            // setEndpoint(String, String, String), this will return the right
            // value. Otherwise it will return "s3", which is an appropriate
            // default.
            v4Signer.setServiceName(getServiceNameIntern());

            // If the user has set an authentication region override, pass it
            // to the signer. Otherwise leave it null - the signer will parse
            // region from the request endpoint.

            String regionOverride = getSignerRegionOverride();
            if (regionOverride == null) {
                if (!hasExplicitRegion) {
                    throw new AmazonClientException(
                        "Signature Version 4 requires knowing the region of "
                        + "the bucket you're trying to access. You can "
                        + "configure a region by calling AmazonS3Client."
                        + "setRegion(Region) or AmazonS3Client.setEndpoint("
                        + "String) with a region-specific endpoint such as "
                        + "\"s3-us-west-2.amazonaws.com\".");
                }
            } else {
                v4Signer.setRegionName(regionOverride);
            }

            return v4Signer;

        }
View Full Code Here

Examples of com.amazonaws.services.s3.internal.AWSS3V4Signer

        Signer signer = getSigner();

        if (upgradeToSigV4() && !(signer instanceof AWSS3V4Signer)){

            AWSS3V4Signer v4Signer = new AWSS3V4Signer();

            // Always set the service name; if the user has overridden it via
            // setEndpoint(String, String, String), this will return the right
            // value. Otherwise it will return "s3", which is an appropriate
            // default.
            v4Signer.setServiceName(getServiceNameIntern());

            // If the user has set an authentication region override, pass it
            // to the signer. Otherwise leave it null - the signer will parse
            // region from the request endpoint.

            String regionOverride = getSignerRegionOverride();
            if (regionOverride == null) {
                if (!hasExplicitRegion) {
                    throw new AmazonClientException(
                        "Signature Version 4 requires knowing the region of "
                        + "the bucket you're trying to access. You can "
                        + "configure a region by calling AmazonS3Client."
                        + "setRegion(Region) or AmazonS3Client.setEndpoint("
                        + "String) with a region-specific endpoint such as "
                        + "\"s3-us-west-2.amazonaws.com\".");
                }
            } else {
                v4Signer.setRegionName(regionOverride);
            }

            return v4Signer;

        }
View Full Code Here

Examples of com.amazonaws.services.s3.internal.AWSS3V4Signer

        Signer signer = getSigner();

        if (upgradeToSigV4() && !(signer instanceof AWSS3V4Signer)){

            AWSS3V4Signer v4Signer = new AWSS3V4Signer();

            // Always set the service name; if the user has overridden it via
            // setEndpoint(String, String, String), this will return the right
            // value. Otherwise it will return "s3", which is an appropriate
            // default.
            v4Signer.setServiceName(getServiceNameIntern());

            // If the user has set an authentication region override, pass it
            // to the signer. Otherwise leave it null - the signer will parse
            // region from the request endpoint.

            String regionOverride = getSignerRegionOverride();
            if (regionOverride == null) {
                if (!hasExplicitRegion) {
                    throw new AmazonClientException(
                        "Signature Version 4 requires knowing the region of "
                        + "the bucket you're trying to access. You can "
                        + "configure a region by calling AmazonS3Client."
                        + "setRegion(Region) or AmazonS3Client.setEndpoint("
                        + "String) with a region-specific endpoint such as "
                        + "\"s3-us-west-2.amazonaws.com\".");
                }
            } else {
                v4Signer.setRegionName(regionOverride);
            }

            return v4Signer;

        }
View Full Code Here

Examples of com.amazonaws.services.s3.internal.AWSS3V4Signer

        Signer signer = getSigner();

        if (upgradeToSigV4() && !(signer instanceof AWSS3V4Signer)){

            AWSS3V4Signer v4Signer = new AWSS3V4Signer();

            // Always set the service name; if the user has overridden it via
            // setEndpoint(String, String, String), this will return the right
            // value. Otherwise it will return "s3", which is an appropriate
            // default.
            v4Signer.setServiceName(getServiceNameIntern());

            // If the user has set an authentication region override, pass it
            // to the signer. Otherwise leave it null - the signer will parse
            // region from the request endpoint.

            String regionOverride = getSignerRegionOverride();
            if (regionOverride == null) {
                if (!hasExplicitRegion) {
                    throw new AmazonClientException(
                        "Signature Version 4 requires knowing the region of "
                        + "the bucket you're trying to access. You can "
                        + "configure a region by calling AmazonS3Client."
                        + "setRegion(Region) or AmazonS3Client.setEndpoint("
                        + "String) with a region-specific endpoint such as "
                        + "\"s3-us-west-2.amazonaws.com\".");
                }
            } else {
                v4Signer.setRegionName(regionOverride);
            }

            return v4Signer;

        }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.