question

Nils avatar image
Nils asked Erick Ramirez answered

Getting AuthorizationQueryParametersError when downloading my Astra secure connect bundle

Hi! Got this error after running "curl -L ....." command in gitpod -

[5:58 PM]<Error><Code>AuthorizationQueryParametersError</Code><Message>Query-string authentication version 4 requires the X-Amz-Algorithm, X-Amz-Credential, X-Amz-Signature, X-Amz-Date, X-Amz-SignedHeaders, and X-Amz-Expires parameters.</Message><RequestId>E007AF0E5EEAAC90</RequestId><HostId>qt/0i8tHPsGm/1xzhjWBw7RIMlT+790+krwYXp8cyn0eGYivLO46M+kz37i+w+HO7+DWNukMr/M=</HostId></Error>

I followed all the instructions so what am I doing wrong ?

astra
10 |1000

Up to 8 attachments (including images) can be used with a maximum of 1.0 MiB each and 10.0 MiB total.

1 Answer

Erick Ramirez avatar image
Erick Ramirez answered

As the error suggests, the API request to download the secure bundle requires several AWS X-Amz-* parameters such as X-Amz-Algorithm and X-Amz-Credential for the request to work:

Query-string authentication version 4 requires the X-Amz-Algorithm, X-Amz-Credential, X-Amz-Signature, X-Amz-Date, X-Amz-SignedHeaders, and X-Amz-Expires parameters.

This indicates that you didn't enclose the URL to your secure bundle in double quotes (") as it states in the CRUD workshop instructions:

$ curl -L "<your bundle link here>" > /workspace/workshop-crud-with-python-and-node/crud-python/creds.zip

For this example URL:

https://datastax-cluster-config-prod.s3.us-east-2.amazonaws.com/362f3f09-c535-443c-ac2b-24460ed92e4f/secure-connect-gocqltest.zip?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIA2AIQRQ76TUCOHUQ4%2F20210112%2Fus-east-2%2Fs3%2Faws4_request&X-Amz-Date=20210112T060755Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=89e916d2ef15461b24e4662b267b7517322557e8b761c2c9d6e51eab042a6573

the format for the curl command is:

$ curl -L "https://datastax-cluster-config-prod.s3.us-east-2.amazonaws.com/362f3f09-c535-443c-ac2b-24460ed92e4f/secure-connect-gocqltest.zip?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIA2AIQRQ76TUCOHUQ4%2F20210112%2Fus-east-2%2Fs3%2Faws4_request&X-Amz-Date=20210112T060755Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=89e916d2ef15461b24e4662b267b7517322557e8b761c2c9d6e51eab042a6573" > /workspace/workshop-crud-with-python-and-node/crud-python/creds.zip

Note that the URL to your secure bundle is only valid for 5 minutes (X-Amz-Expires=300). If you don't use the URL immediately, it will expire and you will need to reload the Astra dashboard to generate a new URL. Cheers!

Share
10 |1000

Up to 8 attachments (including images) can be used with a maximum of 1.0 MiB each and 10.0 MiB total.