C# Class Amazon.Runtime.Internal.Auth.AWS4PreSignedUrlSigner

AWS4 protocol signer for Amazon S3 presigned urls.
Inheritance: AWS4Signer
Datei anzeigen Open project: aws/aws-sdk-net Class Usage Examples

Public Methods

Method Description
Sign ( IRequest request, IClientConfig clientConfig, RequestMetrics metrics, string awsAccessKeyId, string awsSecretAccessKey ) : void

Calculates and signs the specified request using the AWS4 signing protocol by using the AWS account credentials given in the method parameters. The resulting signature is added to the request headers as 'Authorization'.

SignRequest ( IRequest request, IClientConfig clientConfig, RequestMetrics metrics, string awsAccessKeyId, string awsSecretAccessKey ) : AWS4SigningResult

Calculates the AWS4 signature for a presigned url.

Parameters passed as part of the resource path should be uri-encoded prior to entry to the signer. Parameters passed in the request.Parameters collection should be not be encoded; encoding will be done for these parameters as part of the construction of the canonical request.

SignRequest ( IRequest request, IClientConfig clientConfig, RequestMetrics metrics, string awsAccessKeyId, string awsSecretAccessKey, string service, string overrideSigningRegion ) : AWS4SigningResult

Calculates the AWS4 signature for a presigned url.

Parameters passed as part of the resource path should be uri-encoded prior to entry to the signer. Parameters passed in the request.Parameters collection should be not be encoded; encoding will be done for these parameters as part of the construction of the canonical request.

Method Details

Sign() public method

Calculates and signs the specified request using the AWS4 signing protocol by using the AWS account credentials given in the method parameters. The resulting signature is added to the request headers as 'Authorization'.
/// If any problems are encountered while signing the request. ///
public Sign ( IRequest request, IClientConfig clientConfig, RequestMetrics metrics, string awsAccessKeyId, string awsSecretAccessKey ) : void
request IRequest /// The request to compute the signature for. Additional headers mandated by the AWS4 protocol /// ('host' and 'x-amz-date') will be added to the request before signing. ///
clientConfig IClientConfig /// Adding supporting data for the service call required by the signer (notably authentication /// region, endpoint and service name). ///
metrics Amazon.Runtime.Internal.Util.RequestMetrics /// Metrics for the request ///
awsAccessKeyId string /// The AWS public key for the account making the service call. ///
awsSecretAccessKey string /// The AWS secret key for the account making the call, in clear text ///
return void

SignRequest() public method

Calculates the AWS4 signature for a presigned url.
Parameters passed as part of the resource path should be uri-encoded prior to entry to the signer. Parameters passed in the request.Parameters collection should be not be encoded; encoding will be done for these parameters as part of the construction of the canonical request.
/// If any problems are encountered while signing the request. ///
public SignRequest ( IRequest request, IClientConfig clientConfig, RequestMetrics metrics, string awsAccessKeyId, string awsSecretAccessKey ) : AWS4SigningResult
request IRequest /// The request to compute the signature for. Additional headers mandated by the AWS4 protocol /// ('host' and 'x-amz-date') will be added to the request before signing. If the Expires parameter /// is present, it is renamed to 'X-Amz-Expires' before signing. ///
clientConfig IClientConfig /// Adding supporting data for the service call required by the signer (notably authentication /// region, endpoint and service name). ///
metrics Amazon.Runtime.Internal.Util.RequestMetrics /// Metrics for the request ///
awsAccessKeyId string /// The AWS public key for the account making the service call. ///
awsSecretAccessKey string /// The AWS secret key for the account making the call, in clear text ///
return AWS4SigningResult

SignRequest() public static method

Calculates the AWS4 signature for a presigned url.
Parameters passed as part of the resource path should be uri-encoded prior to entry to the signer. Parameters passed in the request.Parameters collection should be not be encoded; encoding will be done for these parameters as part of the construction of the canonical request.
/// If any problems are encountered while signing the request. ///
public static SignRequest ( IRequest request, IClientConfig clientConfig, RequestMetrics metrics, string awsAccessKeyId, string awsSecretAccessKey, string service, string overrideSigningRegion ) : AWS4SigningResult
request IRequest /// The request to compute the signature for. Additional headers mandated by the AWS4 protocol /// ('host' and 'x-amz-date') will be added to the request before signing. If the Expires parameter /// is present, it is renamed to 'X-Amz-Expires' before signing. ///
clientConfig IClientConfig /// Adding supporting data for the service call required by the signer (notably authentication /// region, endpoint and service name). ///
metrics Amazon.Runtime.Internal.Util.RequestMetrics /// Metrics for the request ///
awsAccessKeyId string /// The AWS public key for the account making the service call. ///
awsSecretAccessKey string /// The AWS secret key for the account making the call, in clear text ///
service string /// The service to sign for ///
overrideSigningRegion string /// The region to sign to, if null then the region the client is configured for will be used. ///
return AWS4SigningResult