aboutsummaryrefslogtreecommitdiffhomepage
path: root/vendor/github.com/aws/aws-sdk-go/aws
diff options
context:
space:
mode:
Diffstat (limited to 'vendor/github.com/aws/aws-sdk-go/aws')
-rw-r--r--vendor/github.com/aws/aws-sdk-go/aws/awserr/error.go23
-rw-r--r--vendor/github.com/aws/aws-sdk-go/aws/awserr/types.go31
-rw-r--r--vendor/github.com/aws/aws-sdk-go/aws/awsutil/path_value.go11
-rw-r--r--vendor/github.com/aws/aws-sdk-go/aws/client/logger.go12
-rw-r--r--vendor/github.com/aws/aws-sdk-go/aws/credentials/credentials.go9
-rw-r--r--vendor/github.com/aws/aws-sdk-go/aws/credentials/ec2rolecreds/ec2_role_provider.go6
-rw-r--r--vendor/github.com/aws/aws-sdk-go/aws/credentials/endpointcreds/provider.go15
-rw-r--r--vendor/github.com/aws/aws-sdk-go/aws/credentials/stscreds/assume_role_provider.go3
-rw-r--r--vendor/github.com/aws/aws-sdk-go/aws/credentials/stscreds/web_identity_provider.go97
-rw-r--r--vendor/github.com/aws/aws-sdk-go/aws/csm/doc.go65
-rw-r--r--vendor/github.com/aws/aws-sdk-go/aws/csm/enable.go34
-rw-r--r--vendor/github.com/aws/aws-sdk-go/aws/csm/reporter.go29
-rw-r--r--vendor/github.com/aws/aws-sdk-go/aws/ec2metadata/api.go4
-rw-r--r--vendor/github.com/aws/aws-sdk-go/aws/ec2metadata/service.go4
-rw-r--r--vendor/github.com/aws/aws-sdk-go/aws/endpoints/defaults.go650
-rw-r--r--vendor/github.com/aws/aws-sdk-go/aws/endpoints/dep_service_ids.go2
-rw-r--r--vendor/github.com/aws/aws-sdk-go/aws/request/connection_reset_error.go17
-rw-r--r--vendor/github.com/aws/aws-sdk-go/aws/request/connection_reset_error_other.go11
-rw-r--r--vendor/github.com/aws/aws-sdk-go/aws/request/handlers.go45
-rw-r--r--vendor/github.com/aws/aws-sdk-go/aws/request/offset_reader.go15
-rw-r--r--vendor/github.com/aws/aws-sdk-go/aws/request/request.go92
-rw-r--r--vendor/github.com/aws/aws-sdk-go/aws/request/request_1_8.go5
-rw-r--r--vendor/github.com/aws/aws-sdk-go/aws/request/request_pagination.go2
-rw-r--r--vendor/github.com/aws/aws-sdk-go/aws/session/credentials.go258
-rw-r--r--vendor/github.com/aws/aws-sdk-go/aws/session/env_config.go59
-rw-r--r--vendor/github.com/aws/aws-sdk-go/aws/session/session.go226
-rw-r--r--vendor/github.com/aws/aws-sdk-go/aws/session/shared_config.go339
-rw-r--r--vendor/github.com/aws/aws-sdk-go/aws/signer/v4/v4.go20
-rw-r--r--vendor/github.com/aws/aws-sdk-go/aws/types.go20
-rw-r--r--vendor/github.com/aws/aws-sdk-go/aws/version.go2
30 files changed, 1643 insertions, 463 deletions
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/awserr/error.go b/vendor/github.com/aws/aws-sdk-go/aws/awserr/error.go
index 56fdfc2..99849c0 100644
--- a/vendor/github.com/aws/aws-sdk-go/aws/awserr/error.go
+++ b/vendor/github.com/aws/aws-sdk-go/aws/awserr/error.go
@@ -138,8 +138,27 @@ type RequestFailure interface {
138 RequestID() string 138 RequestID() string
139} 139}
140 140
141// NewRequestFailure returns a new request error wrapper for the given Error 141// NewRequestFailure returns a wrapped error with additional information for
142// provided. 142// request status code, and service requestID.
143//
144// Should be used to wrap all request which involve service requests. Even if
145// the request failed without a service response, but had an HTTP status code
146// that may be meaningful.
143func NewRequestFailure(err Error, statusCode int, reqID string) RequestFailure { 147func NewRequestFailure(err Error, statusCode int, reqID string) RequestFailure {
144 return newRequestError(err, statusCode, reqID) 148 return newRequestError(err, statusCode, reqID)
145} 149}
150
151// UnmarshalError provides the interface for the SDK failing to unmarshal data.
152type UnmarshalError interface {
153 awsError
154 Bytes() []byte
155}
156
157// NewUnmarshalError returns an initialized UnmarshalError error wrapper adding
158// the bytes that fail to unmarshal to the error.
159func NewUnmarshalError(err error, msg string, bytes []byte) UnmarshalError {
160 return &unmarshalError{
161 awsError: New("UnmarshalError", msg, err),
162 bytes: bytes,
163 }
164}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/awserr/types.go b/vendor/github.com/aws/aws-sdk-go/aws/awserr/types.go
index 0202a00..9cf7eaf 100644
--- a/vendor/github.com/aws/aws-sdk-go/aws/awserr/types.go
+++ b/vendor/github.com/aws/aws-sdk-go/aws/awserr/types.go
@@ -1,6 +1,9 @@
1package awserr 1package awserr
2 2
3import "fmt" 3import (
4 "encoding/hex"
5 "fmt"
6)
4 7
5// SprintError returns a string of the formatted error code. 8// SprintError returns a string of the formatted error code.
6// 9//
@@ -119,6 +122,7 @@ type requestError struct {
119 awsError 122 awsError
120 statusCode int 123 statusCode int
121 requestID string 124 requestID string
125 bytes []byte
122} 126}
123 127
124// newRequestError returns a wrapped error with additional information for 128// newRequestError returns a wrapped error with additional information for
@@ -170,6 +174,29 @@ func (r requestError) OrigErrs() []error {
170 return []error{r.OrigErr()} 174 return []error{r.OrigErr()}
171} 175}
172 176
177type unmarshalError struct {
178 awsError
179 bytes []byte
180}
181
182// Error returns the string representation of the error.
183// Satisfies the error interface.
184func (e unmarshalError) Error() string {
185 extra := hex.Dump(e.bytes)
186 return SprintError(e.Code(), e.Message(), extra, e.OrigErr())
187}
188
189// String returns the string representation of the error.
190// Alias for Error to satisfy the stringer interface.
191func (e unmarshalError) String() string {
192 return e.Error()
193}
194
195// Bytes returns the bytes that failed to unmarshal.
196func (e unmarshalError) Bytes() []byte {
197 return e.bytes
198}
199
173// An error list that satisfies the golang interface 200// An error list that satisfies the golang interface
174type errorList []error 201type errorList []error
175 202
@@ -181,7 +208,7 @@ func (e errorList) Error() string {
181 // How do we want to handle the array size being zero 208 // How do we want to handle the array size being zero
182 if size := len(e); size > 0 { 209 if size := len(e); size > 0 {
183 for i := 0; i < size; i++ { 210 for i := 0; i < size; i++ {
184 msg += fmt.Sprintf("%s", e[i].Error()) 211 msg += e[i].Error()
185 // We check the next index to see if it is within the slice. 212 // We check the next index to see if it is within the slice.
186 // If it is, then we append a newline. We do this, because unit tests 213 // If it is, then we append a newline. We do this, because unit tests
187 // could be broken with the additional '\n' 214 // could be broken with the additional '\n'
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/awsutil/path_value.go b/vendor/github.com/aws/aws-sdk-go/aws/awsutil/path_value.go
index 11c52c3..285e54d 100644
--- a/vendor/github.com/aws/aws-sdk-go/aws/awsutil/path_value.go
+++ b/vendor/github.com/aws/aws-sdk-go/aws/awsutil/path_value.go
@@ -185,13 +185,12 @@ func ValuesAtPath(i interface{}, path string) ([]interface{}, error) {
185// SetValueAtPath sets a value at the case insensitive lexical path inside 185// SetValueAtPath sets a value at the case insensitive lexical path inside
186// of a structure. 186// of a structure.
187func SetValueAtPath(i interface{}, path string, v interface{}) { 187func SetValueAtPath(i interface{}, path string, v interface{}) {
188 if rvals := rValuesAtPath(i, path, true, false, v == nil); rvals != nil { 188 rvals := rValuesAtPath(i, path, true, false, v == nil)
189 for _, rval := range rvals { 189 for _, rval := range rvals {
190 if rval.Kind() == reflect.Ptr && rval.IsNil() { 190 if rval.Kind() == reflect.Ptr && rval.IsNil() {
191 continue 191 continue
192 }
193 setValue(rval, v)
194 } 192 }
193 setValue(rval, v)
195 } 194 }
196} 195}
197 196
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/client/logger.go b/vendor/github.com/aws/aws-sdk-go/aws/client/logger.go
index 7b5e127..8958c32 100644
--- a/vendor/github.com/aws/aws-sdk-go/aws/client/logger.go
+++ b/vendor/github.com/aws/aws-sdk-go/aws/client/logger.go
@@ -67,10 +67,14 @@ func logRequest(r *request.Request) {
67 if !bodySeekable { 67 if !bodySeekable {
68 r.SetReaderBody(aws.ReadSeekCloser(r.HTTPRequest.Body)) 68 r.SetReaderBody(aws.ReadSeekCloser(r.HTTPRequest.Body))
69 } 69 }
70 // Reset the request body because dumpRequest will re-wrap the r.HTTPRequest's 70 // Reset the request body because dumpRequest will re-wrap the
71 // Body as a NoOpCloser and will not be reset after read by the HTTP 71 // r.HTTPRequest's Body as a NoOpCloser and will not be reset after
72 // client reader. 72 // read by the HTTP client reader.
73 r.ResetBody() 73 if err := r.Error; err != nil {
74 r.Config.Logger.Log(fmt.Sprintf(logReqErrMsg,
75 r.ClientInfo.ServiceName, r.Operation.Name, err))
76 return
77 }
74 } 78 }
75 79
76 r.Config.Logger.Log(fmt.Sprintf(logReqMsg, 80 r.Config.Logger.Log(fmt.Sprintf(logReqMsg,
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/credentials/credentials.go b/vendor/github.com/aws/aws-sdk-go/aws/credentials/credentials.go
index 894bbc7..4af5921 100644
--- a/vendor/github.com/aws/aws-sdk-go/aws/credentials/credentials.go
+++ b/vendor/github.com/aws/aws-sdk-go/aws/credentials/credentials.go
@@ -50,9 +50,10 @@ package credentials
50 50
51import ( 51import (
52 "fmt" 52 "fmt"
53 "github.com/aws/aws-sdk-go/aws/awserr"
54 "sync" 53 "sync"
55 "time" 54 "time"
55
56 "github.com/aws/aws-sdk-go/aws/awserr"
56) 57)
57 58
58// AnonymousCredentials is an empty Credential object that can be used as 59// AnonymousCredentials is an empty Credential object that can be used as
@@ -83,6 +84,12 @@ type Value struct {
83 ProviderName string 84 ProviderName string
84} 85}
85 86
87// HasKeys returns if the credentials Value has both AccessKeyID and
88// SecretAccessKey value set.
89func (v Value) HasKeys() bool {
90 return len(v.AccessKeyID) != 0 && len(v.SecretAccessKey) != 0
91}
92
86// A Provider is the interface for any component which will provide credentials 93// A Provider is the interface for any component which will provide credentials
87// Value. A provider is required to manage its own Expired state, and what to 94// Value. A provider is required to manage its own Expired state, and what to
88// be expired means. 95// be expired means.
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/credentials/ec2rolecreds/ec2_role_provider.go b/vendor/github.com/aws/aws-sdk-go/aws/credentials/ec2rolecreds/ec2_role_provider.go
index 0ed791b..43d4ed3 100644
--- a/vendor/github.com/aws/aws-sdk-go/aws/credentials/ec2rolecreds/ec2_role_provider.go
+++ b/vendor/github.com/aws/aws-sdk-go/aws/credentials/ec2rolecreds/ec2_role_provider.go
@@ -11,6 +11,7 @@ import (
11 "github.com/aws/aws-sdk-go/aws/client" 11 "github.com/aws/aws-sdk-go/aws/client"
12 "github.com/aws/aws-sdk-go/aws/credentials" 12 "github.com/aws/aws-sdk-go/aws/credentials"
13 "github.com/aws/aws-sdk-go/aws/ec2metadata" 13 "github.com/aws/aws-sdk-go/aws/ec2metadata"
14 "github.com/aws/aws-sdk-go/aws/request"
14 "github.com/aws/aws-sdk-go/internal/sdkuri" 15 "github.com/aws/aws-sdk-go/internal/sdkuri"
15) 16)
16 17
@@ -142,7 +143,8 @@ func requestCredList(client *ec2metadata.EC2Metadata) ([]string, error) {
142 } 143 }
143 144
144 if err := s.Err(); err != nil { 145 if err := s.Err(); err != nil {
145 return nil, awserr.New("SerializationError", "failed to read EC2 instance role from metadata service", err) 146 return nil, awserr.New(request.ErrCodeSerialization,
147 "failed to read EC2 instance role from metadata service", err)
146 } 148 }
147 149
148 return credsList, nil 150 return credsList, nil
@@ -164,7 +166,7 @@ func requestCred(client *ec2metadata.EC2Metadata, credsName string) (ec2RoleCred
164 respCreds := ec2RoleCredRespBody{} 166 respCreds := ec2RoleCredRespBody{}
165 if err := json.NewDecoder(strings.NewReader(resp)).Decode(&respCreds); err != nil { 167 if err := json.NewDecoder(strings.NewReader(resp)).Decode(&respCreds); err != nil {
166 return ec2RoleCredRespBody{}, 168 return ec2RoleCredRespBody{},
167 awserr.New("SerializationError", 169 awserr.New(request.ErrCodeSerialization,
168 fmt.Sprintf("failed to decode %s EC2 instance role credentials", credsName), 170 fmt.Sprintf("failed to decode %s EC2 instance role credentials", credsName),
169 err) 171 err)
170 } 172 }
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/credentials/endpointcreds/provider.go b/vendor/github.com/aws/aws-sdk-go/aws/credentials/endpointcreds/provider.go
index ace5131..c2b2c5d 100644
--- a/vendor/github.com/aws/aws-sdk-go/aws/credentials/endpointcreds/provider.go
+++ b/vendor/github.com/aws/aws-sdk-go/aws/credentials/endpointcreds/provider.go
@@ -39,6 +39,7 @@ import (
39 "github.com/aws/aws-sdk-go/aws/client/metadata" 39 "github.com/aws/aws-sdk-go/aws/client/metadata"
40 "github.com/aws/aws-sdk-go/aws/credentials" 40 "github.com/aws/aws-sdk-go/aws/credentials"
41 "github.com/aws/aws-sdk-go/aws/request" 41 "github.com/aws/aws-sdk-go/aws/request"
42 "github.com/aws/aws-sdk-go/private/protocol/json/jsonutil"
42) 43)
43 44
44// ProviderName is the name of the credentials provider. 45// ProviderName is the name of the credentials provider.
@@ -174,7 +175,7 @@ func unmarshalHandler(r *request.Request) {
174 175
175 out := r.Data.(*getCredentialsOutput) 176 out := r.Data.(*getCredentialsOutput)
176 if err := json.NewDecoder(r.HTTPResponse.Body).Decode(&out); err != nil { 177 if err := json.NewDecoder(r.HTTPResponse.Body).Decode(&out); err != nil {
177 r.Error = awserr.New("SerializationError", 178 r.Error = awserr.New(request.ErrCodeSerialization,
178 "failed to decode endpoint credentials", 179 "failed to decode endpoint credentials",
179 err, 180 err,
180 ) 181 )
@@ -185,11 +186,15 @@ func unmarshalError(r *request.Request) {
185 defer r.HTTPResponse.Body.Close() 186 defer r.HTTPResponse.Body.Close()
186 187
187 var errOut errorOutput 188 var errOut errorOutput
188 if err := json.NewDecoder(r.HTTPResponse.Body).Decode(&errOut); err != nil { 189 err := jsonutil.UnmarshalJSONError(&errOut, r.HTTPResponse.Body)
189 r.Error = awserr.New("SerializationError", 190 if err != nil {
190 "failed to decode endpoint credentials", 191 r.Error = awserr.NewRequestFailure(
191 err, 192 awserr.New(request.ErrCodeSerialization,
193 "failed to decode error message", err),
194 r.HTTPResponse.StatusCode,
195 r.RequestID,
192 ) 196 )
197 return
193 } 198 }
194 199
195 // Response body format is not consistent between metadata endpoints. 200 // Response body format is not consistent between metadata endpoints.
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/credentials/stscreds/assume_role_provider.go b/vendor/github.com/aws/aws-sdk-go/aws/credentials/stscreds/assume_role_provider.go
index b6dbfd2..2e528d1 100644
--- a/vendor/github.com/aws/aws-sdk-go/aws/credentials/stscreds/assume_role_provider.go
+++ b/vendor/github.com/aws/aws-sdk-go/aws/credentials/stscreds/assume_role_provider.go
@@ -200,7 +200,7 @@ type AssumeRoleProvider struct {
200 // by a random percentage between 0 and MaxJitterFraction. MaxJitterFrac must 200 // by a random percentage between 0 and MaxJitterFraction. MaxJitterFrac must
201 // have a value between 0 and 1. Any other value may lead to expected behavior. 201 // have a value between 0 and 1. Any other value may lead to expected behavior.
202 // With a MaxJitterFrac value of 0, default) will no jitter will be used. 202 // With a MaxJitterFrac value of 0, default) will no jitter will be used.
203 // 203 //
204 // For example, with a Duration of 30m and a MaxJitterFrac of 0.1, the 204 // For example, with a Duration of 30m and a MaxJitterFrac of 0.1, the
205 // AssumeRole call will be made with an arbitrary Duration between 27m and 205 // AssumeRole call will be made with an arbitrary Duration between 27m and
206 // 30m. 206 // 30m.
@@ -258,7 +258,6 @@ func NewCredentialsWithClient(svc AssumeRoler, roleARN string, options ...func(*
258 258
259// Retrieve generates a new set of temporary credentials using STS. 259// Retrieve generates a new set of temporary credentials using STS.
260func (p *AssumeRoleProvider) Retrieve() (credentials.Value, error) { 260func (p *AssumeRoleProvider) Retrieve() (credentials.Value, error) {
261
262 // Apply defaults where parameters are not set. 261 // Apply defaults where parameters are not set.
263 if p.RoleSessionName == "" { 262 if p.RoleSessionName == "" {
264 // Try to work out a role name that will hopefully end up unique. 263 // Try to work out a role name that will hopefully end up unique.
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/credentials/stscreds/web_identity_provider.go b/vendor/github.com/aws/aws-sdk-go/aws/credentials/stscreds/web_identity_provider.go
new file mode 100644
index 0000000..20510d9
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go/aws/credentials/stscreds/web_identity_provider.go
@@ -0,0 +1,97 @@
1package stscreds
2
3import (
4 "fmt"
5 "io/ioutil"
6 "strconv"
7 "time"
8
9 "github.com/aws/aws-sdk-go/aws"
10 "github.com/aws/aws-sdk-go/aws/awserr"
11 "github.com/aws/aws-sdk-go/aws/client"
12 "github.com/aws/aws-sdk-go/aws/credentials"
13 "github.com/aws/aws-sdk-go/service/sts"
14 "github.com/aws/aws-sdk-go/service/sts/stsiface"
15)
16
17const (
18 // ErrCodeWebIdentity will be used as an error code when constructing
19 // a new error to be returned during session creation or retrieval.
20 ErrCodeWebIdentity = "WebIdentityErr"
21
22 // WebIdentityProviderName is the web identity provider name
23 WebIdentityProviderName = "WebIdentityCredentials"
24)
25
26// now is used to return a time.Time object representing
27// the current time. This can be used to easily test and
28// compare test values.
29var now = time.Now
30
31// WebIdentityRoleProvider is used to retrieve credentials using
32// an OIDC token.
33type WebIdentityRoleProvider struct {
34 credentials.Expiry
35
36 client stsiface.STSAPI
37 ExpiryWindow time.Duration
38
39 tokenFilePath string
40 roleARN string
41 roleSessionName string
42}
43
44// NewWebIdentityCredentials will return a new set of credentials with a given
45// configuration, role arn, and token file path.
46func NewWebIdentityCredentials(c client.ConfigProvider, roleARN, roleSessionName, path string) *credentials.Credentials {
47 svc := sts.New(c)
48 p := NewWebIdentityRoleProvider(svc, roleARN, roleSessionName, path)
49 return credentials.NewCredentials(p)
50}
51
52// NewWebIdentityRoleProvider will return a new WebIdentityRoleProvider with the
53// provided stsiface.STSAPI
54func NewWebIdentityRoleProvider(svc stsiface.STSAPI, roleARN, roleSessionName, path string) *WebIdentityRoleProvider {
55 return &WebIdentityRoleProvider{
56 client: svc,
57 tokenFilePath: path,
58 roleARN: roleARN,
59 roleSessionName: roleSessionName,
60 }
61}
62
63// Retrieve will attempt to assume a role from a token which is located at
64// 'WebIdentityTokenFilePath' specified destination and if that is empty an
65// error will be returned.
66func (p *WebIdentityRoleProvider) Retrieve() (credentials.Value, error) {
67 b, err := ioutil.ReadFile(p.tokenFilePath)
68 if err != nil {
69 errMsg := fmt.Sprintf("unable to read file at %s", p.tokenFilePath)
70 return credentials.Value{}, awserr.New(ErrCodeWebIdentity, errMsg, err)
71 }
72
73 sessionName := p.roleSessionName
74 if len(sessionName) == 0 {
75 // session name is used to uniquely identify a session. This simply
76 // uses unix time in nanoseconds to uniquely identify sessions.
77 sessionName = strconv.FormatInt(now().UnixNano(), 10)
78 }
79 resp, err := p.client.AssumeRoleWithWebIdentity(&sts.AssumeRoleWithWebIdentityInput{
80 RoleArn: &p.roleARN,
81 RoleSessionName: &sessionName,
82 WebIdentityToken: aws.String(string(b)),
83 })
84 if err != nil {
85 return credentials.Value{}, awserr.New(ErrCodeWebIdentity, "failed to retrieve credentials", err)
86 }
87
88 p.SetExpiration(aws.TimeValue(resp.Credentials.Expiration), p.ExpiryWindow)
89
90 value := credentials.Value{
91 AccessKeyID: aws.StringValue(resp.Credentials.AccessKeyId),
92 SecretAccessKey: aws.StringValue(resp.Credentials.SecretAccessKey),
93 SessionToken: aws.StringValue(resp.Credentials.SessionToken),
94 ProviderName: WebIdentityProviderName,
95 }
96 return value, nil
97}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/csm/doc.go b/vendor/github.com/aws/aws-sdk-go/aws/csm/doc.go
index 152d785..25a66d1 100644
--- a/vendor/github.com/aws/aws-sdk-go/aws/csm/doc.go
+++ b/vendor/github.com/aws/aws-sdk-go/aws/csm/doc.go
@@ -1,30 +1,61 @@
1// Package csm provides Client Side Monitoring (CSM) which enables sending metrics 1// Package csm provides the Client Side Monitoring (CSM) client which enables
2// via UDP connection. Using the Start function will enable the reporting of 2// sending metrics via UDP connection to the CSM agent. This package provides
3// metrics on a given port. If Start is called, with different parameters, again, 3// control options, and configuration for the CSM client. The client can be
4// a panic will occur. 4// controlled manually, or automatically via the SDK's Session configuration.
5// 5//
6// Pause can be called to pause any metrics publishing on a given port. Sessions 6// Enabling CSM client via SDK's Session configuration
7// that have had their handlers modified via InjectHandlers may still be used. 7//
8// However, the handlers will act as a no-op meaning no metrics will be published. 8// The CSM client can be enabled automatically via SDK's Session configuration.
9// The SDK's session configuration enables the CSM client if the AWS_CSM_PORT
10// environment variable is set to a non-empty value.
11//
12// The configuration options for the CSM client via the SDK's session
13// configuration are:
14//
15// * AWS_CSM_PORT=<port number>
16// The port number the CSM agent will receive metrics on.
17//
18// * AWS_CSM_HOST=<hostname or ip>
19// The hostname, or IP address the CSM agent will receive metrics on.
20// Without port number.
21//
22// Manually enabling the CSM client
23//
24// The CSM client can be started, paused, and resumed manually. The Start
25// function will enable the CSM client to publish metrics to the CSM agent. It
26// is safe to call Start concurrently, but if Start is called additional times
27// with different ClientID or address it will panic.
9// 28//
10// Example:
11// r, err := csm.Start("clientID", ":31000") 29// r, err := csm.Start("clientID", ":31000")
12// if err != nil { 30// if err != nil {
13// panic(fmt.Errorf("failed starting CSM: %v", err)) 31// panic(fmt.Errorf("failed starting CSM: %v", err))
14// } 32// }
15// 33//
34// When controlling the CSM client manually, you must also inject its request
35// handlers into the SDK's Session configuration for the SDK's API clients to
36// publish metrics.
37//
16// sess, err := session.NewSession(&aws.Config{}) 38// sess, err := session.NewSession(&aws.Config{})
17// if err != nil { 39// if err != nil {
18// panic(fmt.Errorf("failed loading session: %v", err)) 40// panic(fmt.Errorf("failed loading session: %v", err))
19// } 41// }
20// 42//
43// // Add CSM client's metric publishing request handlers to the SDK's
44// // Session Configuration.
21// r.InjectHandlers(&sess.Handlers) 45// r.InjectHandlers(&sess.Handlers)
22// 46//
23// client := s3.New(sess) 47// Controlling CSM client
24// resp, err := client.GetObject(&s3.GetObjectInput{ 48//
25// Bucket: aws.String("bucket"), 49// Once the CSM client has been enabled the Get function will return a Reporter
26// Key: aws.String("key"), 50// value that you can use to pause and resume the metrics published to the CSM
27// }) 51// agent. If Get function is called before the reporter is enabled with the
52// Start function or via SDK's Session configuration nil will be returned.
53//
54// The Pause method can be called to stop the CSM client publishing metrics to
55// the CSM agent. The Continue method will resume metric publishing.
56//
57// // Get the CSM client Reporter.
58// r := csm.Get()
28// 59//
29// // Will pause monitoring 60// // Will pause monitoring
30// r.Pause() 61// r.Pause()
@@ -35,12 +66,4 @@
35// 66//
36// // Resume monitoring 67// // Resume monitoring
37// r.Continue() 68// r.Continue()
38//
39// Start returns a Reporter that is used to enable or disable monitoring. If
40// access to the Reporter is required later, calling Get will return the Reporter
41// singleton.
42//
43// Example:
44// r := csm.Get()
45// r.Continue()
46package csm 69package csm
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/csm/enable.go b/vendor/github.com/aws/aws-sdk-go/aws/csm/enable.go
index 2f0c6ea..4b19e28 100644
--- a/vendor/github.com/aws/aws-sdk-go/aws/csm/enable.go
+++ b/vendor/github.com/aws/aws-sdk-go/aws/csm/enable.go
@@ -2,6 +2,7 @@ package csm
2 2
3import ( 3import (
4 "fmt" 4 "fmt"
5 "strings"
5 "sync" 6 "sync"
6) 7)
7 8
@@ -9,19 +10,40 @@ var (
9 lock sync.Mutex 10 lock sync.Mutex
10) 11)
11 12
12// Client side metric handler names
13const ( 13const (
14 APICallMetricHandlerName = "awscsm.SendAPICallMetric" 14 // DefaultPort is used when no port is specified.
15 APICallAttemptMetricHandlerName = "awscsm.SendAPICallAttemptMetric" 15 DefaultPort = "31000"
16
17 // DefaultHost is the host that will be used when none is specified.
18 DefaultHost = "127.0.0.1"
16) 19)
17 20
18// Start will start the a long running go routine to capture 21// AddressWithDefaults returns a CSM address built from the host and port
22// values. If the host or port is not set, default values will be used
23// instead. If host is "localhost" it will be replaced with "127.0.0.1".
24func AddressWithDefaults(host, port string) string {
25 if len(host) == 0 || strings.EqualFold(host, "localhost") {
26 host = DefaultHost
27 }
28
29 if len(port) == 0 {
30 port = DefaultPort
31 }
32
33 // Only IP6 host can contain a colon
34 if strings.Contains(host, ":") {
35 return "[" + host + "]:" + port
36 }
37
38 return host + ":" + port
39}
40
41// Start will start a long running go routine to capture
19// client side metrics. Calling start multiple time will only 42// client side metrics. Calling start multiple time will only
20// start the metric listener once and will panic if a different 43// start the metric listener once and will panic if a different
21// client ID or port is passed in. 44// client ID or port is passed in.
22// 45//
23// Example: 46// r, err := csm.Start("clientID", "127.0.0.1:31000")
24// r, err := csm.Start("clientID", "127.0.0.1:8094")
25// if err != nil { 47// if err != nil {
26// panic(fmt.Errorf("expected no error, but received %v", err)) 48// panic(fmt.Errorf("expected no error, but received %v", err))
27// } 49// }
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/csm/reporter.go b/vendor/github.com/aws/aws-sdk-go/aws/csm/reporter.go
index 0b5571a..c7008d8 100644
--- a/vendor/github.com/aws/aws-sdk-go/aws/csm/reporter.go
+++ b/vendor/github.com/aws/aws-sdk-go/aws/csm/reporter.go
@@ -10,11 +10,6 @@ import (
10 "github.com/aws/aws-sdk-go/aws/request" 10 "github.com/aws/aws-sdk-go/aws/request"
11) 11)
12 12
13const (
14 // DefaultPort is used when no port is specified
15 DefaultPort = "31000"
16)
17
18// Reporter will gather metrics of API requests made and 13// Reporter will gather metrics of API requests made and
19// send those metrics to the CSM endpoint. 14// send those metrics to the CSM endpoint.
20type Reporter struct { 15type Reporter struct {
@@ -96,7 +91,7 @@ func getMetricException(err awserr.Error) metricException {
96 91
97 switch code { 92 switch code {
98 case "RequestError", 93 case "RequestError",
99 "SerializationError", 94 request.ErrCodeSerialization,
100 request.CanceledErrorCode: 95 request.CanceledErrorCode:
101 return sdkException{ 96 return sdkException{
102 requestException{exception: code, message: msg}, 97 requestException{exception: code, message: msg},
@@ -123,7 +118,7 @@ func (rep *Reporter) sendAPICallMetric(r *request.Request) {
123 Type: aws.String("ApiCall"), 118 Type: aws.String("ApiCall"),
124 AttemptCount: aws.Int(r.RetryCount + 1), 119 AttemptCount: aws.Int(r.RetryCount + 1),
125 Region: r.Config.Region, 120 Region: r.Config.Region,
126 Latency: aws.Int(int(time.Now().Sub(r.Time) / time.Millisecond)), 121 Latency: aws.Int(int(time.Since(r.Time) / time.Millisecond)),
127 XAmzRequestID: aws.String(r.RequestID), 122 XAmzRequestID: aws.String(r.RequestID),
128 MaxRetriesExceeded: aws.Int(boolIntValue(r.RetryCount >= r.MaxRetries())), 123 MaxRetriesExceeded: aws.Int(boolIntValue(r.RetryCount >= r.MaxRetries())),
129 } 124 }
@@ -190,8 +185,9 @@ func (rep *Reporter) start() {
190 } 185 }
191} 186}
192 187
193// Pause will pause the metric channel preventing any new metrics from 188// Pause will pause the metric channel preventing any new metrics from being
194// being added. 189// added. It is safe to call concurrently with other calls to Pause, but if
190// called concurently with Continue can lead to unexpected state.
195func (rep *Reporter) Pause() { 191func (rep *Reporter) Pause() {
196 lock.Lock() 192 lock.Lock()
197 defer lock.Unlock() 193 defer lock.Unlock()
@@ -203,8 +199,9 @@ func (rep *Reporter) Pause() {
203 rep.close() 199 rep.close()
204} 200}
205 201
206// Continue will reopen the metric channel and allow for monitoring 202// Continue will reopen the metric channel and allow for monitoring to be
207// to be resumed. 203// resumed. It is safe to call concurrently with other calls to Continue, but
204// if called concurently with Pause can lead to unexpected state.
208func (rep *Reporter) Continue() { 205func (rep *Reporter) Continue() {
209 lock.Lock() 206 lock.Lock()
210 defer lock.Unlock() 207 defer lock.Unlock()
@@ -219,10 +216,18 @@ func (rep *Reporter) Continue() {
219 rep.metricsCh.Continue() 216 rep.metricsCh.Continue()
220} 217}
221 218
219// Client side metric handler names
220const (
221 APICallMetricHandlerName = "awscsm.SendAPICallMetric"
222 APICallAttemptMetricHandlerName = "awscsm.SendAPICallAttemptMetric"
223)
224
222// InjectHandlers will will enable client side metrics and inject the proper 225// InjectHandlers will will enable client side metrics and inject the proper
223// handlers to handle how metrics are sent. 226// handlers to handle how metrics are sent.
224// 227//
225// Example: 228// InjectHandlers is NOT safe to call concurrently. Calling InjectHandlers
229// multiple times may lead to unexpected behavior, (e.g. duplicate metrics).
230//
226// // Start must be called in order to inject the correct handlers 231// // Start must be called in order to inject the correct handlers
227// r, err := csm.Start("clientID", "127.0.0.1:8094") 232// r, err := csm.Start("clientID", "127.0.0.1:8094")
228// if err != nil { 233// if err != nil {
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/ec2metadata/api.go b/vendor/github.com/aws/aws-sdk-go/aws/ec2metadata/api.go
index d57a1af..2c8d5f5 100644
--- a/vendor/github.com/aws/aws-sdk-go/aws/ec2metadata/api.go
+++ b/vendor/github.com/aws/aws-sdk-go/aws/ec2metadata/api.go
@@ -82,7 +82,7 @@ func (c *EC2Metadata) GetInstanceIdentityDocument() (EC2InstanceIdentityDocument
82 doc := EC2InstanceIdentityDocument{} 82 doc := EC2InstanceIdentityDocument{}
83 if err := json.NewDecoder(strings.NewReader(resp)).Decode(&doc); err != nil { 83 if err := json.NewDecoder(strings.NewReader(resp)).Decode(&doc); err != nil {
84 return EC2InstanceIdentityDocument{}, 84 return EC2InstanceIdentityDocument{},
85 awserr.New("SerializationError", 85 awserr.New(request.ErrCodeSerialization,
86 "failed to decode EC2 instance identity document", err) 86 "failed to decode EC2 instance identity document", err)
87 } 87 }
88 88
@@ -101,7 +101,7 @@ func (c *EC2Metadata) IAMInfo() (EC2IAMInfo, error) {
101 info := EC2IAMInfo{} 101 info := EC2IAMInfo{}
102 if err := json.NewDecoder(strings.NewReader(resp)).Decode(&info); err != nil { 102 if err := json.NewDecoder(strings.NewReader(resp)).Decode(&info); err != nil {
103 return EC2IAMInfo{}, 103 return EC2IAMInfo{},
104 awserr.New("SerializationError", 104 awserr.New(request.ErrCodeSerialization,
105 "failed to decode EC2 IAM info", err) 105 "failed to decode EC2 IAM info", err)
106 } 106 }
107 107
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/ec2metadata/service.go b/vendor/github.com/aws/aws-sdk-go/aws/ec2metadata/service.go
index f4438ea..f0c1d31 100644
--- a/vendor/github.com/aws/aws-sdk-go/aws/ec2metadata/service.go
+++ b/vendor/github.com/aws/aws-sdk-go/aws/ec2metadata/service.go
@@ -123,7 +123,7 @@ func unmarshalHandler(r *request.Request) {
123 defer r.HTTPResponse.Body.Close() 123 defer r.HTTPResponse.Body.Close()
124 b := &bytes.Buffer{} 124 b := &bytes.Buffer{}
125 if _, err := io.Copy(b, r.HTTPResponse.Body); err != nil { 125 if _, err := io.Copy(b, r.HTTPResponse.Body); err != nil {
126 r.Error = awserr.New("SerializationError", "unable to unmarshal EC2 metadata respose", err) 126 r.Error = awserr.New(request.ErrCodeSerialization, "unable to unmarshal EC2 metadata respose", err)
127 return 127 return
128 } 128 }
129 129
@@ -136,7 +136,7 @@ func unmarshalError(r *request.Request) {
136 defer r.HTTPResponse.Body.Close() 136 defer r.HTTPResponse.Body.Close()
137 b := &bytes.Buffer{} 137 b := &bytes.Buffer{}
138 if _, err := io.Copy(b, r.HTTPResponse.Body); err != nil { 138 if _, err := io.Copy(b, r.HTTPResponse.Body); err != nil {
139 r.Error = awserr.New("SerializationError", "unable to unmarshal EC2 metadata error respose", err) 139 r.Error = awserr.New(request.ErrCodeSerialization, "unable to unmarshal EC2 metadata error respose", err)
140 return 140 return
141 } 141 }
142 142
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/endpoints/defaults.go b/vendor/github.com/aws/aws-sdk-go/aws/endpoints/defaults.go
index 50e170e..2e7bd7a 100644
--- a/vendor/github.com/aws/aws-sdk-go/aws/endpoints/defaults.go
+++ b/vendor/github.com/aws/aws-sdk-go/aws/endpoints/defaults.go
@@ -27,6 +27,7 @@ const (
27 EuWest1RegionID = "eu-west-1" // EU (Ireland). 27 EuWest1RegionID = "eu-west-1" // EU (Ireland).
28 EuWest2RegionID = "eu-west-2" // EU (London). 28 EuWest2RegionID = "eu-west-2" // EU (London).
29 EuWest3RegionID = "eu-west-3" // EU (Paris). 29 EuWest3RegionID = "eu-west-3" // EU (Paris).
30 MeSouth1RegionID = "me-south-1" // Middle East (Bahrain).
30 SaEast1RegionID = "sa-east-1" // South America (Sao Paulo). 31 SaEast1RegionID = "sa-east-1" // South America (Sao Paulo).
31 UsEast1RegionID = "us-east-1" // US East (N. Virginia). 32 UsEast1RegionID = "us-east-1" // US East (N. Virginia).
32 UsEast2RegionID = "us-east-2" // US East (Ohio). 33 UsEast2RegionID = "us-east-2" // US East (Ohio).
@@ -128,6 +129,9 @@ var awsPartition = partition{
128 "eu-west-3": region{ 129 "eu-west-3": region{
129 Description: "EU (Paris)", 130 Description: "EU (Paris)",
130 }, 131 },
132 "me-south-1": region{
133 Description: "Middle East (Bahrain)",
134 },
131 "sa-east-1": region{ 135 "sa-east-1": region{
132 Description: "South America (Sao Paulo)", 136 Description: "South America (Sao Paulo)",
133 }, 137 },
@@ -166,6 +170,7 @@ var awsPartition = partition{
166 "eu-west-1": endpoint{}, 170 "eu-west-1": endpoint{},
167 "eu-west-2": endpoint{}, 171 "eu-west-2": endpoint{},
168 "eu-west-3": endpoint{}, 172 "eu-west-3": endpoint{},
173 "me-south-1": endpoint{},
169 "sa-east-1": endpoint{}, 174 "sa-east-1": endpoint{},
170 "us-east-1": endpoint{}, 175 "us-east-1": endpoint{},
171 "us-east-2": endpoint{}, 176 "us-east-2": endpoint{},
@@ -178,6 +183,7 @@ var awsPartition = partition{
178 Protocols: []string{"https"}, 183 Protocols: []string{"https"},
179 }, 184 },
180 Endpoints: endpoints{ 185 Endpoints: endpoints{
186 "ap-east-1": endpoint{},
181 "ap-northeast-1": endpoint{}, 187 "ap-northeast-1": endpoint{},
182 "ap-northeast-2": endpoint{}, 188 "ap-northeast-2": endpoint{},
183 "ap-south-1": endpoint{}, 189 "ap-south-1": endpoint{},
@@ -270,6 +276,12 @@ var awsPartition = partition{
270 Region: "eu-west-3", 276 Region: "eu-west-3",
271 }, 277 },
272 }, 278 },
279 "me-south-1": endpoint{
280 Hostname: "api.ecr.me-south-1.amazonaws.com",
281 CredentialScope: credentialScope{
282 Region: "me-south-1",
283 },
284 },
273 "sa-east-1": endpoint{ 285 "sa-east-1": endpoint{
274 Hostname: "api.ecr.sa-east-1.amazonaws.com", 286 Hostname: "api.ecr.sa-east-1.amazonaws.com",
275 CredentialScope: credentialScope{ 287 CredentialScope: credentialScope{
@@ -381,6 +393,7 @@ var awsPartition = partition{
381 "eu-west-1": endpoint{}, 393 "eu-west-1": endpoint{},
382 "eu-west-2": endpoint{}, 394 "eu-west-2": endpoint{},
383 "eu-west-3": endpoint{}, 395 "eu-west-3": endpoint{},
396 "me-south-1": endpoint{},
384 "sa-east-1": endpoint{}, 397 "sa-east-1": endpoint{},
385 "us-east-1": endpoint{}, 398 "us-east-1": endpoint{},
386 "us-east-2": endpoint{}, 399 "us-east-2": endpoint{},
@@ -409,6 +422,7 @@ var awsPartition = partition{
409 "eu-west-1": endpoint{}, 422 "eu-west-1": endpoint{},
410 "eu-west-2": endpoint{}, 423 "eu-west-2": endpoint{},
411 "eu-west-3": endpoint{}, 424 "eu-west-3": endpoint{},
425 "me-south-1": endpoint{},
412 "sa-east-1": endpoint{}, 426 "sa-east-1": endpoint{},
413 "us-east-1": endpoint{}, 427 "us-east-1": endpoint{},
414 "us-east-2": endpoint{}, 428 "us-east-2": endpoint{},
@@ -416,6 +430,24 @@ var awsPartition = partition{
416 "us-west-2": endpoint{}, 430 "us-west-2": endpoint{},
417 }, 431 },
418 }, 432 },
433 "appmesh": service{
434
435 Endpoints: endpoints{
436 "ap-northeast-1": endpoint{},
437 "ap-northeast-2": endpoint{},
438 "ap-south-1": endpoint{},
439 "ap-southeast-1": endpoint{},
440 "ap-southeast-2": endpoint{},
441 "ca-central-1": endpoint{},
442 "eu-central-1": endpoint{},
443 "eu-west-1": endpoint{},
444 "eu-west-2": endpoint{},
445 "us-east-1": endpoint{},
446 "us-east-2": endpoint{},
447 "us-west-1": endpoint{},
448 "us-west-2": endpoint{},
449 },
450 },
419 "appstream2": service{ 451 "appstream2": service{
420 Defaults: endpoint{ 452 Defaults: endpoint{
421 Protocols: []string{"https"}, 453 Protocols: []string{"https"},
@@ -460,6 +492,7 @@ var awsPartition = partition{
460 "ap-southeast-2": endpoint{}, 492 "ap-southeast-2": endpoint{},
461 "ca-central-1": endpoint{}, 493 "ca-central-1": endpoint{},
462 "eu-central-1": endpoint{}, 494 "eu-central-1": endpoint{},
495 "eu-north-1": endpoint{},
463 "eu-west-1": endpoint{}, 496 "eu-west-1": endpoint{},
464 "eu-west-2": endpoint{}, 497 "eu-west-2": endpoint{},
465 "us-east-1": endpoint{}, 498 "us-east-1": endpoint{},
@@ -484,6 +517,7 @@ var awsPartition = partition{
484 "eu-west-1": endpoint{}, 517 "eu-west-1": endpoint{},
485 "eu-west-2": endpoint{}, 518 "eu-west-2": endpoint{},
486 "eu-west-3": endpoint{}, 519 "eu-west-3": endpoint{},
520 "me-south-1": endpoint{},
487 "sa-east-1": endpoint{}, 521 "sa-east-1": endpoint{},
488 "us-east-1": endpoint{}, 522 "us-east-1": endpoint{},
489 "us-east-2": endpoint{}, 523 "us-east-2": endpoint{},
@@ -515,9 +549,27 @@ var awsPartition = partition{
515 "us-west-2": endpoint{}, 549 "us-west-2": endpoint{},
516 }, 550 },
517 }, 551 },
552 "backup": service{
553
554 Endpoints: endpoints{
555 "ap-northeast-1": endpoint{},
556 "ap-northeast-2": endpoint{},
557 "ap-southeast-1": endpoint{},
558 "ap-southeast-2": endpoint{},
559 "ca-central-1": endpoint{},
560 "eu-central-1": endpoint{},
561 "eu-west-1": endpoint{},
562 "eu-west-2": endpoint{},
563 "us-east-1": endpoint{},
564 "us-east-2": endpoint{},
565 "us-west-1": endpoint{},
566 "us-west-2": endpoint{},
567 },
568 },
518 "batch": service{ 569 "batch": service{
519 570
520 Endpoints: endpoints{ 571 Endpoints: endpoints{
572 "ap-east-1": endpoint{},
521 "ap-northeast-1": endpoint{}, 573 "ap-northeast-1": endpoint{},
522 "ap-northeast-2": endpoint{}, 574 "ap-northeast-2": endpoint{},
523 "ap-south-1": endpoint{}, 575 "ap-south-1": endpoint{},
@@ -584,6 +636,7 @@ var awsPartition = partition{
584 Endpoints: endpoints{ 636 Endpoints: endpoints{
585 "ap-northeast-1": endpoint{}, 637 "ap-northeast-1": endpoint{},
586 "ap-southeast-1": endpoint{}, 638 "ap-southeast-1": endpoint{},
639 "eu-central-1": endpoint{},
587 "eu-west-1": endpoint{}, 640 "eu-west-1": endpoint{},
588 "us-east-1": endpoint{}, 641 "us-east-1": endpoint{},
589 "us-east-2": endpoint{}, 642 "us-east-2": endpoint{},
@@ -619,6 +672,7 @@ var awsPartition = partition{
619 "eu-west-1": endpoint{}, 672 "eu-west-1": endpoint{},
620 "eu-west-2": endpoint{}, 673 "eu-west-2": endpoint{},
621 "eu-west-3": endpoint{}, 674 "eu-west-3": endpoint{},
675 "me-south-1": endpoint{},
622 "sa-east-1": endpoint{}, 676 "sa-east-1": endpoint{},
623 "us-east-1": endpoint{}, 677 "us-east-1": endpoint{},
624 "us-east-2": endpoint{}, 678 "us-east-2": endpoint{},
@@ -662,6 +716,7 @@ var awsPartition = partition{
662 }, 716 },
663 }, 717 },
664 Endpoints: endpoints{ 718 Endpoints: endpoints{
719 "ap-east-1": endpoint{},
665 "ap-northeast-1": endpoint{}, 720 "ap-northeast-1": endpoint{},
666 "ap-northeast-2": endpoint{}, 721 "ap-northeast-2": endpoint{},
667 "ap-south-1": endpoint{}, 722 "ap-south-1": endpoint{},
@@ -709,6 +764,7 @@ var awsPartition = partition{
709 "eu-west-1": endpoint{}, 764 "eu-west-1": endpoint{},
710 "eu-west-2": endpoint{}, 765 "eu-west-2": endpoint{},
711 "eu-west-3": endpoint{}, 766 "eu-west-3": endpoint{},
767 "me-south-1": endpoint{},
712 "sa-east-1": endpoint{}, 768 "sa-east-1": endpoint{},
713 "us-east-1": endpoint{}, 769 "us-east-1": endpoint{},
714 "us-east-2": endpoint{}, 770 "us-east-2": endpoint{},
@@ -726,6 +782,7 @@ var awsPartition = partition{
726 "ap-southeast-2": endpoint{}, 782 "ap-southeast-2": endpoint{},
727 "ca-central-1": endpoint{}, 783 "ca-central-1": endpoint{},
728 "eu-central-1": endpoint{}, 784 "eu-central-1": endpoint{},
785 "eu-north-1": endpoint{},
729 "eu-west-1": endpoint{}, 786 "eu-west-1": endpoint{},
730 "eu-west-2": endpoint{}, 787 "eu-west-2": endpoint{},
731 "eu-west-3": endpoint{}, 788 "eu-west-3": endpoint{},
@@ -789,6 +846,7 @@ var awsPartition = partition{
789 "codedeploy": service{ 846 "codedeploy": service{
790 847
791 Endpoints: endpoints{ 848 Endpoints: endpoints{
849 "ap-east-1": endpoint{},
792 "ap-northeast-1": endpoint{}, 850 "ap-northeast-1": endpoint{},
793 "ap-northeast-2": endpoint{}, 851 "ap-northeast-2": endpoint{},
794 "ap-south-1": endpoint{}, 852 "ap-south-1": endpoint{},
@@ -800,6 +858,7 @@ var awsPartition = partition{
800 "eu-west-1": endpoint{}, 858 "eu-west-1": endpoint{},
801 "eu-west-2": endpoint{}, 859 "eu-west-2": endpoint{},
802 "eu-west-3": endpoint{}, 860 "eu-west-3": endpoint{},
861 "me-south-1": endpoint{},
803 "sa-east-1": endpoint{}, 862 "sa-east-1": endpoint{},
804 "us-east-1": endpoint{}, 863 "us-east-1": endpoint{},
805 "us-east-1-fips": endpoint{ 864 "us-east-1-fips": endpoint{
@@ -937,10 +996,13 @@ var awsPartition = partition{
937 "comprehendmedical": service{ 996 "comprehendmedical": service{
938 997
939 Endpoints: endpoints{ 998 Endpoints: endpoints{
940 "eu-west-1": endpoint{}, 999 "ap-southeast-2": endpoint{},
941 "us-east-1": endpoint{}, 1000 "ca-central-1": endpoint{},
942 "us-east-2": endpoint{}, 1001 "eu-west-1": endpoint{},
943 "us-west-2": endpoint{}, 1002 "eu-west-2": endpoint{},
1003 "us-east-1": endpoint{},
1004 "us-east-2": endpoint{},
1005 "us-west-2": endpoint{},
944 }, 1006 },
945 }, 1007 },
946 "config": service{ 1008 "config": service{
@@ -958,6 +1020,7 @@ var awsPartition = partition{
958 "eu-west-1": endpoint{}, 1020 "eu-west-1": endpoint{},
959 "eu-west-2": endpoint{}, 1021 "eu-west-2": endpoint{},
960 "eu-west-3": endpoint{}, 1022 "eu-west-3": endpoint{},
1023 "me-south-1": endpoint{},
961 "sa-east-1": endpoint{}, 1024 "sa-east-1": endpoint{},
962 "us-east-1": endpoint{}, 1025 "us-east-1": endpoint{},
963 "us-east-2": endpoint{}, 1026 "us-east-2": endpoint{},
@@ -971,6 +1034,19 @@ var awsPartition = partition{
971 "us-east-1": endpoint{}, 1034 "us-east-1": endpoint{},
972 }, 1035 },
973 }, 1036 },
1037 "data.mediastore": service{
1038
1039 Endpoints: endpoints{
1040 "ap-northeast-1": endpoint{},
1041 "ap-northeast-2": endpoint{},
1042 "ap-southeast-2": endpoint{},
1043 "eu-central-1": endpoint{},
1044 "eu-north-1": endpoint{},
1045 "eu-west-1": endpoint{},
1046 "us-east-1": endpoint{},
1047 "us-west-2": endpoint{},
1048 },
1049 },
974 "datapipeline": service{ 1050 "datapipeline": service{
975 1051
976 Endpoints: endpoints{ 1052 Endpoints: endpoints{
@@ -1032,6 +1108,7 @@ var awsPartition = partition{
1032 "eu-west-1": endpoint{}, 1108 "eu-west-1": endpoint{},
1033 "eu-west-2": endpoint{}, 1109 "eu-west-2": endpoint{},
1034 "eu-west-3": endpoint{}, 1110 "eu-west-3": endpoint{},
1111 "me-south-1": endpoint{},
1035 "sa-east-1": endpoint{}, 1112 "sa-east-1": endpoint{},
1036 "us-east-1": endpoint{}, 1113 "us-east-1": endpoint{},
1037 "us-east-2": endpoint{}, 1114 "us-east-2": endpoint{},
@@ -1060,6 +1137,7 @@ var awsPartition = partition{
1060 "eu-west-1": endpoint{}, 1137 "eu-west-1": endpoint{},
1061 "eu-west-2": endpoint{}, 1138 "eu-west-2": endpoint{},
1062 "eu-west-3": endpoint{}, 1139 "eu-west-3": endpoint{},
1140 "me-south-1": endpoint{},
1063 "sa-east-1": endpoint{}, 1141 "sa-east-1": endpoint{},
1064 "us-east-1": endpoint{}, 1142 "us-east-1": endpoint{},
1065 "us-east-2": endpoint{}, 1143 "us-east-2": endpoint{},
@@ -1070,6 +1148,24 @@ var awsPartition = partition{
1070 "docdb": service{ 1148 "docdb": service{
1071 1149
1072 Endpoints: endpoints{ 1150 Endpoints: endpoints{
1151 "ap-northeast-1": endpoint{
1152 Hostname: "rds.ap-northeast-1.amazonaws.com",
1153 CredentialScope: credentialScope{
1154 Region: "ap-northeast-1",
1155 },
1156 },
1157 "ap-northeast-2": endpoint{
1158 Hostname: "rds.ap-northeast-2.amazonaws.com",
1159 CredentialScope: credentialScope{
1160 Region: "ap-northeast-2",
1161 },
1162 },
1163 "ap-southeast-2": endpoint{
1164 Hostname: "rds.ap-southeast-2.amazonaws.com",
1165 CredentialScope: credentialScope{
1166 Region: "ap-southeast-2",
1167 },
1168 },
1073 "eu-central-1": endpoint{ 1169 "eu-central-1": endpoint{
1074 Hostname: "rds.eu-central-1.amazonaws.com", 1170 Hostname: "rds.eu-central-1.amazonaws.com",
1075 CredentialScope: credentialScope{ 1171 CredentialScope: credentialScope{
@@ -1082,6 +1178,12 @@ var awsPartition = partition{
1082 Region: "eu-west-1", 1178 Region: "eu-west-1",
1083 }, 1179 },
1084 }, 1180 },
1181 "eu-west-2": endpoint{
1182 Hostname: "rds.eu-west-2.amazonaws.com",
1183 CredentialScope: credentialScope{
1184 Region: "eu-west-2",
1185 },
1186 },
1085 "us-east-1": endpoint{ 1187 "us-east-1": endpoint{
1086 Hostname: "rds.us-east-1.amazonaws.com", 1188 Hostname: "rds.us-east-1.amazonaws.com",
1087 CredentialScope: credentialScope{ 1189 CredentialScope: credentialScope{
@@ -1112,6 +1214,7 @@ var awsPartition = partition{
1112 "ap-southeast-2": endpoint{}, 1214 "ap-southeast-2": endpoint{},
1113 "ca-central-1": endpoint{}, 1215 "ca-central-1": endpoint{},
1114 "eu-central-1": endpoint{}, 1216 "eu-central-1": endpoint{},
1217 "eu-north-1": endpoint{},
1115 "eu-west-1": endpoint{}, 1218 "eu-west-1": endpoint{},
1116 "eu-west-2": endpoint{}, 1219 "eu-west-2": endpoint{},
1117 "sa-east-1": endpoint{}, 1220 "sa-east-1": endpoint{},
@@ -1133,11 +1236,17 @@ var awsPartition = partition{
1133 "ap-southeast-1": endpoint{}, 1236 "ap-southeast-1": endpoint{},
1134 "ap-southeast-2": endpoint{}, 1237 "ap-southeast-2": endpoint{},
1135 "ca-central-1": endpoint{}, 1238 "ca-central-1": endpoint{},
1136 "eu-central-1": endpoint{}, 1239 "ca-central-1-fips": endpoint{
1137 "eu-north-1": endpoint{}, 1240 Hostname: "dynamodb-fips.ca-central-1.amazonaws.com",
1138 "eu-west-1": endpoint{}, 1241 CredentialScope: credentialScope{
1139 "eu-west-2": endpoint{}, 1242 Region: "ca-central-1",
1140 "eu-west-3": endpoint{}, 1243 },
1244 },
1245 "eu-central-1": endpoint{},
1246 "eu-north-1": endpoint{},
1247 "eu-west-1": endpoint{},
1248 "eu-west-2": endpoint{},
1249 "eu-west-3": endpoint{},
1141 "local": endpoint{ 1250 "local": endpoint{
1142 Hostname: "localhost:8000", 1251 Hostname: "localhost:8000",
1143 Protocols: []string{"http"}, 1252 Protocols: []string{"http"},
@@ -1145,11 +1254,36 @@ var awsPartition = partition{
1145 Region: "us-east-1", 1254 Region: "us-east-1",
1146 }, 1255 },
1147 }, 1256 },
1148 "sa-east-1": endpoint{}, 1257 "me-south-1": endpoint{},
1149 "us-east-1": endpoint{}, 1258 "sa-east-1": endpoint{},
1259 "us-east-1": endpoint{},
1260 "us-east-1-fips": endpoint{
1261 Hostname: "dynamodb-fips.us-east-1.amazonaws.com",
1262 CredentialScope: credentialScope{
1263 Region: "us-east-1",
1264 },
1265 },
1150 "us-east-2": endpoint{}, 1266 "us-east-2": endpoint{},
1267 "us-east-2-fips": endpoint{
1268 Hostname: "dynamodb-fips.us-east-2.amazonaws.com",
1269 CredentialScope: credentialScope{
1270 Region: "us-east-2",
1271 },
1272 },
1151 "us-west-1": endpoint{}, 1273 "us-west-1": endpoint{},
1274 "us-west-1-fips": endpoint{
1275 Hostname: "dynamodb-fips.us-west-1.amazonaws.com",
1276 CredentialScope: credentialScope{
1277 Region: "us-west-1",
1278 },
1279 },
1152 "us-west-2": endpoint{}, 1280 "us-west-2": endpoint{},
1281 "us-west-2-fips": endpoint{
1282 Hostname: "dynamodb-fips.us-west-2.amazonaws.com",
1283 CredentialScope: credentialScope{
1284 Region: "us-west-2",
1285 },
1286 },
1153 }, 1287 },
1154 }, 1288 },
1155 "ec2": service{ 1289 "ec2": service{
@@ -1169,6 +1303,7 @@ var awsPartition = partition{
1169 "eu-west-1": endpoint{}, 1303 "eu-west-1": endpoint{},
1170 "eu-west-2": endpoint{}, 1304 "eu-west-2": endpoint{},
1171 "eu-west-3": endpoint{}, 1305 "eu-west-3": endpoint{},
1306 "me-south-1": endpoint{},
1172 "sa-east-1": endpoint{}, 1307 "sa-east-1": endpoint{},
1173 "us-east-1": endpoint{}, 1308 "us-east-1": endpoint{},
1174 "us-east-2": endpoint{}, 1309 "us-east-2": endpoint{},
@@ -1202,6 +1337,7 @@ var awsPartition = partition{
1202 "eu-west-1": endpoint{}, 1337 "eu-west-1": endpoint{},
1203 "eu-west-2": endpoint{}, 1338 "eu-west-2": endpoint{},
1204 "eu-west-3": endpoint{}, 1339 "eu-west-3": endpoint{},
1340 "me-south-1": endpoint{},
1205 "sa-east-1": endpoint{}, 1341 "sa-east-1": endpoint{},
1206 "us-east-1": endpoint{}, 1342 "us-east-1": endpoint{},
1207 "us-east-2": endpoint{}, 1343 "us-east-2": endpoint{},
@@ -1230,16 +1366,18 @@ var awsPartition = partition{
1230 Region: "us-west-1", 1366 Region: "us-west-1",
1231 }, 1367 },
1232 }, 1368 },
1233 "sa-east-1": endpoint{}, 1369 "me-south-1": endpoint{},
1234 "us-east-1": endpoint{}, 1370 "sa-east-1": endpoint{},
1235 "us-east-2": endpoint{}, 1371 "us-east-1": endpoint{},
1236 "us-west-1": endpoint{}, 1372 "us-east-2": endpoint{},
1237 "us-west-2": endpoint{}, 1373 "us-west-1": endpoint{},
1374 "us-west-2": endpoint{},
1238 }, 1375 },
1239 }, 1376 },
1240 "elasticbeanstalk": service{ 1377 "elasticbeanstalk": service{
1241 1378
1242 Endpoints: endpoints{ 1379 Endpoints: endpoints{
1380 "ap-east-1": endpoint{},
1243 "ap-northeast-1": endpoint{}, 1381 "ap-northeast-1": endpoint{},
1244 "ap-northeast-2": endpoint{}, 1382 "ap-northeast-2": endpoint{},
1245 "ap-south-1": endpoint{}, 1383 "ap-south-1": endpoint{},
@@ -1251,6 +1389,7 @@ var awsPartition = partition{
1251 "eu-west-1": endpoint{}, 1389 "eu-west-1": endpoint{},
1252 "eu-west-2": endpoint{}, 1390 "eu-west-2": endpoint{},
1253 "eu-west-3": endpoint{}, 1391 "eu-west-3": endpoint{},
1392 "me-south-1": endpoint{},
1254 "sa-east-1": endpoint{}, 1393 "sa-east-1": endpoint{},
1255 "us-east-1": endpoint{}, 1394 "us-east-1": endpoint{},
1256 "us-east-2": endpoint{}, 1395 "us-east-2": endpoint{},
@@ -1263,11 +1402,14 @@ var awsPartition = partition{
1263 Endpoints: endpoints{ 1402 Endpoints: endpoints{
1264 "ap-northeast-1": endpoint{}, 1403 "ap-northeast-1": endpoint{},
1265 "ap-northeast-2": endpoint{}, 1404 "ap-northeast-2": endpoint{},
1405 "ap-south-1": endpoint{},
1266 "ap-southeast-1": endpoint{}, 1406 "ap-southeast-1": endpoint{},
1267 "ap-southeast-2": endpoint{}, 1407 "ap-southeast-2": endpoint{},
1408 "ca-central-1": endpoint{},
1268 "eu-central-1": endpoint{}, 1409 "eu-central-1": endpoint{},
1269 "eu-west-1": endpoint{}, 1410 "eu-west-1": endpoint{},
1270 "eu-west-2": endpoint{}, 1411 "eu-west-2": endpoint{},
1412 "eu-west-3": endpoint{},
1271 "us-east-1": endpoint{}, 1413 "us-east-1": endpoint{},
1272 "us-east-2": endpoint{}, 1414 "us-east-2": endpoint{},
1273 "us-west-1": endpoint{}, 1415 "us-west-1": endpoint{},
@@ -1291,6 +1433,7 @@ var awsPartition = partition{
1291 "eu-west-1": endpoint{}, 1433 "eu-west-1": endpoint{},
1292 "eu-west-2": endpoint{}, 1434 "eu-west-2": endpoint{},
1293 "eu-west-3": endpoint{}, 1435 "eu-west-3": endpoint{},
1436 "me-south-1": endpoint{},
1294 "sa-east-1": endpoint{}, 1437 "sa-east-1": endpoint{},
1295 "us-east-1": endpoint{}, 1438 "us-east-1": endpoint{},
1296 "us-east-2": endpoint{}, 1439 "us-east-2": endpoint{},
@@ -1318,6 +1461,7 @@ var awsPartition = partition{
1318 "eu-west-1": endpoint{}, 1461 "eu-west-1": endpoint{},
1319 "eu-west-2": endpoint{}, 1462 "eu-west-2": endpoint{},
1320 "eu-west-3": endpoint{}, 1463 "eu-west-3": endpoint{},
1464 "me-south-1": endpoint{},
1321 "sa-east-1": endpoint{}, 1465 "sa-east-1": endpoint{},
1322 "us-east-1": endpoint{ 1466 "us-east-1": endpoint{
1323 SSLCommonName: "{service}.{region}.{dnsSuffix}", 1467 SSLCommonName: "{service}.{region}.{dnsSuffix}",
@@ -1343,10 +1487,12 @@ var awsPartition = partition{
1343 "email": service{ 1487 "email": service{
1344 1488
1345 Endpoints: endpoints{ 1489 Endpoints: endpoints{
1346 "eu-central-1": endpoint{}, 1490 "ap-south-1": endpoint{},
1347 "eu-west-1": endpoint{}, 1491 "ap-southeast-2": endpoint{},
1348 "us-east-1": endpoint{}, 1492 "eu-central-1": endpoint{},
1349 "us-west-2": endpoint{}, 1493 "eu-west-1": endpoint{},
1494 "us-east-1": endpoint{},
1495 "us-west-2": endpoint{},
1350 }, 1496 },
1351 }, 1497 },
1352 "entitlement.marketplace": service{ 1498 "entitlement.marketplace": service{
@@ -1402,6 +1548,7 @@ var awsPartition = partition{
1402 "eu-west-1": endpoint{}, 1548 "eu-west-1": endpoint{},
1403 "eu-west-2": endpoint{}, 1549 "eu-west-2": endpoint{},
1404 "eu-west-3": endpoint{}, 1550 "eu-west-3": endpoint{},
1551 "me-south-1": endpoint{},
1405 "sa-east-1": endpoint{}, 1552 "sa-east-1": endpoint{},
1406 "us-east-1": endpoint{}, 1553 "us-east-1": endpoint{},
1407 "us-east-2": endpoint{}, 1554 "us-east-2": endpoint{},
@@ -1419,6 +1566,7 @@ var awsPartition = partition{
1419 "ap-southeast-2": endpoint{}, 1566 "ap-southeast-2": endpoint{},
1420 "ca-central-1": endpoint{}, 1567 "ca-central-1": endpoint{},
1421 "eu-central-1": endpoint{}, 1568 "eu-central-1": endpoint{},
1569 "eu-north-1": endpoint{},
1422 "eu-west-1": endpoint{}, 1570 "eu-west-1": endpoint{},
1423 "eu-west-2": endpoint{}, 1571 "eu-west-2": endpoint{},
1424 "eu-west-3": endpoint{}, 1572 "eu-west-3": endpoint{},
@@ -1435,11 +1583,15 @@ var awsPartition = partition{
1435 }, 1583 },
1436 Endpoints: endpoints{ 1584 Endpoints: endpoints{
1437 "ap-northeast-1": endpoint{}, 1585 "ap-northeast-1": endpoint{},
1586 "ap-northeast-2": endpoint{},
1587 "ap-southeast-1": endpoint{},
1438 "ap-southeast-2": endpoint{}, 1588 "ap-southeast-2": endpoint{},
1439 "eu-central-1": endpoint{}, 1589 "eu-central-1": endpoint{},
1440 "eu-west-1": endpoint{}, 1590 "eu-west-1": endpoint{},
1591 "eu-west-2": endpoint{},
1441 "us-east-1": endpoint{}, 1592 "us-east-1": endpoint{},
1442 "us-east-2": endpoint{}, 1593 "us-east-2": endpoint{},
1594 "us-west-1": endpoint{},
1443 "us-west-2": endpoint{}, 1595 "us-west-2": endpoint{},
1444 }, 1596 },
1445 }, 1597 },
@@ -1447,10 +1599,14 @@ var awsPartition = partition{
1447 1599
1448 Endpoints: endpoints{ 1600 Endpoints: endpoints{
1449 "ap-northeast-1": endpoint{}, 1601 "ap-northeast-1": endpoint{},
1602 "ap-southeast-1": endpoint{},
1450 "ap-southeast-2": endpoint{}, 1603 "ap-southeast-2": endpoint{},
1604 "eu-central-1": endpoint{},
1451 "eu-west-1": endpoint{}, 1605 "eu-west-1": endpoint{},
1606 "eu-west-2": endpoint{},
1452 "us-east-1": endpoint{}, 1607 "us-east-1": endpoint{},
1453 "us-east-2": endpoint{}, 1608 "us-east-2": endpoint{},
1609 "us-west-1": endpoint{},
1454 "us-west-2": endpoint{}, 1610 "us-west-2": endpoint{},
1455 }, 1611 },
1456 }, 1612 },
@@ -1490,6 +1646,7 @@ var awsPartition = partition{
1490 "eu-west-1": endpoint{}, 1646 "eu-west-1": endpoint{},
1491 "eu-west-2": endpoint{}, 1647 "eu-west-2": endpoint{},
1492 "eu-west-3": endpoint{}, 1648 "eu-west-3": endpoint{},
1649 "me-south-1": endpoint{},
1493 "sa-east-1": endpoint{}, 1650 "sa-east-1": endpoint{},
1494 "us-east-1": endpoint{}, 1651 "us-east-1": endpoint{},
1495 "us-east-2": endpoint{}, 1652 "us-east-2": endpoint{},
@@ -1500,6 +1657,7 @@ var awsPartition = partition{
1500 "glue": service{ 1657 "glue": service{
1501 1658
1502 Endpoints: endpoints{ 1659 Endpoints: endpoints{
1660 "ap-east-1": endpoint{},
1503 "ap-northeast-1": endpoint{}, 1661 "ap-northeast-1": endpoint{},
1504 "ap-northeast-2": endpoint{}, 1662 "ap-northeast-2": endpoint{},
1505 "ap-south-1": endpoint{}, 1663 "ap-south-1": endpoint{},
@@ -1507,9 +1665,11 @@ var awsPartition = partition{
1507 "ap-southeast-2": endpoint{}, 1665 "ap-southeast-2": endpoint{},
1508 "ca-central-1": endpoint{}, 1666 "ca-central-1": endpoint{},
1509 "eu-central-1": endpoint{}, 1667 "eu-central-1": endpoint{},
1668 "eu-north-1": endpoint{},
1510 "eu-west-1": endpoint{}, 1669 "eu-west-1": endpoint{},
1511 "eu-west-2": endpoint{}, 1670 "eu-west-2": endpoint{},
1512 "eu-west-3": endpoint{}, 1671 "eu-west-3": endpoint{},
1672 "sa-east-1": endpoint{},
1513 "us-east-1": endpoint{}, 1673 "us-east-1": endpoint{},
1514 "us-east-2": endpoint{}, 1674 "us-east-2": endpoint{},
1515 "us-west-1": endpoint{}, 1675 "us-west-1": endpoint{},
@@ -1523,19 +1683,32 @@ var awsPartition = partition{
1523 }, 1683 },
1524 Endpoints: endpoints{ 1684 Endpoints: endpoints{
1525 "ap-northeast-1": endpoint{}, 1685 "ap-northeast-1": endpoint{},
1686 "ap-northeast-2": endpoint{},
1687 "ap-south-1": endpoint{},
1688 "ap-southeast-1": endpoint{},
1526 "ap-southeast-2": endpoint{}, 1689 "ap-southeast-2": endpoint{},
1527 "eu-central-1": endpoint{}, 1690 "eu-central-1": endpoint{},
1528 "eu-west-1": endpoint{}, 1691 "eu-west-1": endpoint{},
1692 "eu-west-2": endpoint{},
1529 "us-east-1": endpoint{}, 1693 "us-east-1": endpoint{},
1694 "us-east-2": endpoint{},
1530 "us-west-2": endpoint{}, 1695 "us-west-2": endpoint{},
1531 }, 1696 },
1532 }, 1697 },
1698 "groundstation": service{
1699
1700 Endpoints: endpoints{
1701 "us-east-2": endpoint{},
1702 "us-west-2": endpoint{},
1703 },
1704 },
1533 "guardduty": service{ 1705 "guardduty": service{
1534 IsRegionalized: boxedTrue, 1706 IsRegionalized: boxedTrue,
1535 Defaults: endpoint{ 1707 Defaults: endpoint{
1536 Protocols: []string{"https"}, 1708 Protocols: []string{"https"},
1537 }, 1709 },
1538 Endpoints: endpoints{ 1710 Endpoints: endpoints{
1711 "ap-east-1": endpoint{},
1539 "ap-northeast-1": endpoint{}, 1712 "ap-northeast-1": endpoint{},
1540 "ap-northeast-2": endpoint{}, 1713 "ap-northeast-2": endpoint{},
1541 "ap-south-1": endpoint{}, 1714 "ap-south-1": endpoint{},
@@ -1543,6 +1716,7 @@ var awsPartition = partition{
1543 "ap-southeast-2": endpoint{}, 1716 "ap-southeast-2": endpoint{},
1544 "ca-central-1": endpoint{}, 1717 "ca-central-1": endpoint{},
1545 "eu-central-1": endpoint{}, 1718 "eu-central-1": endpoint{},
1719 "eu-north-1": endpoint{},
1546 "eu-west-1": endpoint{}, 1720 "eu-west-1": endpoint{},
1547 "eu-west-2": endpoint{}, 1721 "eu-west-2": endpoint{},
1548 "eu-west-3": endpoint{}, 1722 "eu-west-3": endpoint{},
@@ -1595,7 +1769,9 @@ var awsPartition = partition{
1595 "ap-south-1": endpoint{}, 1769 "ap-south-1": endpoint{},
1596 "ap-southeast-2": endpoint{}, 1770 "ap-southeast-2": endpoint{},
1597 "eu-central-1": endpoint{}, 1771 "eu-central-1": endpoint{},
1772 "eu-north-1": endpoint{},
1598 "eu-west-1": endpoint{}, 1773 "eu-west-1": endpoint{},
1774 "eu-west-2": endpoint{},
1599 "us-east-1": endpoint{}, 1775 "us-east-1": endpoint{},
1600 "us-east-2": endpoint{}, 1776 "us-east-2": endpoint{},
1601 "us-west-1": endpoint{}, 1777 "us-west-1": endpoint{},
@@ -1614,11 +1790,16 @@ var awsPartition = partition{
1614 "ap-south-1": endpoint{}, 1790 "ap-south-1": endpoint{},
1615 "ap-southeast-1": endpoint{}, 1791 "ap-southeast-1": endpoint{},
1616 "ap-southeast-2": endpoint{}, 1792 "ap-southeast-2": endpoint{},
1793 "ca-central-1": endpoint{},
1617 "eu-central-1": endpoint{}, 1794 "eu-central-1": endpoint{},
1795 "eu-north-1": endpoint{},
1618 "eu-west-1": endpoint{}, 1796 "eu-west-1": endpoint{},
1619 "eu-west-2": endpoint{}, 1797 "eu-west-2": endpoint{},
1798 "eu-west-3": endpoint{},
1799 "sa-east-1": endpoint{},
1620 "us-east-1": endpoint{}, 1800 "us-east-1": endpoint{},
1621 "us-east-2": endpoint{}, 1801 "us-east-2": endpoint{},
1802 "us-west-1": endpoint{},
1622 "us-west-2": endpoint{}, 1803 "us-west-2": endpoint{},
1623 }, 1804 },
1624 }, 1805 },
@@ -1633,6 +1814,95 @@ var awsPartition = partition{
1633 "us-west-2": endpoint{}, 1814 "us-west-2": endpoint{},
1634 }, 1815 },
1635 }, 1816 },
1817 "iotevents": service{
1818
1819 Endpoints: endpoints{
1820 "ap-northeast-1": endpoint{},
1821 "ap-southeast-2": endpoint{},
1822 "eu-central-1": endpoint{},
1823 "eu-west-1": endpoint{},
1824 "us-east-1": endpoint{},
1825 "us-east-2": endpoint{},
1826 "us-west-2": endpoint{},
1827 },
1828 },
1829 "ioteventsdata": service{
1830
1831 Endpoints: endpoints{
1832 "ap-northeast-1": endpoint{
1833 Hostname: "data.iotevents.ap-northeast-1.amazonaws.com",
1834 CredentialScope: credentialScope{
1835 Region: "ap-northeast-1",
1836 },
1837 },
1838 "ap-southeast-2": endpoint{
1839 Hostname: "data.iotevents.ap-southeast-2.amazonaws.com",
1840 CredentialScope: credentialScope{
1841 Region: "ap-southeast-2",
1842 },
1843 },
1844 "eu-central-1": endpoint{
1845 Hostname: "data.iotevents.eu-central-1.amazonaws.com",
1846 CredentialScope: credentialScope{
1847 Region: "eu-central-1",
1848 },
1849 },
1850 "eu-west-1": endpoint{
1851 Hostname: "data.iotevents.eu-west-1.amazonaws.com",
1852 CredentialScope: credentialScope{
1853 Region: "eu-west-1",
1854 },
1855 },
1856 "us-east-1": endpoint{
1857 Hostname: "data.iotevents.us-east-1.amazonaws.com",
1858 CredentialScope: credentialScope{
1859 Region: "us-east-1",
1860 },
1861 },
1862 "us-east-2": endpoint{
1863 Hostname: "data.iotevents.us-east-2.amazonaws.com",
1864 CredentialScope: credentialScope{
1865 Region: "us-east-2",
1866 },
1867 },
1868 "us-west-2": endpoint{
1869 Hostname: "data.iotevents.us-west-2.amazonaws.com",
1870 CredentialScope: credentialScope{
1871 Region: "us-west-2",
1872 },
1873 },
1874 },
1875 },
1876 "iotthingsgraph": service{
1877 Defaults: endpoint{
1878 CredentialScope: credentialScope{
1879 Service: "iotthingsgraph",
1880 },
1881 },
1882 Endpoints: endpoints{
1883 "ap-northeast-1": endpoint{},
1884 "ap-southeast-2": endpoint{},
1885 "eu-west-1": endpoint{},
1886 "us-east-1": endpoint{},
1887 "us-west-2": endpoint{},
1888 },
1889 },
1890 "kafka": service{
1891
1892 Endpoints: endpoints{
1893 "ap-northeast-1": endpoint{},
1894 "ap-southeast-1": endpoint{},
1895 "ap-southeast-2": endpoint{},
1896 "eu-central-1": endpoint{},
1897 "eu-north-1": endpoint{},
1898 "eu-west-1": endpoint{},
1899 "eu-west-2": endpoint{},
1900 "eu-west-3": endpoint{},
1901 "us-east-1": endpoint{},
1902 "us-east-2": endpoint{},
1903 "us-west-2": endpoint{},
1904 },
1905 },
1636 "kinesis": service{ 1906 "kinesis": service{
1637 1907
1638 Endpoints: endpoints{ 1908 Endpoints: endpoints{
@@ -1648,6 +1918,7 @@ var awsPartition = partition{
1648 "eu-west-1": endpoint{}, 1918 "eu-west-1": endpoint{},
1649 "eu-west-2": endpoint{}, 1919 "eu-west-2": endpoint{},
1650 "eu-west-3": endpoint{}, 1920 "eu-west-3": endpoint{},
1921 "me-south-1": endpoint{},
1651 "sa-east-1": endpoint{}, 1922 "sa-east-1": endpoint{},
1652 "us-east-1": endpoint{}, 1923 "us-east-1": endpoint{},
1653 "us-east-2": endpoint{}, 1924 "us-east-2": endpoint{},
@@ -1658,11 +1929,16 @@ var awsPartition = partition{
1658 "kinesisanalytics": service{ 1929 "kinesisanalytics": service{
1659 1930
1660 Endpoints: endpoints{ 1931 Endpoints: endpoints{
1661 "eu-central-1": endpoint{}, 1932 "ap-northeast-1": endpoint{},
1662 "eu-west-1": endpoint{}, 1933 "ap-northeast-2": endpoint{},
1663 "us-east-1": endpoint{}, 1934 "ap-southeast-1": endpoint{},
1664 "us-east-2": endpoint{}, 1935 "ap-southeast-2": endpoint{},
1665 "us-west-2": endpoint{}, 1936 "eu-central-1": endpoint{},
1937 "eu-west-1": endpoint{},
1938 "eu-west-2": endpoint{},
1939 "us-east-1": endpoint{},
1940 "us-east-2": endpoint{},
1941 "us-west-2": endpoint{},
1666 }, 1942 },
1667 }, 1943 },
1668 "kinesisvideo": service{ 1944 "kinesisvideo": service{
@@ -1679,12 +1955,6 @@ var awsPartition = partition{
1679 "kms": service{ 1955 "kms": service{
1680 1956
1681 Endpoints: endpoints{ 1957 Endpoints: endpoints{
1682 "ProdFips": endpoint{
1683 Hostname: "kms-fips.ca-central-1.amazonaws.com",
1684 CredentialScope: credentialScope{
1685 Region: "ca-central-1",
1686 },
1687 },
1688 "ap-east-1": endpoint{}, 1958 "ap-east-1": endpoint{},
1689 "ap-northeast-1": endpoint{}, 1959 "ap-northeast-1": endpoint{},
1690 "ap-northeast-2": endpoint{}, 1960 "ap-northeast-2": endpoint{},
@@ -1697,6 +1967,7 @@ var awsPartition = partition{
1697 "eu-west-1": endpoint{}, 1967 "eu-west-1": endpoint{},
1698 "eu-west-2": endpoint{}, 1968 "eu-west-2": endpoint{},
1699 "eu-west-3": endpoint{}, 1969 "eu-west-3": endpoint{},
1970 "me-south-1": endpoint{},
1700 "sa-east-1": endpoint{}, 1971 "sa-east-1": endpoint{},
1701 "us-east-1": endpoint{}, 1972 "us-east-1": endpoint{},
1702 "us-east-2": endpoint{}, 1973 "us-east-2": endpoint{},
@@ -1719,6 +1990,7 @@ var awsPartition = partition{
1719 "eu-west-1": endpoint{}, 1990 "eu-west-1": endpoint{},
1720 "eu-west-2": endpoint{}, 1991 "eu-west-2": endpoint{},
1721 "eu-west-3": endpoint{}, 1992 "eu-west-3": endpoint{},
1993 "me-south-1": endpoint{},
1722 "sa-east-1": endpoint{}, 1994 "sa-east-1": endpoint{},
1723 "us-east-1": endpoint{}, 1995 "us-east-1": endpoint{},
1724 "us-east-2": endpoint{}, 1996 "us-east-2": endpoint{},
@@ -1729,16 +2001,22 @@ var awsPartition = partition{
1729 "license-manager": service{ 2001 "license-manager": service{
1730 2002
1731 Endpoints: endpoints{ 2003 Endpoints: endpoints{
2004 "ap-east-1": endpoint{},
1732 "ap-northeast-1": endpoint{}, 2005 "ap-northeast-1": endpoint{},
1733 "ap-northeast-2": endpoint{}, 2006 "ap-northeast-2": endpoint{},
1734 "ap-south-1": endpoint{}, 2007 "ap-south-1": endpoint{},
1735 "ap-southeast-1": endpoint{}, 2008 "ap-southeast-1": endpoint{},
1736 "ap-southeast-2": endpoint{}, 2009 "ap-southeast-2": endpoint{},
2010 "ca-central-1": endpoint{},
1737 "eu-central-1": endpoint{}, 2011 "eu-central-1": endpoint{},
2012 "eu-north-1": endpoint{},
1738 "eu-west-1": endpoint{}, 2013 "eu-west-1": endpoint{},
1739 "eu-west-2": endpoint{}, 2014 "eu-west-2": endpoint{},
2015 "eu-west-3": endpoint{},
2016 "sa-east-1": endpoint{},
1740 "us-east-1": endpoint{}, 2017 "us-east-1": endpoint{},
1741 "us-east-2": endpoint{}, 2018 "us-east-2": endpoint{},
2019 "us-west-1": endpoint{},
1742 "us-west-2": endpoint{}, 2020 "us-west-2": endpoint{},
1743 }, 2021 },
1744 }, 2022 },
@@ -1775,6 +2053,7 @@ var awsPartition = partition{
1775 "eu-west-1": endpoint{}, 2053 "eu-west-1": endpoint{},
1776 "eu-west-2": endpoint{}, 2054 "eu-west-2": endpoint{},
1777 "eu-west-3": endpoint{}, 2055 "eu-west-3": endpoint{},
2056 "me-south-1": endpoint{},
1778 "sa-east-1": endpoint{}, 2057 "sa-east-1": endpoint{},
1779 "us-east-1": endpoint{}, 2058 "us-east-1": endpoint{},
1780 "us-east-2": endpoint{}, 2059 "us-east-2": endpoint{},
@@ -1843,6 +2122,7 @@ var awsPartition = partition{
1843 "ap-southeast-1": endpoint{}, 2122 "ap-southeast-1": endpoint{},
1844 "ap-southeast-2": endpoint{}, 2123 "ap-southeast-2": endpoint{},
1845 "eu-central-1": endpoint{}, 2124 "eu-central-1": endpoint{},
2125 "eu-north-1": endpoint{},
1846 "eu-west-1": endpoint{}, 2126 "eu-west-1": endpoint{},
1847 "sa-east-1": endpoint{}, 2127 "sa-east-1": endpoint{},
1848 "us-east-1": endpoint{}, 2128 "us-east-1": endpoint{},
@@ -1873,6 +2153,7 @@ var awsPartition = partition{
1873 "ap-northeast-2": endpoint{}, 2153 "ap-northeast-2": endpoint{},
1874 "ap-southeast-2": endpoint{}, 2154 "ap-southeast-2": endpoint{},
1875 "eu-central-1": endpoint{}, 2155 "eu-central-1": endpoint{},
2156 "eu-north-1": endpoint{},
1876 "eu-west-1": endpoint{}, 2157 "eu-west-1": endpoint{},
1877 "us-east-1": endpoint{}, 2158 "us-east-1": endpoint{},
1878 "us-west-2": endpoint{}, 2159 "us-west-2": endpoint{},
@@ -1945,6 +2226,7 @@ var awsPartition = partition{
1945 "eu-west-1": endpoint{}, 2226 "eu-west-1": endpoint{},
1946 "eu-west-2": endpoint{}, 2227 "eu-west-2": endpoint{},
1947 "eu-west-3": endpoint{}, 2228 "eu-west-3": endpoint{},
2229 "me-south-1": endpoint{},
1948 "sa-east-1": endpoint{}, 2230 "sa-east-1": endpoint{},
1949 "us-east-1": endpoint{}, 2231 "us-east-1": endpoint{},
1950 "us-east-2": endpoint{}, 2232 "us-east-2": endpoint{},
@@ -1957,11 +2239,14 @@ var awsPartition = partition{
1957 Endpoints: endpoints{ 2239 Endpoints: endpoints{
1958 "ap-northeast-1": endpoint{}, 2240 "ap-northeast-1": endpoint{},
1959 "ap-northeast-2": endpoint{}, 2241 "ap-northeast-2": endpoint{},
2242 "ap-south-1": endpoint{},
1960 "ap-southeast-1": endpoint{}, 2243 "ap-southeast-1": endpoint{},
1961 "ap-southeast-2": endpoint{}, 2244 "ap-southeast-2": endpoint{},
2245 "ca-central-1": endpoint{},
1962 "eu-central-1": endpoint{}, 2246 "eu-central-1": endpoint{},
1963 "eu-west-1": endpoint{}, 2247 "eu-west-1": endpoint{},
1964 "eu-west-2": endpoint{}, 2248 "eu-west-2": endpoint{},
2249 "eu-west-3": endpoint{},
1965 "us-east-1": endpoint{}, 2250 "us-east-1": endpoint{},
1966 "us-east-2": endpoint{}, 2251 "us-east-2": endpoint{},
1967 "us-west-1": endpoint{}, 2252 "us-west-1": endpoint{},
@@ -1987,6 +2272,12 @@ var awsPartition = partition{
1987 Region: "ap-northeast-1", 2272 Region: "ap-northeast-1",
1988 }, 2273 },
1989 }, 2274 },
2275 "ap-northeast-2": endpoint{
2276 Hostname: "rds.ap-northeast-2.amazonaws.com",
2277 CredentialScope: credentialScope{
2278 Region: "ap-northeast-2",
2279 },
2280 },
1990 "ap-south-1": endpoint{ 2281 "ap-south-1": endpoint{
1991 Hostname: "rds.ap-south-1.amazonaws.com", 2282 Hostname: "rds.ap-south-1.amazonaws.com",
1992 CredentialScope: credentialScope{ 2283 CredentialScope: credentialScope{
@@ -2011,6 +2302,12 @@ var awsPartition = partition{
2011 Region: "eu-central-1", 2302 Region: "eu-central-1",
2012 }, 2303 },
2013 }, 2304 },
2305 "eu-north-1": endpoint{
2306 Hostname: "rds.eu-north-1.amazonaws.com",
2307 CredentialScope: credentialScope{
2308 Region: "eu-north-1",
2309 },
2310 },
2014 "eu-west-1": endpoint{ 2311 "eu-west-1": endpoint{
2015 Hostname: "rds.eu-west-1.amazonaws.com", 2312 Hostname: "rds.eu-west-1.amazonaws.com",
2016 CredentialScope: credentialScope{ 2313 CredentialScope: credentialScope{
@@ -2126,6 +2423,38 @@ var awsPartition = partition{
2126 "us-west-2": endpoint{}, 2423 "us-west-2": endpoint{},
2127 }, 2424 },
2128 }, 2425 },
2426 "projects.iot1click": service{
2427
2428 Endpoints: endpoints{
2429 "ap-northeast-1": endpoint{},
2430 "eu-central-1": endpoint{},
2431 "eu-west-1": endpoint{},
2432 "eu-west-2": endpoint{},
2433 "us-east-1": endpoint{},
2434 "us-east-2": endpoint{},
2435 "us-west-2": endpoint{},
2436 },
2437 },
2438 "ram": service{
2439
2440 Endpoints: endpoints{
2441 "ap-northeast-1": endpoint{},
2442 "ap-northeast-2": endpoint{},
2443 "ap-south-1": endpoint{},
2444 "ap-southeast-1": endpoint{},
2445 "ap-southeast-2": endpoint{},
2446 "ca-central-1": endpoint{},
2447 "eu-central-1": endpoint{},
2448 "eu-north-1": endpoint{},
2449 "eu-west-1": endpoint{},
2450 "eu-west-2": endpoint{},
2451 "eu-west-3": endpoint{},
2452 "us-east-1": endpoint{},
2453 "us-east-2": endpoint{},
2454 "us-west-1": endpoint{},
2455 "us-west-2": endpoint{},
2456 },
2457 },
2129 "rds": service{ 2458 "rds": service{
2130 2459
2131 Endpoints: endpoints{ 2460 Endpoints: endpoints{
@@ -2165,6 +2494,7 @@ var awsPartition = partition{
2165 "eu-west-1": endpoint{}, 2494 "eu-west-1": endpoint{},
2166 "eu-west-2": endpoint{}, 2495 "eu-west-2": endpoint{},
2167 "eu-west-3": endpoint{}, 2496 "eu-west-3": endpoint{},
2497 "me-south-1": endpoint{},
2168 "sa-east-1": endpoint{}, 2498 "sa-east-1": endpoint{},
2169 "us-east-1": endpoint{}, 2499 "us-east-1": endpoint{},
2170 "us-east-2": endpoint{}, 2500 "us-east-2": endpoint{},
@@ -2178,10 +2508,14 @@ var awsPartition = partition{
2178 "ap-northeast-1": endpoint{}, 2508 "ap-northeast-1": endpoint{},
2179 "ap-northeast-2": endpoint{}, 2509 "ap-northeast-2": endpoint{},
2180 "ap-south-1": endpoint{}, 2510 "ap-south-1": endpoint{},
2511 "ap-southeast-1": endpoint{},
2181 "ap-southeast-2": endpoint{}, 2512 "ap-southeast-2": endpoint{},
2513 "eu-central-1": endpoint{},
2182 "eu-west-1": endpoint{}, 2514 "eu-west-1": endpoint{},
2515 "eu-west-2": endpoint{},
2183 "us-east-1": endpoint{}, 2516 "us-east-1": endpoint{},
2184 "us-east-2": endpoint{}, 2517 "us-east-2": endpoint{},
2518 "us-west-1": endpoint{},
2185 "us-west-2": endpoint{}, 2519 "us-west-2": endpoint{},
2186 }, 2520 },
2187 }, 2521 },
@@ -2200,6 +2534,7 @@ var awsPartition = partition{
2200 "eu-west-1": endpoint{}, 2534 "eu-west-1": endpoint{},
2201 "eu-west-2": endpoint{}, 2535 "eu-west-2": endpoint{},
2202 "eu-west-3": endpoint{}, 2536 "eu-west-3": endpoint{},
2537 "me-south-1": endpoint{},
2203 "sa-east-1": endpoint{}, 2538 "sa-east-1": endpoint{},
2204 "us-east-1": endpoint{}, 2539 "us-east-1": endpoint{},
2205 "us-east-2": endpoint{}, 2540 "us-east-2": endpoint{},
@@ -2211,8 +2546,11 @@ var awsPartition = partition{
2211 2546
2212 Endpoints: endpoints{ 2547 Endpoints: endpoints{
2213 "ap-northeast-1": endpoint{}, 2548 "ap-northeast-1": endpoint{},
2549 "ap-southeast-1": endpoint{},
2550 "eu-central-1": endpoint{},
2214 "eu-west-1": endpoint{}, 2551 "eu-west-1": endpoint{},
2215 "us-east-1": endpoint{}, 2552 "us-east-1": endpoint{},
2553 "us-east-2": endpoint{},
2216 "us-west-2": endpoint{}, 2554 "us-west-2": endpoint{},
2217 }, 2555 },
2218 }, 2556 },
@@ -2281,9 +2619,33 @@ var awsPartition = partition{
2281 "eu-west-1": endpoint{}, 2619 "eu-west-1": endpoint{},
2282 "eu-west-2": endpoint{}, 2620 "eu-west-2": endpoint{},
2283 "us-east-1": endpoint{}, 2621 "us-east-1": endpoint{},
2284 "us-east-2": endpoint{}, 2622 "us-east-1-fips": endpoint{
2285 "us-west-1": endpoint{}, 2623 Hostname: "runtime-fips.sagemaker.us-east-1.amazonaws.com",
2286 "us-west-2": endpoint{}, 2624 CredentialScope: credentialScope{
2625 Region: "us-east-1",
2626 },
2627 },
2628 "us-east-2": endpoint{},
2629 "us-east-2-fips": endpoint{
2630 Hostname: "runtime-fips.sagemaker.us-east-2.amazonaws.com",
2631 CredentialScope: credentialScope{
2632 Region: "us-east-2",
2633 },
2634 },
2635 "us-west-1": endpoint{},
2636 "us-west-1-fips": endpoint{
2637 Hostname: "runtime-fips.sagemaker.us-west-1.amazonaws.com",
2638 CredentialScope: credentialScope{
2639 Region: "us-west-1",
2640 },
2641 },
2642 "us-west-2": endpoint{},
2643 "us-west-2-fips": endpoint{
2644 Hostname: "runtime-fips.sagemaker.us-west-2.amazonaws.com",
2645 CredentialScope: credentialScope{
2646 Region: "us-west-2",
2647 },
2648 },
2287 }, 2649 },
2288 }, 2650 },
2289 "s3": service{ 2651 "s3": service{
@@ -2319,8 +2681,9 @@ var awsPartition = partition{
2319 Hostname: "s3.eu-west-1.amazonaws.com", 2681 Hostname: "s3.eu-west-1.amazonaws.com",
2320 SignatureVersions: []string{"s3", "s3v4"}, 2682 SignatureVersions: []string{"s3", "s3v4"},
2321 }, 2683 },
2322 "eu-west-2": endpoint{}, 2684 "eu-west-2": endpoint{},
2323 "eu-west-3": endpoint{}, 2685 "eu-west-3": endpoint{},
2686 "me-south-1": endpoint{},
2324 "s3-external-1": endpoint{ 2687 "s3-external-1": endpoint{
2325 Hostname: "s3-external-1.amazonaws.com", 2688 Hostname: "s3-external-1.amazonaws.com",
2326 SignatureVersions: []string{"s3", "s3v4"}, 2689 SignatureVersions: []string{"s3", "s3v4"},
@@ -2571,6 +2934,7 @@ var awsPartition = partition{
2571 "ap-southeast-2": endpoint{}, 2934 "ap-southeast-2": endpoint{},
2572 "ca-central-1": endpoint{}, 2935 "ca-central-1": endpoint{},
2573 "eu-central-1": endpoint{}, 2936 "eu-central-1": endpoint{},
2937 "eu-north-1": endpoint{},
2574 "eu-west-1": endpoint{}, 2938 "eu-west-1": endpoint{},
2575 "eu-west-2": endpoint{}, 2939 "eu-west-2": endpoint{},
2576 "eu-west-3": endpoint{}, 2940 "eu-west-3": endpoint{},
@@ -2714,6 +3078,7 @@ var awsPartition = partition{
2714 "sms": service{ 3078 "sms": service{
2715 3079
2716 Endpoints: endpoints{ 3080 Endpoints: endpoints{
3081 "ap-east-1": endpoint{},
2717 "ap-northeast-1": endpoint{}, 3082 "ap-northeast-1": endpoint{},
2718 "ap-northeast-2": endpoint{}, 3083 "ap-northeast-2": endpoint{},
2719 "ap-south-1": endpoint{}, 3084 "ap-south-1": endpoint{},
@@ -2736,6 +3101,7 @@ var awsPartition = partition{
2736 3101
2737 Endpoints: endpoints{ 3102 Endpoints: endpoints{
2738 "ap-northeast-1": endpoint{}, 3103 "ap-northeast-1": endpoint{},
3104 "ap-northeast-2": endpoint{},
2739 "ap-south-1": endpoint{}, 3105 "ap-south-1": endpoint{},
2740 "ap-southeast-1": endpoint{}, 3106 "ap-southeast-1": endpoint{},
2741 "ap-southeast-2": endpoint{}, 3107 "ap-southeast-2": endpoint{},
@@ -2768,6 +3134,7 @@ var awsPartition = partition{
2768 "eu-west-1": endpoint{}, 3134 "eu-west-1": endpoint{},
2769 "eu-west-2": endpoint{}, 3135 "eu-west-2": endpoint{},
2770 "eu-west-3": endpoint{}, 3136 "eu-west-3": endpoint{},
3137 "me-south-1": endpoint{},
2771 "sa-east-1": endpoint{}, 3138 "sa-east-1": endpoint{},
2772 "us-east-1": endpoint{}, 3139 "us-east-1": endpoint{},
2773 "us-east-2": endpoint{}, 3140 "us-east-2": endpoint{},
@@ -2817,7 +3184,8 @@ var awsPartition = partition{
2817 Region: "us-west-2", 3184 Region: "us-west-2",
2818 }, 3185 },
2819 }, 3186 },
2820 "sa-east-1": endpoint{}, 3187 "me-south-1": endpoint{},
3188 "sa-east-1": endpoint{},
2821 "us-east-1": endpoint{ 3189 "us-east-1": endpoint{
2822 SSLCommonName: "queue.{dnsSuffix}", 3190 SSLCommonName: "queue.{dnsSuffix}",
2823 }, 3191 },
@@ -2841,6 +3209,7 @@ var awsPartition = partition{
2841 "eu-west-1": endpoint{}, 3209 "eu-west-1": endpoint{},
2842 "eu-west-2": endpoint{}, 3210 "eu-west-2": endpoint{},
2843 "eu-west-3": endpoint{}, 3211 "eu-west-3": endpoint{},
3212 "me-south-1": endpoint{},
2844 "sa-east-1": endpoint{}, 3213 "sa-east-1": endpoint{},
2845 "us-east-1": endpoint{}, 3214 "us-east-1": endpoint{},
2846 "us-east-2": endpoint{}, 3215 "us-east-2": endpoint{},
@@ -2863,6 +3232,7 @@ var awsPartition = partition{
2863 "eu-west-1": endpoint{}, 3232 "eu-west-1": endpoint{},
2864 "eu-west-2": endpoint{}, 3233 "eu-west-2": endpoint{},
2865 "eu-west-3": endpoint{}, 3234 "eu-west-3": endpoint{},
3235 "me-south-1": endpoint{},
2866 "sa-east-1": endpoint{}, 3236 "sa-east-1": endpoint{},
2867 "us-east-1": endpoint{}, 3237 "us-east-1": endpoint{},
2868 "us-east-2": endpoint{}, 3238 "us-east-2": endpoint{},
@@ -2884,6 +3254,7 @@ var awsPartition = partition{
2884 "eu-west-1": endpoint{}, 3254 "eu-west-1": endpoint{},
2885 "eu-west-2": endpoint{}, 3255 "eu-west-2": endpoint{},
2886 "eu-west-3": endpoint{}, 3256 "eu-west-3": endpoint{},
3257 "me-south-1": endpoint{},
2887 "sa-east-1": endpoint{}, 3258 "sa-east-1": endpoint{},
2888 "us-east-1": endpoint{}, 3259 "us-east-1": endpoint{},
2889 "us-east-2": endpoint{}, 3260 "us-east-2": endpoint{},
@@ -2905,11 +3276,17 @@ var awsPartition = partition{
2905 "ap-southeast-1": endpoint{}, 3276 "ap-southeast-1": endpoint{},
2906 "ap-southeast-2": endpoint{}, 3277 "ap-southeast-2": endpoint{},
2907 "ca-central-1": endpoint{}, 3278 "ca-central-1": endpoint{},
2908 "eu-central-1": endpoint{}, 3279 "ca-central-1-fips": endpoint{
2909 "eu-north-1": endpoint{}, 3280 Hostname: "dynamodb-fips.ca-central-1.amazonaws.com",
2910 "eu-west-1": endpoint{}, 3281 CredentialScope: credentialScope{
2911 "eu-west-2": endpoint{}, 3282 Region: "ca-central-1",
2912 "eu-west-3": endpoint{}, 3283 },
3284 },
3285 "eu-central-1": endpoint{},
3286 "eu-north-1": endpoint{},
3287 "eu-west-1": endpoint{},
3288 "eu-west-2": endpoint{},
3289 "eu-west-3": endpoint{},
2913 "local": endpoint{ 3290 "local": endpoint{
2914 Hostname: "localhost:8000", 3291 Hostname: "localhost:8000",
2915 Protocols: []string{"http"}, 3292 Protocols: []string{"http"},
@@ -2917,11 +3294,36 @@ var awsPartition = partition{
2917 Region: "us-east-1", 3294 Region: "us-east-1",
2918 }, 3295 },
2919 }, 3296 },
2920 "sa-east-1": endpoint{}, 3297 "me-south-1": endpoint{},
2921 "us-east-1": endpoint{}, 3298 "sa-east-1": endpoint{},
3299 "us-east-1": endpoint{},
3300 "us-east-1-fips": endpoint{
3301 Hostname: "dynamodb-fips.us-east-1.amazonaws.com",
3302 CredentialScope: credentialScope{
3303 Region: "us-east-1",
3304 },
3305 },
2922 "us-east-2": endpoint{}, 3306 "us-east-2": endpoint{},
3307 "us-east-2-fips": endpoint{
3308 Hostname: "dynamodb-fips.us-east-2.amazonaws.com",
3309 CredentialScope: credentialScope{
3310 Region: "us-east-2",
3311 },
3312 },
2923 "us-west-1": endpoint{}, 3313 "us-west-1": endpoint{},
3314 "us-west-1-fips": endpoint{
3315 Hostname: "dynamodb-fips.us-west-1.amazonaws.com",
3316 CredentialScope: credentialScope{
3317 Region: "us-west-1",
3318 },
3319 },
2924 "us-west-2": endpoint{}, 3320 "us-west-2": endpoint{},
3321 "us-west-2-fips": endpoint{
3322 Hostname: "dynamodb-fips.us-west-2.amazonaws.com",
3323 CredentialScope: credentialScope{
3324 Region: "us-west-2",
3325 },
3326 },
2925 }, 3327 },
2926 }, 3328 },
2927 "sts": service{ 3329 "sts": service{
@@ -2956,8 +3358,14 @@ var awsPartition = partition{
2956 "eu-west-1": endpoint{}, 3358 "eu-west-1": endpoint{},
2957 "eu-west-2": endpoint{}, 3359 "eu-west-2": endpoint{},
2958 "eu-west-3": endpoint{}, 3360 "eu-west-3": endpoint{},
2959 "sa-east-1": endpoint{}, 3361 "me-south-1": endpoint{
2960 "us-east-1": endpoint{}, 3362 Hostname: "sts.me-south-1.amazonaws.com",
3363 CredentialScope: credentialScope{
3364 Region: "me-south-1",
3365 },
3366 },
3367 "sa-east-1": endpoint{},
3368 "us-east-1": endpoint{},
2961 "us-east-1-fips": endpoint{ 3369 "us-east-1-fips": endpoint{
2962 Hostname: "sts-fips.us-east-1.amazonaws.com", 3370 Hostname: "sts-fips.us-east-1.amazonaws.com",
2963 CredentialScope: credentialScope{ 3371 CredentialScope: credentialScope{
@@ -2988,9 +3396,15 @@ var awsPartition = partition{
2988 }, 3396 },
2989 }, 3397 },
2990 "support": service{ 3398 "support": service{
3399 PartitionEndpoint: "aws-global",
2991 3400
2992 Endpoints: endpoints{ 3401 Endpoints: endpoints{
2993 "us-east-1": endpoint{}, 3402 "aws-global": endpoint{
3403 Hostname: "support.us-east-1.amazonaws.com",
3404 CredentialScope: credentialScope{
3405 Region: "us-east-1",
3406 },
3407 },
2994 }, 3408 },
2995 }, 3409 },
2996 "swf": service{ 3410 "swf": service{
@@ -3008,6 +3422,7 @@ var awsPartition = partition{
3008 "eu-west-1": endpoint{}, 3422 "eu-west-1": endpoint{},
3009 "eu-west-2": endpoint{}, 3423 "eu-west-2": endpoint{},
3010 "eu-west-3": endpoint{}, 3424 "eu-west-3": endpoint{},
3425 "me-south-1": endpoint{},
3011 "sa-east-1": endpoint{}, 3426 "sa-east-1": endpoint{},
3012 "us-east-1": endpoint{}, 3427 "us-east-1": endpoint{},
3013 "us-east-2": endpoint{}, 3428 "us-east-2": endpoint{},
@@ -3030,6 +3445,7 @@ var awsPartition = partition{
3030 "eu-west-1": endpoint{}, 3445 "eu-west-1": endpoint{},
3031 "eu-west-2": endpoint{}, 3446 "eu-west-2": endpoint{},
3032 "eu-west-3": endpoint{}, 3447 "eu-west-3": endpoint{},
3448 "me-south-1": endpoint{},
3033 "sa-east-1": endpoint{}, 3449 "sa-east-1": endpoint{},
3034 "us-east-1": endpoint{}, 3450 "us-east-1": endpoint{},
3035 "us-east-2": endpoint{}, 3451 "us-east-2": endpoint{},
@@ -3061,7 +3477,11 @@ var awsPartition = partition{
3061 Protocols: []string{"https"}, 3477 Protocols: []string{"https"},
3062 }, 3478 },
3063 Endpoints: endpoints{ 3479 Endpoints: endpoints{
3480 "ap-northeast-1": endpoint{},
3064 "ap-northeast-2": endpoint{}, 3481 "ap-northeast-2": endpoint{},
3482 "ap-south-1": endpoint{},
3483 "ap-southeast-1": endpoint{},
3484 "ca-central-1": endpoint{},
3065 "eu-central-1": endpoint{}, 3485 "eu-central-1": endpoint{},
3066 "eu-west-1": endpoint{}, 3486 "eu-west-1": endpoint{},
3067 "us-east-1": endpoint{}, 3487 "us-east-1": endpoint{},
@@ -3105,12 +3525,16 @@ var awsPartition = partition{
3105 Endpoints: endpoints{ 3525 Endpoints: endpoints{
3106 "ap-northeast-1": endpoint{}, 3526 "ap-northeast-1": endpoint{},
3107 "ap-northeast-2": endpoint{}, 3527 "ap-northeast-2": endpoint{},
3528 "ap-south-1": endpoint{},
3108 "ap-southeast-1": endpoint{}, 3529 "ap-southeast-1": endpoint{},
3109 "ap-southeast-2": endpoint{}, 3530 "ap-southeast-2": endpoint{},
3531 "ca-central-1": endpoint{},
3110 "eu-central-1": endpoint{}, 3532 "eu-central-1": endpoint{},
3111 "eu-north-1": endpoint{}, 3533 "eu-north-1": endpoint{},
3112 "eu-west-1": endpoint{}, 3534 "eu-west-1": endpoint{},
3113 "eu-west-2": endpoint{}, 3535 "eu-west-2": endpoint{},
3536 "eu-west-3": endpoint{},
3537 "sa-east-1": endpoint{},
3114 "us-east-1": endpoint{}, 3538 "us-east-1": endpoint{},
3115 "us-east-2": endpoint{}, 3539 "us-east-2": endpoint{},
3116 "us-west-1": endpoint{}, 3540 "us-west-1": endpoint{},
@@ -3157,6 +3581,7 @@ var awsPartition = partition{
3157 "xray": service{ 3581 "xray": service{
3158 3582
3159 Endpoints: endpoints{ 3583 Endpoints: endpoints{
3584 "ap-east-1": endpoint{},
3160 "ap-northeast-1": endpoint{}, 3585 "ap-northeast-1": endpoint{},
3161 "ap-northeast-2": endpoint{}, 3586 "ap-northeast-2": endpoint{},
3162 "ap-south-1": endpoint{}, 3587 "ap-south-1": endpoint{},
@@ -3433,6 +3858,15 @@ var awscnPartition = partition{
3433 "cn-northwest-1": endpoint{}, 3858 "cn-northwest-1": endpoint{},
3434 }, 3859 },
3435 }, 3860 },
3861 "greengrass": service{
3862 IsRegionalized: boxedTrue,
3863 Defaults: endpoint{
3864 Protocols: []string{"https"},
3865 },
3866 Endpoints: endpoints{
3867 "cn-north-1": endpoint{},
3868 },
3869 },
3436 "iam": service{ 3870 "iam": service{
3437 PartitionEndpoint: "aws-cn-global", 3871 PartitionEndpoint: "aws-cn-global",
3438 IsRegionalized: boxedFalse, 3872 IsRegionalized: boxedFalse,
@@ -3463,6 +3897,13 @@ var awscnPartition = partition{
3463 "cn-northwest-1": endpoint{}, 3897 "cn-northwest-1": endpoint{},
3464 }, 3898 },
3465 }, 3899 },
3900 "kms": service{
3901
3902 Endpoints: endpoints{
3903 "cn-north-1": endpoint{},
3904 "cn-northwest-1": endpoint{},
3905 },
3906 },
3466 "lambda": service{ 3907 "lambda": service{
3467 3908
3468 Endpoints: endpoints{ 3909 Endpoints: endpoints{
@@ -3470,6 +3911,13 @@ var awscnPartition = partition{
3470 "cn-northwest-1": endpoint{}, 3911 "cn-northwest-1": endpoint{},
3471 }, 3912 },
3472 }, 3913 },
3914 "license-manager": service{
3915
3916 Endpoints: endpoints{
3917 "cn-north-1": endpoint{},
3918 "cn-northwest-1": endpoint{},
3919 },
3920 },
3473 "logs": service{ 3921 "logs": service{
3474 3922
3475 Endpoints: endpoints{ 3923 Endpoints: endpoints{
@@ -3480,7 +3928,12 @@ var awscnPartition = partition{
3480 "mediaconvert": service{ 3928 "mediaconvert": service{
3481 3929
3482 Endpoints: endpoints{ 3930 Endpoints: endpoints{
3483 "cn-northwest-1": endpoint{}, 3931 "cn-northwest-1": endpoint{
3932 Hostname: "subscribe.mediaconvert.cn-northwest-1.amazonaws.com.cn",
3933 CredentialScope: credentialScope{
3934 Region: "cn-northwest-1",
3935 },
3936 },
3484 }, 3937 },
3485 }, 3938 },
3486 "monitoring": service{ 3939 "monitoring": service{
@@ -3615,6 +4068,18 @@ var awscnPartition = partition{
3615 "cn-northwest-1": endpoint{}, 4068 "cn-northwest-1": endpoint{},
3616 }, 4069 },
3617 }, 4070 },
4071 "support": service{
4072 PartitionEndpoint: "aws-cn-global",
4073
4074 Endpoints: endpoints{
4075 "aws-cn-global": endpoint{
4076 Hostname: "support.cn-north-1.amazonaws.com",
4077 CredentialScope: credentialScope{
4078 Region: "cn-north-1",
4079 },
4080 },
4081 },
4082 },
3618 "swf": service{ 4083 "swf": service{
3619 4084
3620 Endpoints: endpoints{ 4085 Endpoints: endpoints{
@@ -3668,6 +4133,15 @@ var awsusgovPartition = partition{
3668 "us-gov-west-1": endpoint{}, 4133 "us-gov-west-1": endpoint{},
3669 }, 4134 },
3670 }, 4135 },
4136 "acm-pca": service{
4137 Defaults: endpoint{
4138 Protocols: []string{"https"},
4139 },
4140 Endpoints: endpoints{
4141 "us-gov-east-1": endpoint{},
4142 "us-gov-west-1": endpoint{},
4143 },
4144 },
3671 "api.ecr": service{ 4145 "api.ecr": service{
3672 4146
3673 Endpoints: endpoints{ 4147 Endpoints: endpoints{
@@ -3713,6 +4187,7 @@ var awsusgovPartition = partition{
3713 "athena": service{ 4187 "athena": service{
3714 4188
3715 Endpoints: endpoints{ 4189 Endpoints: endpoints{
4190 "us-gov-east-1": endpoint{},
3716 "us-gov-west-1": endpoint{}, 4191 "us-gov-west-1": endpoint{},
3717 }, 4192 },
3718 }, 4193 },
@@ -3762,9 +4237,17 @@ var awsusgovPartition = partition{
3762 "us-gov-west-1": endpoint{}, 4237 "us-gov-west-1": endpoint{},
3763 }, 4238 },
3764 }, 4239 },
4240 "codebuild": service{
4241
4242 Endpoints: endpoints{
4243 "us-gov-east-1": endpoint{},
4244 "us-gov-west-1": endpoint{},
4245 },
4246 },
3765 "codecommit": service{ 4247 "codecommit": service{
3766 4248
3767 Endpoints: endpoints{ 4249 Endpoints: endpoints{
4250 "us-gov-east-1": endpoint{},
3768 "us-gov-west-1": endpoint{}, 4251 "us-gov-west-1": endpoint{},
3769 }, 4252 },
3770 }, 4253 },
@@ -3802,6 +4285,12 @@ var awsusgovPartition = partition{
3802 "us-gov-west-1": endpoint{}, 4285 "us-gov-west-1": endpoint{},
3803 }, 4286 },
3804 }, 4287 },
4288 "datasync": service{
4289
4290 Endpoints: endpoints{
4291 "us-gov-west-1": endpoint{},
4292 },
4293 },
3805 "directconnect": service{ 4294 "directconnect": service{
3806 4295
3807 Endpoints: endpoints{ 4296 Endpoints: endpoints{
@@ -3819,6 +4308,7 @@ var awsusgovPartition = partition{
3819 "ds": service{ 4308 "ds": service{
3820 4309
3821 Endpoints: endpoints{ 4310 Endpoints: endpoints{
4311 "us-gov-east-1": endpoint{},
3822 "us-gov-west-1": endpoint{}, 4312 "us-gov-west-1": endpoint{},
3823 }, 4313 },
3824 }, 4314 },
@@ -3826,6 +4316,12 @@ var awsusgovPartition = partition{
3826 4316
3827 Endpoints: endpoints{ 4317 Endpoints: endpoints{
3828 "us-gov-east-1": endpoint{}, 4318 "us-gov-east-1": endpoint{},
4319 "us-gov-east-1-fips": endpoint{
4320 Hostname: "dynamodb.us-gov-east-1.amazonaws.com",
4321 CredentialScope: credentialScope{
4322 Region: "us-gov-east-1",
4323 },
4324 },
3829 "us-gov-west-1": endpoint{}, 4325 "us-gov-west-1": endpoint{},
3830 "us-gov-west-1-fips": endpoint{ 4326 "us-gov-west-1-fips": endpoint{
3831 Hostname: "dynamodb.us-gov-west-1.amazonaws.com", 4327 Hostname: "dynamodb.us-gov-west-1.amazonaws.com",
@@ -3927,6 +4423,7 @@ var awsusgovPartition = partition{
3927 "firehose": service{ 4423 "firehose": service{
3928 4424
3929 Endpoints: endpoints{ 4425 Endpoints: endpoints{
4426 "us-gov-east-1": endpoint{},
3930 "us-gov-west-1": endpoint{}, 4427 "us-gov-west-1": endpoint{},
3931 }, 4428 },
3932 }, 4429 },
@@ -3942,6 +4439,16 @@ var awsusgovPartition = partition{
3942 "glue": service{ 4439 "glue": service{
3943 4440
3944 Endpoints: endpoints{ 4441 Endpoints: endpoints{
4442 "us-gov-east-1": endpoint{},
4443 "us-gov-west-1": endpoint{},
4444 },
4445 },
4446 "greengrass": service{
4447 IsRegionalized: boxedTrue,
4448 Defaults: endpoint{
4449 Protocols: []string{"https"},
4450 },
4451 Endpoints: endpoints{
3945 "us-gov-west-1": endpoint{}, 4452 "us-gov-west-1": endpoint{},
3946 }, 4453 },
3947 }, 4454 },
@@ -4048,12 +4555,31 @@ var awsusgovPartition = partition{
4048 "us-gov-west-1": endpoint{}, 4555 "us-gov-west-1": endpoint{},
4049 }, 4556 },
4050 }, 4557 },
4558 "organizations": service{
4559 PartitionEndpoint: "aws-us-gov-global",
4560 IsRegionalized: boxedFalse,
4561
4562 Endpoints: endpoints{
4563 "aws-us-gov-global": endpoint{
4564 Hostname: "organizations.us-gov-west-1.amazonaws.com",
4565 CredentialScope: credentialScope{
4566 Region: "us-gov-west-1",
4567 },
4568 },
4569 },
4570 },
4051 "polly": service{ 4571 "polly": service{
4052 4572
4053 Endpoints: endpoints{ 4573 Endpoints: endpoints{
4054 "us-gov-west-1": endpoint{}, 4574 "us-gov-west-1": endpoint{},
4055 }, 4575 },
4056 }, 4576 },
4577 "ram": service{
4578
4579 Endpoints: endpoints{
4580 "us-gov-west-1": endpoint{},
4581 },
4582 },
4057 "rds": service{ 4583 "rds": service{
4058 4584
4059 Endpoints: endpoints{ 4585 Endpoints: endpoints{
@@ -4137,6 +4663,28 @@ var awsusgovPartition = partition{
4137 }, 4663 },
4138 }, 4664 },
4139 }, 4665 },
4666 "secretsmanager": service{
4667
4668 Endpoints: endpoints{
4669 "us-gov-west-1": endpoint{},
4670 "us-gov-west-1-fips": endpoint{
4671 Hostname: "secretsmanager-fips.us-gov-west-1.amazonaws.com",
4672 CredentialScope: credentialScope{
4673 Region: "us-gov-west-1",
4674 },
4675 },
4676 },
4677 },
4678 "serverlessrepo": service{
4679 Defaults: endpoint{
4680 Protocols: []string{"https"},
4681 },
4682 Endpoints: endpoints{
4683 "us-gov-west-1": endpoint{
4684 Protocols: []string{"https"},
4685 },
4686 },
4687 },
4140 "sms": service{ 4688 "sms": service{
4141 4689
4142 Endpoints: endpoints{ 4690 Endpoints: endpoints{
@@ -4198,6 +4746,12 @@ var awsusgovPartition = partition{
4198 }, 4746 },
4199 Endpoints: endpoints{ 4747 Endpoints: endpoints{
4200 "us-gov-east-1": endpoint{}, 4748 "us-gov-east-1": endpoint{},
4749 "us-gov-east-1-fips": endpoint{
4750 Hostname: "dynamodb.us-gov-east-1.amazonaws.com",
4751 CredentialScope: credentialScope{
4752 Region: "us-gov-east-1",
4753 },
4754 },
4201 "us-gov-west-1": endpoint{}, 4755 "us-gov-west-1": endpoint{},
4202 "us-gov-west-1-fips": endpoint{ 4756 "us-gov-west-1-fips": endpoint{
4203 Hostname: "dynamodb.us-gov-west-1.amazonaws.com", 4757 Hostname: "dynamodb.us-gov-west-1.amazonaws.com",
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/endpoints/dep_service_ids.go b/vendor/github.com/aws/aws-sdk-go/aws/endpoints/dep_service_ids.go
index 000dd79..ca8fc82 100644
--- a/vendor/github.com/aws/aws-sdk-go/aws/endpoints/dep_service_ids.go
+++ b/vendor/github.com/aws/aws-sdk-go/aws/endpoints/dep_service_ids.go
@@ -2,7 +2,7 @@ package endpoints
2 2
3// Service identifiers 3// Service identifiers
4// 4//
5// Deprecated: Use client package's EndpointID value instead of these 5// Deprecated: Use client package's EndpointsID value instead of these
6// ServiceIDs. These IDs are not maintained, and are out of date. 6// ServiceIDs. These IDs are not maintained, and are out of date.
7const ( 7const (
8 A4bServiceID = "a4b" // A4b. 8 A4bServiceID = "a4b" // A4b.
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/request/connection_reset_error.go b/vendor/github.com/aws/aws-sdk-go/aws/request/connection_reset_error.go
index 271da43..d9b37f4 100644
--- a/vendor/github.com/aws/aws-sdk-go/aws/request/connection_reset_error.go
+++ b/vendor/github.com/aws/aws-sdk-go/aws/request/connection_reset_error.go
@@ -1,18 +1,17 @@
1// +build !appengine,!plan9
2
3package request 1package request
4 2
5import ( 3import (
6 "net" 4 "strings"
7 "os"
8 "syscall"
9) 5)
10 6
11func isErrConnectionReset(err error) bool { 7func isErrConnectionReset(err error) bool {
12 if opErr, ok := err.(*net.OpError); ok { 8 if strings.Contains(err.Error(), "read: connection reset") {
13 if sysErr, ok := opErr.Err.(*os.SyscallError); ok { 9 return false
14 return sysErr.Err == syscall.ECONNRESET 10 }
15 } 11
12 if strings.Contains(err.Error(), "connection reset") ||
13 strings.Contains(err.Error(), "broken pipe") {
14 return true
16 } 15 }
17 16
18 return false 17 return false
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/request/connection_reset_error_other.go b/vendor/github.com/aws/aws-sdk-go/aws/request/connection_reset_error_other.go
deleted file mode 100644
index daf9eca..0000000
--- a/vendor/github.com/aws/aws-sdk-go/aws/request/connection_reset_error_other.go
+++ /dev/null
@@ -1,11 +0,0 @@
1// +build appengine plan9
2
3package request
4
5import (
6 "strings"
7)
8
9func isErrConnectionReset(err error) bool {
10 return strings.Contains(err.Error(), "connection reset")
11}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/request/handlers.go b/vendor/github.com/aws/aws-sdk-go/aws/request/handlers.go
index 8ef8548..627ec72 100644
--- a/vendor/github.com/aws/aws-sdk-go/aws/request/handlers.go
+++ b/vendor/github.com/aws/aws-sdk-go/aws/request/handlers.go
@@ -59,6 +59,51 @@ func (h *Handlers) Clear() {
59 h.Complete.Clear() 59 h.Complete.Clear()
60} 60}
61 61
62// IsEmpty returns if there are no handlers in any of the handlerlists.
63func (h *Handlers) IsEmpty() bool {
64 if h.Validate.Len() != 0 {
65 return false
66 }
67 if h.Build.Len() != 0 {
68 return false
69 }
70 if h.Send.Len() != 0 {
71 return false
72 }
73 if h.Sign.Len() != 0 {
74 return false
75 }
76 if h.Unmarshal.Len() != 0 {
77 return false
78 }
79 if h.UnmarshalStream.Len() != 0 {
80 return false
81 }
82 if h.UnmarshalMeta.Len() != 0 {
83 return false
84 }
85 if h.UnmarshalError.Len() != 0 {
86 return false
87 }
88 if h.ValidateResponse.Len() != 0 {
89 return false
90 }
91 if h.Retry.Len() != 0 {
92 return false
93 }
94 if h.AfterRetry.Len() != 0 {
95 return false
96 }
97 if h.CompleteAttempt.Len() != 0 {
98 return false
99 }
100 if h.Complete.Len() != 0 {
101 return false
102 }
103
104 return true
105}
106
62// A HandlerListRunItem represents an entry in the HandlerList which 107// A HandlerListRunItem represents an entry in the HandlerList which
63// is being run. 108// is being run.
64type HandlerListRunItem struct { 109type HandlerListRunItem struct {
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/request/offset_reader.go b/vendor/github.com/aws/aws-sdk-go/aws/request/offset_reader.go
index b0c2ef4..9370fa5 100644
--- a/vendor/github.com/aws/aws-sdk-go/aws/request/offset_reader.go
+++ b/vendor/github.com/aws/aws-sdk-go/aws/request/offset_reader.go
@@ -15,12 +15,15 @@ type offsetReader struct {
15 closed bool 15 closed bool
16} 16}
17 17
18func newOffsetReader(buf io.ReadSeeker, offset int64) *offsetReader { 18func newOffsetReader(buf io.ReadSeeker, offset int64) (*offsetReader, error) {
19 reader := &offsetReader{} 19 reader := &offsetReader{}
20 buf.Seek(offset, sdkio.SeekStart) 20 _, err := buf.Seek(offset, sdkio.SeekStart)
21 if err != nil {
22 return nil, err
23 }
21 24
22 reader.buf = buf 25 reader.buf = buf
23 return reader 26 return reader, nil
24} 27}
25 28
26// Close will close the instance of the offset reader's access to 29// Close will close the instance of the offset reader's access to
@@ -54,7 +57,9 @@ func (o *offsetReader) Seek(offset int64, whence int) (int64, error) {
54 57
55// CloseAndCopy will return a new offsetReader with a copy of the old buffer 58// CloseAndCopy will return a new offsetReader with a copy of the old buffer
56// and close the old buffer. 59// and close the old buffer.
57func (o *offsetReader) CloseAndCopy(offset int64) *offsetReader { 60func (o *offsetReader) CloseAndCopy(offset int64) (*offsetReader, error) {
58 o.Close() 61 if err := o.Close(); err != nil {
62 return nil, err
63 }
59 return newOffsetReader(o.buf, offset) 64 return newOffsetReader(o.buf, offset)
60} 65}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/request/request.go b/vendor/github.com/aws/aws-sdk-go/aws/request/request.go
index 8f2eb3e..e7c9b2b 100644
--- a/vendor/github.com/aws/aws-sdk-go/aws/request/request.go
+++ b/vendor/github.com/aws/aws-sdk-go/aws/request/request.go
@@ -4,6 +4,7 @@ import (
4 "bytes" 4 "bytes"
5 "fmt" 5 "fmt"
6 "io" 6 "io"
7 "net"
7 "net/http" 8 "net/http"
8 "net/url" 9 "net/url"
9 "reflect" 10 "reflect"
@@ -231,6 +232,10 @@ func (r *Request) WillRetry() bool {
231 return r.Error != nil && aws.BoolValue(r.Retryable) && r.RetryCount < r.MaxRetries() 232 return r.Error != nil && aws.BoolValue(r.Retryable) && r.RetryCount < r.MaxRetries()
232} 233}
233 234
235func fmtAttemptCount(retryCount, maxRetries int) string {
236 return fmt.Sprintf("attempt %v/%v", retryCount, maxRetries)
237}
238
234// ParamsFilled returns if the request's parameters have been populated 239// ParamsFilled returns if the request's parameters have been populated
235// and the parameters are valid. False is returned if no parameters are 240// and the parameters are valid. False is returned if no parameters are
236// provided or invalid. 241// provided or invalid.
@@ -259,7 +264,18 @@ func (r *Request) SetStringBody(s string) {
259// SetReaderBody will set the request's body reader. 264// SetReaderBody will set the request's body reader.
260func (r *Request) SetReaderBody(reader io.ReadSeeker) { 265func (r *Request) SetReaderBody(reader io.ReadSeeker) {
261 r.Body = reader 266 r.Body = reader
262 r.BodyStart, _ = reader.Seek(0, sdkio.SeekCurrent) // Get the Bodies current offset. 267
268 if aws.IsReaderSeekable(reader) {
269 var err error
270 // Get the Bodies current offset so retries will start from the same
271 // initial position.
272 r.BodyStart, err = reader.Seek(0, sdkio.SeekCurrent)
273 if err != nil {
274 r.Error = awserr.New(ErrCodeSerialization,
275 "failed to determine start of request body", err)
276 return
277 }
278 }
263 r.ResetBody() 279 r.ResetBody()
264} 280}
265 281
@@ -330,16 +346,15 @@ func getPresignedURL(r *Request, expire time.Duration) (string, http.Header, err
330 return r.HTTPRequest.URL.String(), r.SignedHeaderVals, nil 346 return r.HTTPRequest.URL.String(), r.SignedHeaderVals, nil
331} 347}
332 348
333func debugLogReqError(r *Request, stage string, retrying bool, err error) { 349const (
350 notRetrying = "not retrying"
351)
352
353func debugLogReqError(r *Request, stage, retryStr string, err error) {
334 if !r.Config.LogLevel.Matches(aws.LogDebugWithRequestErrors) { 354 if !r.Config.LogLevel.Matches(aws.LogDebugWithRequestErrors) {
335 return 355 return
336 } 356 }
337 357
338 retryStr := "not retrying"
339 if retrying {
340 retryStr = "will retry"
341 }
342
343 r.Config.Logger.Log(fmt.Sprintf("DEBUG: %s %s/%s failed, %s, error %v", 358 r.Config.Logger.Log(fmt.Sprintf("DEBUG: %s %s/%s failed, %s, error %v",
344 stage, r.ClientInfo.ServiceName, r.Operation.Name, retryStr, err)) 359 stage, r.ClientInfo.ServiceName, r.Operation.Name, retryStr, err))
345} 360}
@@ -358,12 +373,12 @@ func (r *Request) Build() error {
358 if !r.built { 373 if !r.built {
359 r.Handlers.Validate.Run(r) 374 r.Handlers.Validate.Run(r)
360 if r.Error != nil { 375 if r.Error != nil {
361 debugLogReqError(r, "Validate Request", false, r.Error) 376 debugLogReqError(r, "Validate Request", notRetrying, r.Error)
362 return r.Error 377 return r.Error
363 } 378 }
364 r.Handlers.Build.Run(r) 379 r.Handlers.Build.Run(r)
365 if r.Error != nil { 380 if r.Error != nil {
366 debugLogReqError(r, "Build Request", false, r.Error) 381 debugLogReqError(r, "Build Request", notRetrying, r.Error)
367 return r.Error 382 return r.Error
368 } 383 }
369 r.built = true 384 r.built = true
@@ -379,7 +394,7 @@ func (r *Request) Build() error {
379func (r *Request) Sign() error { 394func (r *Request) Sign() error {
380 r.Build() 395 r.Build()
381 if r.Error != nil { 396 if r.Error != nil {
382 debugLogReqError(r, "Build Request", false, r.Error) 397 debugLogReqError(r, "Build Request", notRetrying, r.Error)
383 return r.Error 398 return r.Error
384 } 399 }
385 400
@@ -387,12 +402,16 @@ func (r *Request) Sign() error {
387 return r.Error 402 return r.Error
388} 403}
389 404
390func (r *Request) getNextRequestBody() (io.ReadCloser, error) { 405func (r *Request) getNextRequestBody() (body io.ReadCloser, err error) {
391 if r.safeBody != nil { 406 if r.safeBody != nil {
392 r.safeBody.Close() 407 r.safeBody.Close()
393 } 408 }
394 409
395 r.safeBody = newOffsetReader(r.Body, r.BodyStart) 410 r.safeBody, err = newOffsetReader(r.Body, r.BodyStart)
411 if err != nil {
412 return nil, awserr.New(ErrCodeSerialization,
413 "failed to get next request body reader", err)
414 }
396 415
397 // Go 1.8 tightened and clarified the rules code needs to use when building 416 // Go 1.8 tightened and clarified the rules code needs to use when building
398 // requests with the http package. Go 1.8 removed the automatic detection 417 // requests with the http package. Go 1.8 removed the automatic detection
@@ -409,10 +428,10 @@ func (r *Request) getNextRequestBody() (io.ReadCloser, error) {
409 // Related golang/go#18257 428 // Related golang/go#18257
410 l, err := aws.SeekerLen(r.Body) 429 l, err := aws.SeekerLen(r.Body)
411 if err != nil { 430 if err != nil {
412 return nil, awserr.New(ErrCodeSerialization, "failed to compute request body size", err) 431 return nil, awserr.New(ErrCodeSerialization,
432 "failed to compute request body size", err)
413 } 433 }
414 434
415 var body io.ReadCloser
416 if l == 0 { 435 if l == 0 {
417 body = NoBody 436 body = NoBody
418 } else if l > 0 { 437 } else if l > 0 {
@@ -473,13 +492,13 @@ func (r *Request) Send() error {
473 r.AttemptTime = time.Now() 492 r.AttemptTime = time.Now()
474 493
475 if err := r.Sign(); err != nil { 494 if err := r.Sign(); err != nil {
476 debugLogReqError(r, "Sign Request", false, err) 495 debugLogReqError(r, "Sign Request", notRetrying, err)
477 return err 496 return err
478 } 497 }
479 498
480 if err := r.sendRequest(); err == nil { 499 if err := r.sendRequest(); err == nil {
481 return nil 500 return nil
482 } else if !shouldRetryCancel(r.Error) { 501 } else if !shouldRetryError(r.Error) {
483 return err 502 return err
484 } else { 503 } else {
485 r.Handlers.Retry.Run(r) 504 r.Handlers.Retry.Run(r)
@@ -489,13 +508,16 @@ func (r *Request) Send() error {
489 return r.Error 508 return r.Error
490 } 509 }
491 510
492 r.prepareRetry() 511 if err := r.prepareRetry(); err != nil {
512 r.Error = err
513 return err
514 }
493 continue 515 continue
494 } 516 }
495 } 517 }
496} 518}
497 519
498func (r *Request) prepareRetry() { 520func (r *Request) prepareRetry() error {
499 if r.Config.LogLevel.Matches(aws.LogDebugWithRequestRetries) { 521 if r.Config.LogLevel.Matches(aws.LogDebugWithRequestRetries) {
500 r.Config.Logger.Log(fmt.Sprintf("DEBUG: Retrying Request %s/%s, attempt %d", 522 r.Config.Logger.Log(fmt.Sprintf("DEBUG: Retrying Request %s/%s, attempt %d",
501 r.ClientInfo.ServiceName, r.Operation.Name, r.RetryCount)) 523 r.ClientInfo.ServiceName, r.Operation.Name, r.RetryCount))
@@ -506,12 +528,19 @@ func (r *Request) prepareRetry() {
506 // the request's body even though the Client's Do returned. 528 // the request's body even though the Client's Do returned.
507 r.HTTPRequest = copyHTTPRequest(r.HTTPRequest, nil) 529 r.HTTPRequest = copyHTTPRequest(r.HTTPRequest, nil)
508 r.ResetBody() 530 r.ResetBody()
531 if err := r.Error; err != nil {
532 return awserr.New(ErrCodeSerialization,
533 "failed to prepare body for retry", err)
534
535 }
509 536
510 // Closing response body to ensure that no response body is leaked 537 // Closing response body to ensure that no response body is leaked
511 // between retry attempts. 538 // between retry attempts.
512 if r.HTTPResponse != nil && r.HTTPResponse.Body != nil { 539 if r.HTTPResponse != nil && r.HTTPResponse.Body != nil {
513 r.HTTPResponse.Body.Close() 540 r.HTTPResponse.Body.Close()
514 } 541 }
542
543 return nil
515} 544}
516 545
517func (r *Request) sendRequest() (sendErr error) { 546func (r *Request) sendRequest() (sendErr error) {
@@ -520,7 +549,9 @@ func (r *Request) sendRequest() (sendErr error) {
520 r.Retryable = nil 549 r.Retryable = nil
521 r.Handlers.Send.Run(r) 550 r.Handlers.Send.Run(r)
522 if r.Error != nil { 551 if r.Error != nil {
523 debugLogReqError(r, "Send Request", r.WillRetry(), r.Error) 552 debugLogReqError(r, "Send Request",
553 fmtAttemptCount(r.RetryCount, r.MaxRetries()),
554 r.Error)
524 return r.Error 555 return r.Error
525 } 556 }
526 557
@@ -528,13 +559,17 @@ func (r *Request) sendRequest() (sendErr error) {
528 r.Handlers.ValidateResponse.Run(r) 559 r.Handlers.ValidateResponse.Run(r)
529 if r.Error != nil { 560 if r.Error != nil {
530 r.Handlers.UnmarshalError.Run(r) 561 r.Handlers.UnmarshalError.Run(r)
531 debugLogReqError(r, "Validate Response", r.WillRetry(), r.Error) 562 debugLogReqError(r, "Validate Response",
563 fmtAttemptCount(r.RetryCount, r.MaxRetries()),
564 r.Error)
532 return r.Error 565 return r.Error
533 } 566 }
534 567
535 r.Handlers.Unmarshal.Run(r) 568 r.Handlers.Unmarshal.Run(r)
536 if r.Error != nil { 569 if r.Error != nil {
537 debugLogReqError(r, "Unmarshal Response", r.WillRetry(), r.Error) 570 debugLogReqError(r, "Unmarshal Response",
571 fmtAttemptCount(r.RetryCount, r.MaxRetries()),
572 r.Error)
538 return r.Error 573 return r.Error
539 } 574 }
540 575
@@ -565,13 +600,13 @@ type temporary interface {
565 Temporary() bool 600 Temporary() bool
566} 601}
567 602
568func shouldRetryCancel(err error) bool { 603func shouldRetryError(origErr error) bool {
569 switch err := err.(type) { 604 switch err := origErr.(type) {
570 case awserr.Error: 605 case awserr.Error:
571 if err.Code() == CanceledErrorCode { 606 if err.Code() == CanceledErrorCode {
572 return false 607 return false
573 } 608 }
574 return shouldRetryCancel(err.OrigErr()) 609 return shouldRetryError(err.OrigErr())
575 case *url.Error: 610 case *url.Error:
576 if strings.Contains(err.Error(), "connection refused") { 611 if strings.Contains(err.Error(), "connection refused") {
577 // Refused connections should be retried as the service may not yet 612 // Refused connections should be retried as the service may not yet
@@ -581,14 +616,17 @@ func shouldRetryCancel(err error) bool {
581 } 616 }
582 // *url.Error only implements Temporary after golang 1.6 but since 617 // *url.Error only implements Temporary after golang 1.6 but since
583 // url.Error only wraps the error: 618 // url.Error only wraps the error:
584 return shouldRetryCancel(err.Err) 619 return shouldRetryError(err.Err)
585 case temporary: 620 case temporary:
621 if netErr, ok := err.(*net.OpError); ok && netErr.Op == "dial" {
622 return true
623 }
586 // If the error is temporary, we want to allow continuation of the 624 // If the error is temporary, we want to allow continuation of the
587 // retry process 625 // retry process
588 return err.Temporary() 626 return err.Temporary() || isErrConnectionReset(origErr)
589 case nil: 627 case nil:
590 // `awserr.Error.OrigErr()` can be nil, meaning there was an error but 628 // `awserr.Error.OrigErr()` can be nil, meaning there was an error but
591 // because we don't know the cause, it is marked as retriable. See 629 // because we don't know the cause, it is marked as retryable. See
592 // TestRequest4xxUnretryable for an example. 630 // TestRequest4xxUnretryable for an example.
593 return true 631 return true
594 default: 632 default:
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/request/request_1_8.go b/vendor/github.com/aws/aws-sdk-go/aws/request/request_1_8.go
index 7c6a800..de1292f 100644
--- a/vendor/github.com/aws/aws-sdk-go/aws/request/request_1_8.go
+++ b/vendor/github.com/aws/aws-sdk-go/aws/request/request_1_8.go
@@ -4,6 +4,8 @@ package request
4 4
5import ( 5import (
6 "net/http" 6 "net/http"
7
8 "github.com/aws/aws-sdk-go/aws/awserr"
7) 9)
8 10
9// NoBody is a http.NoBody reader instructing Go HTTP client to not include 11// NoBody is a http.NoBody reader instructing Go HTTP client to not include
@@ -24,7 +26,8 @@ var NoBody = http.NoBody
24func (r *Request) ResetBody() { 26func (r *Request) ResetBody() {
25 body, err := r.getNextRequestBody() 27 body, err := r.getNextRequestBody()
26 if err != nil { 28 if err != nil {
27 r.Error = err 29 r.Error = awserr.New(ErrCodeSerialization,
30 "failed to reset request body", err)
28 return 31 return
29 } 32 }
30 33
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/request/request_pagination.go b/vendor/github.com/aws/aws-sdk-go/aws/request/request_pagination.go
index a633ed5..f093fc5 100644
--- a/vendor/github.com/aws/aws-sdk-go/aws/request/request_pagination.go
+++ b/vendor/github.com/aws/aws-sdk-go/aws/request/request_pagination.go
@@ -146,7 +146,7 @@ func (r *Request) nextPageTokens() []interface{} {
146 return nil 146 return nil
147 } 147 }
148 case bool: 148 case bool:
149 if v == false { 149 if !v {
150 return nil 150 return nil
151 } 151 }
152 } 152 }
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/session/credentials.go b/vendor/github.com/aws/aws-sdk-go/aws/session/credentials.go
new file mode 100644
index 0000000..ce41518
--- /dev/null
+++ b/vendor/github.com/aws/aws-sdk-go/aws/session/credentials.go
@@ -0,0 +1,258 @@
1package session
2
3import (
4 "fmt"
5 "os"
6
7 "github.com/aws/aws-sdk-go/aws"
8 "github.com/aws/aws-sdk-go/aws/awserr"
9 "github.com/aws/aws-sdk-go/aws/credentials"
10 "github.com/aws/aws-sdk-go/aws/credentials/processcreds"
11 "github.com/aws/aws-sdk-go/aws/credentials/stscreds"
12 "github.com/aws/aws-sdk-go/aws/defaults"
13 "github.com/aws/aws-sdk-go/aws/request"
14 "github.com/aws/aws-sdk-go/internal/shareddefaults"
15)
16
17func resolveCredentials(cfg *aws.Config,
18 envCfg envConfig, sharedCfg sharedConfig,
19 handlers request.Handlers,
20 sessOpts Options,
21) (*credentials.Credentials, error) {
22
23 switch {
24 case len(envCfg.Profile) != 0:
25 // User explicitly provided an Profile, so load from shared config
26 // first.
27 return resolveCredsFromProfile(cfg, envCfg, sharedCfg, handlers, sessOpts)
28
29 case envCfg.Creds.HasKeys():
30 // Environment credentials
31 return credentials.NewStaticCredentialsFromCreds(envCfg.Creds), nil
32
33 case len(envCfg.WebIdentityTokenFilePath) != 0:
34 // Web identity token from environment, RoleARN required to also be
35 // set.
36 return assumeWebIdentity(cfg, handlers,
37 envCfg.WebIdentityTokenFilePath,
38 envCfg.RoleARN,
39 envCfg.RoleSessionName,
40 )
41
42 default:
43 // Fallback to the "default" credential resolution chain.
44 return resolveCredsFromProfile(cfg, envCfg, sharedCfg, handlers, sessOpts)
45 }
46}
47
48// WebIdentityEmptyRoleARNErr will occur if 'AWS_WEB_IDENTITY_TOKEN_FILE' was set but
49// 'AWS_IAM_ROLE_ARN' was not set.
50var WebIdentityEmptyRoleARNErr = awserr.New(stscreds.ErrCodeWebIdentity, "role ARN is not set", nil)
51
52// WebIdentityEmptyTokenFilePathErr will occur if 'AWS_IAM_ROLE_ARN' was set but
53// 'AWS_WEB_IDENTITY_TOKEN_FILE' was not set.
54var WebIdentityEmptyTokenFilePathErr = awserr.New(stscreds.ErrCodeWebIdentity, "token file path is not set", nil)
55
56func assumeWebIdentity(cfg *aws.Config, handlers request.Handlers,
57 filepath string,
58 roleARN, sessionName string,
59) (*credentials.Credentials, error) {
60
61 if len(filepath) == 0 {
62 return nil, WebIdentityEmptyTokenFilePathErr
63 }
64
65 if len(roleARN) == 0 {
66 return nil, WebIdentityEmptyRoleARNErr
67 }
68
69 creds := stscreds.NewWebIdentityCredentials(
70 &Session{
71 Config: cfg,
72 Handlers: handlers.Copy(),
73 },
74 roleARN,
75 sessionName,
76 filepath,
77 )
78
79 return creds, nil
80}
81
82func resolveCredsFromProfile(cfg *aws.Config,
83 envCfg envConfig, sharedCfg sharedConfig,
84 handlers request.Handlers,
85 sessOpts Options,
86) (creds *credentials.Credentials, err error) {
87
88 switch {
89 case sharedCfg.SourceProfile != nil:
90 // Assume IAM role with credentials source from a different profile.
91 creds, err = resolveCredsFromProfile(cfg, envCfg,
92 *sharedCfg.SourceProfile, handlers, sessOpts,
93 )
94
95 case sharedCfg.Creds.HasKeys():
96 // Static Credentials from Shared Config/Credentials file.
97 creds = credentials.NewStaticCredentialsFromCreds(
98 sharedCfg.Creds,
99 )
100
101 case len(sharedCfg.CredentialProcess) != 0:
102 // Get credentials from CredentialProcess
103 creds = processcreds.NewCredentials(sharedCfg.CredentialProcess)
104
105 case len(sharedCfg.CredentialSource) != 0:
106 creds, err = resolveCredsFromSource(cfg, envCfg,
107 sharedCfg, handlers, sessOpts,
108 )
109
110 case len(sharedCfg.WebIdentityTokenFile) != 0:
111 // Credentials from Assume Web Identity token require an IAM Role, and
112 // that roll will be assumed. May be wrapped with another assume role
113 // via SourceProfile.
114 return assumeWebIdentity(cfg, handlers,
115 sharedCfg.WebIdentityTokenFile,
116 sharedCfg.RoleARN,
117 sharedCfg.RoleSessionName,
118 )
119
120 default:
121 // Fallback to default credentials provider, include mock errors for
122 // the credential chain so user can identify why credentials failed to
123 // be retrieved.
124 creds = credentials.NewCredentials(&credentials.ChainProvider{
125 VerboseErrors: aws.BoolValue(cfg.CredentialsChainVerboseErrors),
126 Providers: []credentials.Provider{
127 &credProviderError{
128 Err: awserr.New("EnvAccessKeyNotFound",
129 "failed to find credentials in the environment.", nil),
130 },
131 &credProviderError{
132 Err: awserr.New("SharedCredsLoad",
133 fmt.Sprintf("failed to load profile, %s.", envCfg.Profile), nil),
134 },
135 defaults.RemoteCredProvider(*cfg, handlers),
136 },
137 })
138 }
139 if err != nil {
140 return nil, err
141 }
142
143 if len(sharedCfg.RoleARN) > 0 {
144 cfgCp := *cfg
145 cfgCp.Credentials = creds
146 return credsFromAssumeRole(cfgCp, handlers, sharedCfg, sessOpts)
147 }
148
149 return creds, nil
150}
151
152// valid credential source values
153const (
154 credSourceEc2Metadata = "Ec2InstanceMetadata"
155 credSourceEnvironment = "Environment"
156 credSourceECSContainer = "EcsContainer"
157)
158
159func resolveCredsFromSource(cfg *aws.Config,
160 envCfg envConfig, sharedCfg sharedConfig,
161 handlers request.Handlers,
162 sessOpts Options,
163) (creds *credentials.Credentials, err error) {
164
165 switch sharedCfg.CredentialSource {
166 case credSourceEc2Metadata:
167 p := defaults.RemoteCredProvider(*cfg, handlers)
168 creds = credentials.NewCredentials(p)
169
170 case credSourceEnvironment:
171 creds = credentials.NewStaticCredentialsFromCreds(envCfg.Creds)
172
173 case credSourceECSContainer:
174 if len(os.Getenv(shareddefaults.ECSCredsProviderEnvVar)) == 0 {
175 return nil, ErrSharedConfigECSContainerEnvVarEmpty
176 }
177
178 p := defaults.RemoteCredProvider(*cfg, handlers)
179 creds = credentials.NewCredentials(p)
180
181 default:
182 return nil, ErrSharedConfigInvalidCredSource
183 }
184
185 return creds, nil
186}
187
188func credsFromAssumeRole(cfg aws.Config,
189 handlers request.Handlers,
190 sharedCfg sharedConfig,
191 sessOpts Options,
192) (*credentials.Credentials, error) {
193
194 if len(sharedCfg.MFASerial) != 0 && sessOpts.AssumeRoleTokenProvider == nil {
195 // AssumeRole Token provider is required if doing Assume Role
196 // with MFA.
197 return nil, AssumeRoleTokenProviderNotSetError{}
198 }
199
200 return stscreds.NewCredentials(
201 &Session{
202 Config: &cfg,
203 Handlers: handlers.Copy(),
204 },
205 sharedCfg.RoleARN,
206 func(opt *stscreds.AssumeRoleProvider) {
207 opt.RoleSessionName = sharedCfg.RoleSessionName
208 opt.Duration = sessOpts.AssumeRoleDuration
209
210 // Assume role with external ID
211 if len(sharedCfg.ExternalID) > 0 {
212 opt.ExternalID = aws.String(sharedCfg.ExternalID)
213 }
214
215 // Assume role with MFA
216 if len(sharedCfg.MFASerial) > 0 {
217 opt.SerialNumber = aws.String(sharedCfg.MFASerial)
218 opt.TokenProvider = sessOpts.AssumeRoleTokenProvider
219 }
220 },
221 ), nil
222}
223
224// AssumeRoleTokenProviderNotSetError is an error returned when creating a
225// session when the MFAToken option is not set when shared config is configured
226// load assume a role with an MFA token.
227type AssumeRoleTokenProviderNotSetError struct{}
228
229// Code is the short id of the error.
230func (e AssumeRoleTokenProviderNotSetError) Code() string {
231 return "AssumeRoleTokenProviderNotSetError"
232}
233
234// Message is the description of the error
235func (e AssumeRoleTokenProviderNotSetError) Message() string {
236 return fmt.Sprintf("assume role with MFA enabled, but AssumeRoleTokenProvider session option not set.")
237}
238
239// OrigErr is the underlying error that caused the failure.
240func (e AssumeRoleTokenProviderNotSetError) OrigErr() error {
241 return nil
242}
243
244// Error satisfies the error interface.
245func (e AssumeRoleTokenProviderNotSetError) Error() string {
246 return awserr.SprintError(e.Code(), e.Message(), "", nil)
247}
248
249type credProviderError struct {
250 Err error
251}
252
253func (c credProviderError) Retrieve() (credentials.Value, error) {
254 return credentials.Value{}, c.Err
255}
256func (c credProviderError) IsExpired() bool {
257 return true
258}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/session/env_config.go b/vendor/github.com/aws/aws-sdk-go/aws/session/env_config.go
index e3959b9..3a998d5 100644
--- a/vendor/github.com/aws/aws-sdk-go/aws/session/env_config.go
+++ b/vendor/github.com/aws/aws-sdk-go/aws/session/env_config.go
@@ -102,18 +102,38 @@ type envConfig struct {
102 CSMEnabled bool 102 CSMEnabled bool
103 CSMPort string 103 CSMPort string
104 CSMClientID string 104 CSMClientID string
105 CSMHost string
105 106
106 enableEndpointDiscovery string
107 // Enables endpoint discovery via environment variables. 107 // Enables endpoint discovery via environment variables.
108 // 108 //
109 // AWS_ENABLE_ENDPOINT_DISCOVERY=true 109 // AWS_ENABLE_ENDPOINT_DISCOVERY=true
110 EnableEndpointDiscovery *bool 110 EnableEndpointDiscovery *bool
111 enableEndpointDiscovery string
112
113 // Specifies the WebIdentity token the SDK should use to assume a role
114 // with.
115 //
116 // AWS_WEB_IDENTITY_TOKEN_FILE=file_path
117 WebIdentityTokenFilePath string
118
119 // Specifies the IAM role arn to use when assuming an role.
120 //
121 // AWS_ROLE_ARN=role_arn
122 RoleARN string
123
124 // Specifies the IAM role session name to use when assuming a role.
125 //
126 // AWS_ROLE_SESSION_NAME=session_name
127 RoleSessionName string
111} 128}
112 129
113var ( 130var (
114 csmEnabledEnvKey = []string{ 131 csmEnabledEnvKey = []string{
115 "AWS_CSM_ENABLED", 132 "AWS_CSM_ENABLED",
116 } 133 }
134 csmHostEnvKey = []string{
135 "AWS_CSM_HOST",
136 }
117 csmPortEnvKey = []string{ 137 csmPortEnvKey = []string{
118 "AWS_CSM_PORT", 138 "AWS_CSM_PORT",
119 } 139 }
@@ -150,6 +170,15 @@ var (
150 sharedConfigFileEnvKey = []string{ 170 sharedConfigFileEnvKey = []string{
151 "AWS_CONFIG_FILE", 171 "AWS_CONFIG_FILE",
152 } 172 }
173 webIdentityTokenFilePathEnvKey = []string{
174 "AWS_WEB_IDENTITY_TOKEN_FILE",
175 }
176 roleARNEnvKey = []string{
177 "AWS_ROLE_ARN",
178 }
179 roleSessionNameEnvKey = []string{
180 "AWS_ROLE_SESSION_NAME",
181 }
153) 182)
154 183
155// loadEnvConfig retrieves the SDK's environment configuration. 184// loadEnvConfig retrieves the SDK's environment configuration.
@@ -178,23 +207,31 @@ func envConfigLoad(enableSharedConfig bool) envConfig {
178 207
179 cfg.EnableSharedConfig = enableSharedConfig 208 cfg.EnableSharedConfig = enableSharedConfig
180 209
181 setFromEnvVal(&cfg.Creds.AccessKeyID, credAccessEnvKey) 210 // Static environment credentials
182 setFromEnvVal(&cfg.Creds.SecretAccessKey, credSecretEnvKey) 211 var creds credentials.Value
183 setFromEnvVal(&cfg.Creds.SessionToken, credSessionEnvKey) 212 setFromEnvVal(&creds.AccessKeyID, credAccessEnvKey)
213 setFromEnvVal(&creds.SecretAccessKey, credSecretEnvKey)
214 setFromEnvVal(&creds.SessionToken, credSessionEnvKey)
215 if creds.HasKeys() {
216 // Require logical grouping of credentials
217 creds.ProviderName = EnvProviderName
218 cfg.Creds = creds
219 }
220
221 // Role Metadata
222 setFromEnvVal(&cfg.RoleARN, roleARNEnvKey)
223 setFromEnvVal(&cfg.RoleSessionName, roleSessionNameEnvKey)
224
225 // Web identity environment variables
226 setFromEnvVal(&cfg.WebIdentityTokenFilePath, webIdentityTokenFilePathEnvKey)
184 227
185 // CSM environment variables 228 // CSM environment variables
186 setFromEnvVal(&cfg.csmEnabled, csmEnabledEnvKey) 229 setFromEnvVal(&cfg.csmEnabled, csmEnabledEnvKey)
230 setFromEnvVal(&cfg.CSMHost, csmHostEnvKey)
187 setFromEnvVal(&cfg.CSMPort, csmPortEnvKey) 231 setFromEnvVal(&cfg.CSMPort, csmPortEnvKey)
188 setFromEnvVal(&cfg.CSMClientID, csmClientIDEnvKey) 232 setFromEnvVal(&cfg.CSMClientID, csmClientIDEnvKey)
189 cfg.CSMEnabled = len(cfg.csmEnabled) > 0 233 cfg.CSMEnabled = len(cfg.csmEnabled) > 0
190 234
191 // Require logical grouping of credentials
192 if len(cfg.Creds.AccessKeyID) == 0 || len(cfg.Creds.SecretAccessKey) == 0 {
193 cfg.Creds = credentials.Value{}
194 } else {
195 cfg.Creds.ProviderName = EnvProviderName
196 }
197
198 regionKeys := regionEnvKeys 235 regionKeys := regionEnvKeys
199 profileKeys := profileEnvKeys 236 profileKeys := profileEnvKeys
200 if !cfg.EnableSharedConfig { 237 if !cfg.EnableSharedConfig {
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/session/session.go b/vendor/github.com/aws/aws-sdk-go/aws/session/session.go
index be4b5f0..3a28da5 100644
--- a/vendor/github.com/aws/aws-sdk-go/aws/session/session.go
+++ b/vendor/github.com/aws/aws-sdk-go/aws/session/session.go
@@ -8,19 +8,17 @@ import (
8 "io/ioutil" 8 "io/ioutil"
9 "net/http" 9 "net/http"
10 "os" 10 "os"
11 "time"
11 12
12 "github.com/aws/aws-sdk-go/aws" 13 "github.com/aws/aws-sdk-go/aws"
13 "github.com/aws/aws-sdk-go/aws/awserr" 14 "github.com/aws/aws-sdk-go/aws/awserr"
14 "github.com/aws/aws-sdk-go/aws/client" 15 "github.com/aws/aws-sdk-go/aws/client"
15 "github.com/aws/aws-sdk-go/aws/corehandlers" 16 "github.com/aws/aws-sdk-go/aws/corehandlers"
16 "github.com/aws/aws-sdk-go/aws/credentials" 17 "github.com/aws/aws-sdk-go/aws/credentials"
17 "github.com/aws/aws-sdk-go/aws/credentials/processcreds"
18 "github.com/aws/aws-sdk-go/aws/credentials/stscreds"
19 "github.com/aws/aws-sdk-go/aws/csm" 18 "github.com/aws/aws-sdk-go/aws/csm"
20 "github.com/aws/aws-sdk-go/aws/defaults" 19 "github.com/aws/aws-sdk-go/aws/defaults"
21 "github.com/aws/aws-sdk-go/aws/endpoints" 20 "github.com/aws/aws-sdk-go/aws/endpoints"
22 "github.com/aws/aws-sdk-go/aws/request" 21 "github.com/aws/aws-sdk-go/aws/request"
23 "github.com/aws/aws-sdk-go/internal/shareddefaults"
24) 22)
25 23
26const ( 24const (
@@ -107,7 +105,15 @@ func New(cfgs ...*aws.Config) *Session {
107 105
108 s := deprecatedNewSession(cfgs...) 106 s := deprecatedNewSession(cfgs...)
109 if envCfg.CSMEnabled { 107 if envCfg.CSMEnabled {
110 enableCSM(&s.Handlers, envCfg.CSMClientID, envCfg.CSMPort, s.Config.Logger) 108 err := enableCSM(&s.Handlers, envCfg.CSMClientID,
109 envCfg.CSMHost, envCfg.CSMPort, s.Config.Logger)
110 if err != nil {
111 err = fmt.Errorf("failed to enable CSM, %v", err)
112 s.Config.Logger.Log("ERROR:", err.Error())
113 s.Handlers.Validate.PushBack(func(r *request.Request) {
114 r.Error = err
115 })
116 }
111 } 117 }
112 118
113 return s 119 return s
@@ -210,6 +216,12 @@ type Options struct {
210 // the config enables assume role wit MFA via the mfa_serial field. 216 // the config enables assume role wit MFA via the mfa_serial field.
211 AssumeRoleTokenProvider func() (string, error) 217 AssumeRoleTokenProvider func() (string, error)
212 218
219 // When the SDK's shared config is configured to assume a role this option
220 // may be provided to set the expiry duration of the STS credentials.
221 // Defaults to 15 minutes if not set as documented in the
222 // stscreds.AssumeRoleProvider.
223 AssumeRoleDuration time.Duration
224
213 // Reader for a custom Credentials Authority (CA) bundle in PEM format that 225 // Reader for a custom Credentials Authority (CA) bundle in PEM format that
214 // the SDK will use instead of the default system's root CA bundle. Use this 226 // the SDK will use instead of the default system's root CA bundle. Use this
215 // only if you want to replace the CA bundle the SDK uses for TLS requests. 227 // only if you want to replace the CA bundle the SDK uses for TLS requests.
@@ -224,6 +236,12 @@ type Options struct {
224 // to also enable this feature. CustomCABundle session option field has priority 236 // to also enable this feature. CustomCABundle session option field has priority
225 // over the AWS_CA_BUNDLE environment variable, and will be used if both are set. 237 // over the AWS_CA_BUNDLE environment variable, and will be used if both are set.
226 CustomCABundle io.Reader 238 CustomCABundle io.Reader
239
240 // The handlers that the session and all API clients will be created with.
241 // This must be a complete set of handlers. Use the defaults.Handlers()
242 // function to initialize this value before changing the handlers to be
243 // used by the SDK.
244 Handlers request.Handlers
227} 245}
228 246
229// NewSessionWithOptions returns a new Session created from SDK defaults, config files, 247// NewSessionWithOptions returns a new Session created from SDK defaults, config files,
@@ -329,27 +347,36 @@ func deprecatedNewSession(cfgs ...*aws.Config) *Session {
329 return s 347 return s
330} 348}
331 349
332func enableCSM(handlers *request.Handlers, clientID string, port string, logger aws.Logger) { 350func enableCSM(handlers *request.Handlers,
333 logger.Log("Enabling CSM") 351 clientID, host, port string,
334 if len(port) == 0 { 352 logger aws.Logger,
335 port = csm.DefaultPort 353) error {
354 if logger != nil {
355 logger.Log("Enabling CSM")
336 } 356 }
337 357
338 r, err := csm.Start(clientID, "127.0.0.1:"+port) 358 r, err := csm.Start(clientID, csm.AddressWithDefaults(host, port))
339 if err != nil { 359 if err != nil {
340 return 360 return err
341 } 361 }
342 r.InjectHandlers(handlers) 362 r.InjectHandlers(handlers)
363
364 return nil
343} 365}
344 366
345func newSession(opts Options, envCfg envConfig, cfgs ...*aws.Config) (*Session, error) { 367func newSession(opts Options, envCfg envConfig, cfgs ...*aws.Config) (*Session, error) {
346 cfg := defaults.Config() 368 cfg := defaults.Config()
347 handlers := defaults.Handlers() 369
370 handlers := opts.Handlers
371 if handlers.IsEmpty() {
372 handlers = defaults.Handlers()
373 }
348 374
349 // Get a merged version of the user provided config to determine if 375 // Get a merged version of the user provided config to determine if
350 // credentials were. 376 // credentials were.
351 userCfg := &aws.Config{} 377 userCfg := &aws.Config{}
352 userCfg.MergeIn(cfgs...) 378 userCfg.MergeIn(cfgs...)
379 cfg.MergeIn(userCfg)
353 380
354 // Ordered config files will be loaded in with later files overwriting 381 // Ordered config files will be loaded in with later files overwriting
355 // previous config file values. 382 // previous config file values.
@@ -366,9 +393,11 @@ func newSession(opts Options, envCfg envConfig, cfgs ...*aws.Config) (*Session,
366 } 393 }
367 394
368 // Load additional config from file(s) 395 // Load additional config from file(s)
369 sharedCfg, err := loadSharedConfig(envCfg.Profile, cfgFiles) 396 sharedCfg, err := loadSharedConfig(envCfg.Profile, cfgFiles, envCfg.EnableSharedConfig)
370 if err != nil { 397 if err != nil {
371 return nil, err 398 if _, ok := err.(SharedConfigProfileNotExistsError); !ok {
399 return nil, err
400 }
372 } 401 }
373 402
374 if err := mergeConfigSrcs(cfg, userCfg, envCfg, sharedCfg, handlers, opts); err != nil { 403 if err := mergeConfigSrcs(cfg, userCfg, envCfg, sharedCfg, handlers, opts); err != nil {
@@ -382,7 +411,11 @@ func newSession(opts Options, envCfg envConfig, cfgs ...*aws.Config) (*Session,
382 411
383 initHandlers(s) 412 initHandlers(s)
384 if envCfg.CSMEnabled { 413 if envCfg.CSMEnabled {
385 enableCSM(&s.Handlers, envCfg.CSMClientID, envCfg.CSMPort, s.Config.Logger) 414 err := enableCSM(&s.Handlers, envCfg.CSMClientID,
415 envCfg.CSMHost, envCfg.CSMPort, s.Config.Logger)
416 if err != nil {
417 return nil, err
418 }
386 } 419 }
387 420
388 // Setup HTTP client with custom cert bundle if enabled 421 // Setup HTTP client with custom cert bundle if enabled
@@ -443,9 +476,11 @@ func loadCertPool(r io.Reader) (*x509.CertPool, error) {
443 return p, nil 476 return p, nil
444} 477}
445 478
446func mergeConfigSrcs(cfg, userCfg *aws.Config, envCfg envConfig, sharedCfg sharedConfig, handlers request.Handlers, sessOpts Options) error { 479func mergeConfigSrcs(cfg, userCfg *aws.Config,
447 // Merge in user provided configuration 480 envCfg envConfig, sharedCfg sharedConfig,
448 cfg.MergeIn(userCfg) 481 handlers request.Handlers,
482 sessOpts Options,
483) error {
449 484
450 // Region if not already set by user 485 // Region if not already set by user
451 if len(aws.StringValue(cfg.Region)) == 0 { 486 if len(aws.StringValue(cfg.Region)) == 0 {
@@ -464,164 +499,19 @@ func mergeConfigSrcs(cfg, userCfg *aws.Config, envCfg envConfig, sharedCfg share
464 } 499 }
465 } 500 }
466 501
467 // Configure credentials if not already set 502 // Configure credentials if not already set by the user when creating the
503 // Session.
468 if cfg.Credentials == credentials.AnonymousCredentials && userCfg.Credentials == nil { 504 if cfg.Credentials == credentials.AnonymousCredentials && userCfg.Credentials == nil {
469 505 creds, err := resolveCredentials(cfg, envCfg, sharedCfg, handlers, sessOpts)
470 // inspect the profile to see if a credential source has been specified. 506 if err != nil {
471 if envCfg.EnableSharedConfig && len(sharedCfg.AssumeRole.CredentialSource) > 0 { 507 return err
472
473 // if both credential_source and source_profile have been set, return an error
474 // as this is undefined behavior.
475 if len(sharedCfg.AssumeRole.SourceProfile) > 0 {
476 return ErrSharedConfigSourceCollision
477 }
478
479 // valid credential source values
480 const (
481 credSourceEc2Metadata = "Ec2InstanceMetadata"
482 credSourceEnvironment = "Environment"
483 credSourceECSContainer = "EcsContainer"
484 )
485
486 switch sharedCfg.AssumeRole.CredentialSource {
487 case credSourceEc2Metadata:
488 cfgCp := *cfg
489 p := defaults.RemoteCredProvider(cfgCp, handlers)
490 cfgCp.Credentials = credentials.NewCredentials(p)
491
492 if len(sharedCfg.AssumeRole.MFASerial) > 0 && sessOpts.AssumeRoleTokenProvider == nil {
493 // AssumeRole Token provider is required if doing Assume Role
494 // with MFA.
495 return AssumeRoleTokenProviderNotSetError{}
496 }
497
498 cfg.Credentials = assumeRoleCredentials(cfgCp, handlers, sharedCfg, sessOpts)
499 case credSourceEnvironment:
500 cfg.Credentials = credentials.NewStaticCredentialsFromCreds(
501 envCfg.Creds,
502 )
503 case credSourceECSContainer:
504 if len(os.Getenv(shareddefaults.ECSCredsProviderEnvVar)) == 0 {
505 return ErrSharedConfigECSContainerEnvVarEmpty
506 }
507
508 cfgCp := *cfg
509 p := defaults.RemoteCredProvider(cfgCp, handlers)
510 creds := credentials.NewCredentials(p)
511
512 cfg.Credentials = creds
513 default:
514 return ErrSharedConfigInvalidCredSource
515 }
516
517 return nil
518 }
519
520 if len(envCfg.Creds.AccessKeyID) > 0 {
521 cfg.Credentials = credentials.NewStaticCredentialsFromCreds(
522 envCfg.Creds,
523 )
524 } else if envCfg.EnableSharedConfig && len(sharedCfg.AssumeRole.RoleARN) > 0 && sharedCfg.AssumeRoleSource != nil {
525 cfgCp := *cfg
526 cfgCp.Credentials = credentials.NewStaticCredentialsFromCreds(
527 sharedCfg.AssumeRoleSource.Creds,
528 )
529
530 if len(sharedCfg.AssumeRole.MFASerial) > 0 && sessOpts.AssumeRoleTokenProvider == nil {
531 // AssumeRole Token provider is required if doing Assume Role
532 // with MFA.
533 return AssumeRoleTokenProviderNotSetError{}
534 }
535
536 cfg.Credentials = assumeRoleCredentials(cfgCp, handlers, sharedCfg, sessOpts)
537 } else if len(sharedCfg.Creds.AccessKeyID) > 0 {
538 cfg.Credentials = credentials.NewStaticCredentialsFromCreds(
539 sharedCfg.Creds,
540 )
541 } else if len(sharedCfg.CredentialProcess) > 0 {
542 cfg.Credentials = processcreds.NewCredentials(
543 sharedCfg.CredentialProcess,
544 )
545 } else {
546 // Fallback to default credentials provider, include mock errors
547 // for the credential chain so user can identify why credentials
548 // failed to be retrieved.
549 cfg.Credentials = credentials.NewCredentials(&credentials.ChainProvider{
550 VerboseErrors: aws.BoolValue(cfg.CredentialsChainVerboseErrors),
551 Providers: []credentials.Provider{
552 &credProviderError{Err: awserr.New("EnvAccessKeyNotFound", "failed to find credentials in the environment.", nil)},
553 &credProviderError{Err: awserr.New("SharedCredsLoad", fmt.Sprintf("failed to load profile, %s.", envCfg.Profile), nil)},
554 defaults.RemoteCredProvider(*cfg, handlers),
555 },
556 })
557 } 508 }
509 cfg.Credentials = creds
558 } 510 }
559 511
560 return nil 512 return nil
561} 513}
562 514
563func assumeRoleCredentials(cfg aws.Config, handlers request.Handlers, sharedCfg sharedConfig, sessOpts Options) *credentials.Credentials {
564 return stscreds.NewCredentials(
565 &Session{
566 Config: &cfg,
567 Handlers: handlers.Copy(),
568 },
569 sharedCfg.AssumeRole.RoleARN,
570 func(opt *stscreds.AssumeRoleProvider) {
571 opt.RoleSessionName = sharedCfg.AssumeRole.RoleSessionName
572
573 // Assume role with external ID
574 if len(sharedCfg.AssumeRole.ExternalID) > 0 {
575 opt.ExternalID = aws.String(sharedCfg.AssumeRole.ExternalID)
576 }
577
578 // Assume role with MFA
579 if len(sharedCfg.AssumeRole.MFASerial) > 0 {
580 opt.SerialNumber = aws.String(sharedCfg.AssumeRole.MFASerial)
581 opt.TokenProvider = sessOpts.AssumeRoleTokenProvider
582 }
583 },
584 )
585}
586
587// AssumeRoleTokenProviderNotSetError is an error returned when creating a session when the
588// MFAToken option is not set when shared config is configured load assume a
589// role with an MFA token.
590type AssumeRoleTokenProviderNotSetError struct{}
591
592// Code is the short id of the error.
593func (e AssumeRoleTokenProviderNotSetError) Code() string {
594 return "AssumeRoleTokenProviderNotSetError"
595}
596
597// Message is the description of the error
598func (e AssumeRoleTokenProviderNotSetError) Message() string {
599 return fmt.Sprintf("assume role with MFA enabled, but AssumeRoleTokenProvider session option not set.")
600}
601
602// OrigErr is the underlying error that caused the failure.
603func (e AssumeRoleTokenProviderNotSetError) OrigErr() error {
604 return nil
605}
606
607// Error satisfies the error interface.
608func (e AssumeRoleTokenProviderNotSetError) Error() string {
609 return awserr.SprintError(e.Code(), e.Message(), "", nil)
610}
611
612type credProviderError struct {
613 Err error
614}
615
616var emptyCreds = credentials.Value{}
617
618func (c credProviderError) Retrieve() (credentials.Value, error) {
619 return credentials.Value{}, c.Err
620}
621func (c credProviderError) IsExpired() bool {
622 return true
623}
624
625func initHandlers(s *Session) { 515func initHandlers(s *Session) {
626 // Add the Validate parameter handler if it is not disabled. 516 // Add the Validate parameter handler if it is not disabled.
627 s.Handlers.Validate.Remove(corehandlers.ValidateParametersHandler) 517 s.Handlers.Validate.Remove(corehandlers.ValidateParametersHandler)
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/session/shared_config.go b/vendor/github.com/aws/aws-sdk-go/aws/session/shared_config.go
index 7cb4402..5170b49 100644
--- a/vendor/github.com/aws/aws-sdk-go/aws/session/shared_config.go
+++ b/vendor/github.com/aws/aws-sdk-go/aws/session/shared_config.go
@@ -5,7 +5,6 @@ import (
5 5
6 "github.com/aws/aws-sdk-go/aws/awserr" 6 "github.com/aws/aws-sdk-go/aws/awserr"
7 "github.com/aws/aws-sdk-go/aws/credentials" 7 "github.com/aws/aws-sdk-go/aws/credentials"
8
9 "github.com/aws/aws-sdk-go/internal/ini" 8 "github.com/aws/aws-sdk-go/internal/ini"
10) 9)
11 10
@@ -28,8 +27,12 @@ const (
28 27
29 // endpoint discovery group 28 // endpoint discovery group
30 enableEndpointDiscoveryKey = `endpoint_discovery_enabled` // optional 29 enableEndpointDiscoveryKey = `endpoint_discovery_enabled` // optional
30
31 // External Credential Process 31 // External Credential Process
32 credentialProcessKey = `credential_process` 32 credentialProcessKey = `credential_process` // optional
33
34 // Web Identity Token File
35 webIdentityTokenFileKey = `web_identity_token_file` // optional
33 36
34 // DefaultSharedConfigProfile is the default profile to be used when 37 // DefaultSharedConfigProfile is the default profile to be used when
35 // loading configuration from the config files if another profile name 38 // loading configuration from the config files if another profile name
@@ -37,36 +40,33 @@ const (
37 DefaultSharedConfigProfile = `default` 40 DefaultSharedConfigProfile = `default`
38) 41)
39 42
40type assumeRoleConfig struct {
41 RoleARN string
42 SourceProfile string
43 CredentialSource string
44 ExternalID string
45 MFASerial string
46 RoleSessionName string
47}
48
49// sharedConfig represents the configuration fields of the SDK config files. 43// sharedConfig represents the configuration fields of the SDK config files.
50type sharedConfig struct { 44type sharedConfig struct {
51 // Credentials values from the config file. Both aws_access_key_id 45 // Credentials values from the config file. Both aws_access_key_id and
52 // and aws_secret_access_key must be provided together in the same file 46 // aws_secret_access_key must be provided together in the same file to be
53 // to be considered valid. The values will be ignored if not a complete group. 47 // considered valid. The values will be ignored if not a complete group.
54 // aws_session_token is an optional field that can be provided if both of the 48 // aws_session_token is an optional field that can be provided if both of
55 // other two fields are also provided. 49 // the other two fields are also provided.
56 // 50 //
57 // aws_access_key_id 51 // aws_access_key_id
58 // aws_secret_access_key 52 // aws_secret_access_key
59 // aws_session_token 53 // aws_session_token
60 Creds credentials.Value 54 Creds credentials.Value
61 55
62 AssumeRole assumeRoleConfig 56 CredentialSource string
63 AssumeRoleSource *sharedConfig 57 CredentialProcess string
58 WebIdentityTokenFile string
59
60 RoleARN string
61 RoleSessionName string
62 ExternalID string
63 MFASerial string
64 64
65 // An external process to request credentials 65 SourceProfileName string
66 CredentialProcess string 66 SourceProfile *sharedConfig
67 67
68 // Region is the region the SDK should use for looking up AWS service endpoints 68 // Region is the region the SDK should use for looking up AWS service
69 // and signing requests. 69 // endpoints and signing requests.
70 // 70 //
71 // region 71 // region
72 Region string 72 Region string
@@ -83,17 +83,18 @@ type sharedConfigFile struct {
83 IniData ini.Sections 83 IniData ini.Sections
84} 84}
85 85
86// loadSharedConfig retrieves the configuration from the list of files 86// loadSharedConfig retrieves the configuration from the list of files using
87// using the profile provided. The order the files are listed will determine 87// the profile provided. The order the files are listed will determine
88// precedence. Values in subsequent files will overwrite values defined in 88// precedence. Values in subsequent files will overwrite values defined in
89// earlier files. 89// earlier files.
90// 90//
91// For example, given two files A and B. Both define credentials. If the order 91// For example, given two files A and B. Both define credentials. If the order
92// of the files are A then B, B's credential values will be used instead of A's. 92// of the files are A then B, B's credential values will be used instead of
93// A's.
93// 94//
94// See sharedConfig.setFromFile for information how the config files 95// See sharedConfig.setFromFile for information how the config files
95// will be loaded. 96// will be loaded.
96func loadSharedConfig(profile string, filenames []string) (sharedConfig, error) { 97func loadSharedConfig(profile string, filenames []string, exOpts bool) (sharedConfig, error) {
97 if len(profile) == 0 { 98 if len(profile) == 0 {
98 profile = DefaultSharedConfigProfile 99 profile = DefaultSharedConfigProfile
99 } 100 }
@@ -104,16 +105,11 @@ func loadSharedConfig(profile string, filenames []string) (sharedConfig, error)
104 } 105 }
105 106
106 cfg := sharedConfig{} 107 cfg := sharedConfig{}
107 if err = cfg.setFromIniFiles(profile, files); err != nil { 108 profiles := map[string]struct{}{}
109 if err = cfg.setFromIniFiles(profiles, profile, files, exOpts); err != nil {
108 return sharedConfig{}, err 110 return sharedConfig{}, err
109 } 111 }
110 112
111 if len(cfg.AssumeRole.SourceProfile) > 0 {
112 if err := cfg.setAssumeRoleSource(profile, files); err != nil {
113 return sharedConfig{}, err
114 }
115 }
116
117 return cfg, nil 113 return cfg, nil
118} 114}
119 115
@@ -137,60 +133,88 @@ func loadSharedConfigIniFiles(filenames []string) ([]sharedConfigFile, error) {
137 return files, nil 133 return files, nil
138} 134}
139 135
140func (cfg *sharedConfig) setAssumeRoleSource(origProfile string, files []sharedConfigFile) error { 136func (cfg *sharedConfig) setFromIniFiles(profiles map[string]struct{}, profile string, files []sharedConfigFile, exOpts bool) error {
141 var assumeRoleSrc sharedConfig 137 // Trim files from the list that don't exist.
142 138 var skippedFiles int
143 if len(cfg.AssumeRole.CredentialSource) > 0 { 139 var profileNotFoundErr error
144 // setAssumeRoleSource is only called when source_profile is found. 140 for _, f := range files {
145 // If both source_profile and credential_source are set, then 141 if err := cfg.setFromIniFile(profile, f, exOpts); err != nil {
146 // ErrSharedConfigSourceCollision will be returned 142 if _, ok := err.(SharedConfigProfileNotExistsError); ok {
147 return ErrSharedConfigSourceCollision 143 // Ignore profiles not defined in individual files.
144 profileNotFoundErr = err
145 skippedFiles++
146 continue
147 }
148 return err
149 }
150 }
151 if skippedFiles == len(files) {
152 // If all files were skipped because the profile is not found, return
153 // the original profile not found error.
154 return profileNotFoundErr
148 } 155 }
149 156
150 // Multiple level assume role chains are not support 157 if _, ok := profiles[profile]; ok {
151 if cfg.AssumeRole.SourceProfile == origProfile { 158 // if this is the second instance of the profile the Assume Role
152 assumeRoleSrc = *cfg 159 // options must be cleared because they are only valid for the
153 assumeRoleSrc.AssumeRole = assumeRoleConfig{} 160 // first reference of a profile. The self linked instance of the
161 // profile only have credential provider options.
162 cfg.clearAssumeRoleOptions()
154 } else { 163 } else {
155 err := assumeRoleSrc.setFromIniFiles(cfg.AssumeRole.SourceProfile, files) 164 // First time a profile has been seen, It must either be a assume role
156 if err != nil { 165 // or credentials. Assert if the credential type requires a role ARN,
166 // the ARN is also set.
167 if err := cfg.validateCredentialsRequireARN(profile); err != nil {
157 return err 168 return err
158 } 169 }
159 } 170 }
171 profiles[profile] = struct{}{}
160 172
161 if len(assumeRoleSrc.Creds.AccessKeyID) == 0 { 173 if err := cfg.validateCredentialType(); err != nil {
162 return SharedConfigAssumeRoleError{RoleARN: cfg.AssumeRole.RoleARN} 174 return err
163 } 175 }
164 176
165 cfg.AssumeRoleSource = &assumeRoleSrc 177 // Link source profiles for assume roles
166 178 if len(cfg.SourceProfileName) != 0 {
167 return nil 179 // Linked profile via source_profile ignore credential provider
168} 180 // options, the source profile must provide the credentials.
181 cfg.clearCredentialOptions()
169 182
170func (cfg *sharedConfig) setFromIniFiles(profile string, files []sharedConfigFile) error { 183 srcCfg := &sharedConfig{}
171 // Trim files from the list that don't exist. 184 err := srcCfg.setFromIniFiles(profiles, cfg.SourceProfileName, files, exOpts)
172 for _, f := range files { 185 if err != nil {
173 if err := cfg.setFromIniFile(profile, f); err != nil { 186 // SourceProfile that doesn't exist is an error in configuration.
174 if _, ok := err.(SharedConfigProfileNotExistsError); ok { 187 if _, ok := err.(SharedConfigProfileNotExistsError); ok {
175 // Ignore proviles missings 188 err = SharedConfigAssumeRoleError{
176 continue 189 RoleARN: cfg.RoleARN,
190 SourceProfile: cfg.SourceProfileName,
191 }
177 } 192 }
178 return err 193 return err
179 } 194 }
195
196 if !srcCfg.hasCredentials() {
197 return SharedConfigAssumeRoleError{
198 RoleARN: cfg.RoleARN,
199 SourceProfile: cfg.SourceProfileName,
200 }
201 }
202
203 cfg.SourceProfile = srcCfg
180 } 204 }
181 205
182 return nil 206 return nil
183} 207}
184 208
185// setFromFile loads the configuration from the file using 209// setFromFile loads the configuration from the file using the profile
186// the profile provided. A sharedConfig pointer type value is used so that 210// provided. A sharedConfig pointer type value is used so that multiple config
187// multiple config file loadings can be chained. 211// file loadings can be chained.
188// 212//
189// Only loads complete logically grouped values, and will not set fields in cfg 213// Only loads complete logically grouped values, and will not set fields in cfg
190// for incomplete grouped values in the config. Such as credentials. For example 214// for incomplete grouped values in the config. Such as credentials. For
191// if a config file only includes aws_access_key_id but no aws_secret_access_key 215// example if a config file only includes aws_access_key_id but no
192// the aws_access_key_id will be ignored. 216// aws_secret_access_key the aws_access_key_id will be ignored.
193func (cfg *sharedConfig) setFromIniFile(profile string, file sharedConfigFile) error { 217func (cfg *sharedConfig) setFromIniFile(profile string, file sharedConfigFile, exOpts bool) error {
194 section, ok := file.IniData.GetSection(profile) 218 section, ok := file.IniData.GetSection(profile)
195 if !ok { 219 if !ok {
196 // Fallback to to alternate profile name: profile <name> 220 // Fallback to to alternate profile name: profile <name>
@@ -200,42 +224,30 @@ func (cfg *sharedConfig) setFromIniFile(profile string, file sharedConfigFile) e
200 } 224 }
201 } 225 }
202 226
203 // Shared Credentials 227 if exOpts {
204 akid := section.String(accessKeyIDKey) 228 // Assume Role Parameters
205 secret := section.String(secretAccessKey) 229 updateString(&cfg.RoleARN, section, roleArnKey)
206 if len(akid) > 0 && len(secret) > 0 { 230 updateString(&cfg.ExternalID, section, externalIDKey)
207 cfg.Creds = credentials.Value{ 231 updateString(&cfg.MFASerial, section, mfaSerialKey)
208 AccessKeyID: akid, 232 updateString(&cfg.RoleSessionName, section, roleSessionNameKey)
209 SecretAccessKey: secret, 233 updateString(&cfg.SourceProfileName, section, sourceProfileKey)
210 SessionToken: section.String(sessionTokenKey), 234 updateString(&cfg.CredentialSource, section, credentialSourceKey)
211 ProviderName: fmt.Sprintf("SharedConfigCredentials: %s", file.Filename),
212 }
213 }
214 235
215 // Assume Role 236 updateString(&cfg.Region, section, regionKey)
216 roleArn := section.String(roleArnKey)
217 srcProfile := section.String(sourceProfileKey)
218 credentialSource := section.String(credentialSourceKey)
219 hasSource := len(srcProfile) > 0 || len(credentialSource) > 0
220 if len(roleArn) > 0 && hasSource {
221 cfg.AssumeRole = assumeRoleConfig{
222 RoleARN: roleArn,
223 SourceProfile: srcProfile,
224 CredentialSource: credentialSource,
225 ExternalID: section.String(externalIDKey),
226 MFASerial: section.String(mfaSerialKey),
227 RoleSessionName: section.String(roleSessionNameKey),
228 }
229 } 237 }
230 238
231 // `credential_process` 239 updateString(&cfg.CredentialProcess, section, credentialProcessKey)
232 if credProc := section.String(credentialProcessKey); len(credProc) > 0 { 240 updateString(&cfg.WebIdentityTokenFile, section, webIdentityTokenFileKey)
233 cfg.CredentialProcess = credProc
234 }
235 241
236 // Region 242 // Shared Credentials
237 if v := section.String(regionKey); len(v) > 0 { 243 creds := credentials.Value{
238 cfg.Region = v 244 AccessKeyID: section.String(accessKeyIDKey),
245 SecretAccessKey: section.String(secretAccessKey),
246 SessionToken: section.String(sessionTokenKey),
247 ProviderName: fmt.Sprintf("SharedConfigCredentials: %s", file.Filename),
248 }
249 if creds.HasKeys() {
250 cfg.Creds = creds
239 } 251 }
240 252
241 // Endpoint discovery 253 // Endpoint discovery
@@ -247,6 +259,95 @@ func (cfg *sharedConfig) setFromIniFile(profile string, file sharedConfigFile) e
247 return nil 259 return nil
248} 260}
249 261
262func (cfg *sharedConfig) validateCredentialsRequireARN(profile string) error {
263 var credSource string
264
265 switch {
266 case len(cfg.SourceProfileName) != 0:
267 credSource = sourceProfileKey
268 case len(cfg.CredentialSource) != 0:
269 credSource = credentialSourceKey
270 case len(cfg.WebIdentityTokenFile) != 0:
271 credSource = webIdentityTokenFileKey
272 }
273
274 if len(credSource) != 0 && len(cfg.RoleARN) == 0 {
275 return CredentialRequiresARNError{
276 Type: credSource,
277 Profile: profile,
278 }
279 }
280
281 return nil
282}
283
284func (cfg *sharedConfig) validateCredentialType() error {
285 // Only one or no credential type can be defined.
286 if !oneOrNone(
287 len(cfg.SourceProfileName) != 0,
288 len(cfg.CredentialSource) != 0,
289 len(cfg.CredentialProcess) != 0,
290 len(cfg.WebIdentityTokenFile) != 0,
291 ) {
292 return ErrSharedConfigSourceCollision
293 }
294
295 return nil
296}
297
298func (cfg *sharedConfig) hasCredentials() bool {
299 switch {
300 case len(cfg.SourceProfileName) != 0:
301 case len(cfg.CredentialSource) != 0:
302 case len(cfg.CredentialProcess) != 0:
303 case len(cfg.WebIdentityTokenFile) != 0:
304 case cfg.Creds.HasKeys():
305 default:
306 return false
307 }
308
309 return true
310}
311
312func (cfg *sharedConfig) clearCredentialOptions() {
313 cfg.CredentialSource = ""
314 cfg.CredentialProcess = ""
315 cfg.WebIdentityTokenFile = ""
316 cfg.Creds = credentials.Value{}
317}
318
319func (cfg *sharedConfig) clearAssumeRoleOptions() {
320 cfg.RoleARN = ""
321 cfg.ExternalID = ""
322 cfg.MFASerial = ""
323 cfg.RoleSessionName = ""
324 cfg.SourceProfileName = ""
325}
326
327func oneOrNone(bs ...bool) bool {
328 var count int
329
330 for _, b := range bs {
331 if b {
332 count++
333 if count > 1 {
334 return false
335 }
336 }
337 }
338
339 return true
340}
341
342// updateString will only update the dst with the value in the section key, key
343// is present in the section.
344func updateString(dst *string, section ini.Section, key string) {
345 if !section.Has(key) {
346 return
347 }
348 *dst = section.String(key)
349}
350
250// SharedConfigLoadError is an error for the shared config file failed to load. 351// SharedConfigLoadError is an error for the shared config file failed to load.
251type SharedConfigLoadError struct { 352type SharedConfigLoadError struct {
252 Filename string 353 Filename string
@@ -304,7 +405,8 @@ func (e SharedConfigProfileNotExistsError) Error() string {
304// profile contains assume role information, but that information is invalid 405// profile contains assume role information, but that information is invalid
305// or not complete. 406// or not complete.
306type SharedConfigAssumeRoleError struct { 407type SharedConfigAssumeRoleError struct {
307 RoleARN string 408 RoleARN string
409 SourceProfile string
308} 410}
309 411
310// Code is the short id of the error. 412// Code is the short id of the error.
@@ -314,8 +416,10 @@ func (e SharedConfigAssumeRoleError) Code() string {
314 416
315// Message is the description of the error 417// Message is the description of the error
316func (e SharedConfigAssumeRoleError) Message() string { 418func (e SharedConfigAssumeRoleError) Message() string {
317 return fmt.Sprintf("failed to load assume role for %s, source profile has no shared credentials", 419 return fmt.Sprintf(
318 e.RoleARN) 420 "failed to load assume role for %s, source profile %s has no shared credentials",
421 e.RoleARN, e.SourceProfile,
422 )
319} 423}
320 424
321// OrigErr is the underlying error that caused the failure. 425// OrigErr is the underlying error that caused the failure.
@@ -327,3 +431,36 @@ func (e SharedConfigAssumeRoleError) OrigErr() error {
327func (e SharedConfigAssumeRoleError) Error() string { 431func (e SharedConfigAssumeRoleError) Error() string {
328 return awserr.SprintError(e.Code(), e.Message(), "", nil) 432 return awserr.SprintError(e.Code(), e.Message(), "", nil)
329} 433}
434
435// CredentialRequiresARNError provides the error for shared config credentials
436// that are incorrectly configured in the shared config or credentials file.
437type CredentialRequiresARNError struct {
438 // type of credentials that were configured.
439 Type string
440
441 // Profile name the credentials were in.
442 Profile string
443}
444
445// Code is the short id of the error.
446func (e CredentialRequiresARNError) Code() string {
447 return "CredentialRequiresARNError"
448}
449
450// Message is the description of the error
451func (e CredentialRequiresARNError) Message() string {
452 return fmt.Sprintf(
453 "credential type %s requires role_arn, profile %s",
454 e.Type, e.Profile,
455 )
456}
457
458// OrigErr is the underlying error that caused the failure.
459func (e CredentialRequiresARNError) OrigErr() error {
460 return nil
461}
462
463// Error satisfies the error interface.
464func (e CredentialRequiresARNError) Error() string {
465 return awserr.SprintError(e.Code(), e.Message(), "", nil)
466}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/signer/v4/v4.go b/vendor/github.com/aws/aws-sdk-go/aws/signer/v4/v4.go
index 523db79..8104793 100644
--- a/vendor/github.com/aws/aws-sdk-go/aws/signer/v4/v4.go
+++ b/vendor/github.com/aws/aws-sdk-go/aws/signer/v4/v4.go
@@ -687,7 +687,11 @@ func (ctx *signingCtx) buildBodyDigest() error {
687 if !aws.IsReaderSeekable(ctx.Body) { 687 if !aws.IsReaderSeekable(ctx.Body) {
688 return fmt.Errorf("cannot use unseekable request body %T, for signed request with body", ctx.Body) 688 return fmt.Errorf("cannot use unseekable request body %T, for signed request with body", ctx.Body)
689 } 689 }
690 hash = hex.EncodeToString(makeSha256Reader(ctx.Body)) 690 hashBytes, err := makeSha256Reader(ctx.Body)
691 if err != nil {
692 return err
693 }
694 hash = hex.EncodeToString(hashBytes)
691 } 695 }
692 696
693 if includeSHA256Header { 697 if includeSHA256Header {
@@ -734,10 +738,16 @@ func makeSha256(data []byte) []byte {
734 return hash.Sum(nil) 738 return hash.Sum(nil)
735} 739}
736 740
737func makeSha256Reader(reader io.ReadSeeker) []byte { 741func makeSha256Reader(reader io.ReadSeeker) (hashBytes []byte, err error) {
738 hash := sha256.New() 742 hash := sha256.New()
739 start, _ := reader.Seek(0, sdkio.SeekCurrent) 743 start, err := reader.Seek(0, sdkio.SeekCurrent)
740 defer reader.Seek(start, sdkio.SeekStart) 744 if err != nil {
745 return nil, err
746 }
747 defer func() {
748 // ensure error is return if unable to seek back to start of payload.
749 _, err = reader.Seek(start, sdkio.SeekStart)
750 }()
741 751
742 // Use CopyN to avoid allocating the 32KB buffer in io.Copy for bodies 752 // Use CopyN to avoid allocating the 32KB buffer in io.Copy for bodies
743 // smaller than 32KB. Fall back to io.Copy if we fail to determine the size. 753 // smaller than 32KB. Fall back to io.Copy if we fail to determine the size.
@@ -748,7 +758,7 @@ func makeSha256Reader(reader io.ReadSeeker) []byte {
748 io.CopyN(hash, reader, size) 758 io.CopyN(hash, reader, size)
749 } 759 }
750 760
751 return hash.Sum(nil) 761 return hash.Sum(nil), nil
752} 762}
753 763
754const doubleSpace = " " 764const doubleSpace = " "
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/types.go b/vendor/github.com/aws/aws-sdk-go/aws/types.go
index 8b6f234..4550915 100644
--- a/vendor/github.com/aws/aws-sdk-go/aws/types.go
+++ b/vendor/github.com/aws/aws-sdk-go/aws/types.go
@@ -7,13 +7,18 @@ import (
7 "github.com/aws/aws-sdk-go/internal/sdkio" 7 "github.com/aws/aws-sdk-go/internal/sdkio"
8) 8)
9 9
10// ReadSeekCloser wraps a io.Reader returning a ReaderSeekerCloser. Should 10// ReadSeekCloser wraps a io.Reader returning a ReaderSeekerCloser. Allows the
11// only be used with an io.Reader that is also an io.Seeker. Doing so may 11// SDK to accept an io.Reader that is not also an io.Seeker for unsigned
12// cause request signature errors, or request body's not sent for GET, HEAD 12// streaming payload API operations.
13// and DELETE HTTP methods.
14// 13//
15// Deprecated: Should only be used with io.ReadSeeker. If using for 14// A ReadSeekCloser wrapping an nonseekable io.Reader used in an API
16// S3 PutObject to stream content use s3manager.Uploader instead. 15// operation's input will prevent that operation being retried in the case of
16// network errors, and cause operation requests to fail if the operation
17// requires payload signing.
18//
19// Note: If using With S3 PutObject to stream an object upload The SDK's S3
20// Upload manager (s3manager.Uploader) provides support for streaming with the
21// ability to retry network errors.
17func ReadSeekCloser(r io.Reader) ReaderSeekerCloser { 22func ReadSeekCloser(r io.Reader) ReaderSeekerCloser {
18 return ReaderSeekerCloser{r} 23 return ReaderSeekerCloser{r}
19} 24}
@@ -43,7 +48,8 @@ func IsReaderSeekable(r io.Reader) bool {
43// Read reads from the reader up to size of p. The number of bytes read, and 48// Read reads from the reader up to size of p. The number of bytes read, and
44// error if it occurred will be returned. 49// error if it occurred will be returned.
45// 50//
46// If the reader is not an io.Reader zero bytes read, and nil error will be returned. 51// If the reader is not an io.Reader zero bytes read, and nil error will be
52// returned.
47// 53//
48// Performs the same functionality as io.Reader Read 54// Performs the same functionality as io.Reader Read
49func (r ReaderSeekerCloser) Read(p []byte) (int, error) { 55func (r ReaderSeekerCloser) Read(p []byte) (int, error) {
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/version.go b/vendor/github.com/aws/aws-sdk-go/aws/version.go
index 15ad9cf..23aae7d 100644
--- a/vendor/github.com/aws/aws-sdk-go/aws/version.go
+++ b/vendor/github.com/aws/aws-sdk-go/aws/version.go
@@ -5,4 +5,4 @@ package aws
5const SDKName = "aws-sdk-go" 5const SDKName = "aws-sdk-go"
6 6
7// SDKVersion is the version of this SDK 7// SDKVersion is the version of this SDK
8const SDKVersion = "1.19.18" 8const SDKVersion = "1.21.7"