Starting an AWS Instance with the API, AUTHPARAMS

I am trying to run AMI using

https://ec2.amazonaws.com/ ?Action=StartInstances &InstanceId.1=i-10a64379 &AUTHPARAMS 

Like documentadion, here , but I can not find what AUTHPARAMS refers to.
Thanks

+4
source share
2 answers

As Steffen notes, the API is much easier to use than direct REST calls (especially the reasonably new command line interface - which is much lighter and possibly easier to use as a result of JSON integration than the original command line tools for by-products)

... but if you decide:

It is a bit like documentation, but the following links seem to lead us to the answer:

1) a high-level description of "AUTHPARAMS" (as is often mentioned in the API documentation).

Authparams

Parameters required for authentication Conditional request. Contains:

AWSAccessKeyID

SignatureVersion

Mark

Signature

Default: None

Requires: Conditional

2) a step by step parameters needed for a REST request:

3) a detailed outline of the method for obtaining a "signature for" AUTHPARAMS "

This is an example in the documentation (I added new lines to make reading easier)

 https://elasticmapreduce.amazonaws.com? AWSAccessKeyId=AKIAIOSFODNN7EXAMPLE& Action=DescribeJobFlows& SignatureMethod=HmacSHA256& SignatureVersion=2& Timestamp=2011-10-03T15%3A19%3A30& Version=2009-03-31& Signature=i91nKc4PWAt0JJIdXwz9HxZCJDdiy6cf%2FMj6vPxyYIs%3D 

4) In addition, there is some general information about signatures

+4
source

First of all, to interact with the Amazon EC2 API , I highly recommend using one of the available SDKs , if possible - it will make your life much easier, especially when it also interacts with any of many other AWS Products and Solutions over time, because the SDK facilitate the tedious template code for you, and harmonize the use of the cross-service APIs in general and the authentication process you are asking about in particular.

Now, if you really want / need to handle authentication yourself, you will find the required information in the Query API Authentication , which refers to the Signature Version 2 Signing Process , in turn (the version of the signature changes over time, which is one of the themes drawn, for example, from the SDK).

0
source

Source: https://habr.com/ru/post/1479058/


All Articles